mirror of
https://github.com/EQEmu/Server.git
synced 2026-04-26 15:32:27 +00:00
Merge fix
This commit is contained in:
commit
722260f4c3
@ -27,7 +27,7 @@ void SendCrashReport(const std::string &crash_report)
|
||||
// "http://localhost:3010/api/v1/server-crash-report", // development
|
||||
};
|
||||
|
||||
auto config = EQEmuConfig::get();
|
||||
auto config = EQEmuConfig::get();
|
||||
for (auto &e: endpoints) {
|
||||
uri u(e);
|
||||
|
||||
|
||||
@ -2770,7 +2770,7 @@ bool NPC::Death(Mob* killer_mob, int64 damage, uint16 spell, EQ::skills::SkillTy
|
||||
}
|
||||
}
|
||||
|
||||
if (killer_mob->IsBot()) {
|
||||
if (killer_mob && killer_mob->IsBot()) {
|
||||
parse->EventBot(EVENT_NPC_SLAY, killer_mob->CastToBot(), this, "", 0);
|
||||
killer_mob->TrySpellOnKill(killed_level, spell);
|
||||
}
|
||||
|
||||
@ -7192,7 +7192,13 @@ void bot_subcommand_botgroup_add_member(Client *c, const Seperator *sep)
|
||||
std::list<Bot*> sbl;
|
||||
MyBots::PopulateSBL_ByNamedBot(c, sbl, sep->arg[1]);
|
||||
if (sbl.empty()) {
|
||||
c->Message(Chat::White, "You must name a new member as a bot that you own to use this command.");
|
||||
c->Message(
|
||||
Chat::White,
|
||||
fmt::format(
|
||||
"Usage: (<target_leader>) {} [member_name]",
|
||||
sep->arg[0]
|
||||
).c_str()
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@ -2358,7 +2358,7 @@ bool BotDatabase::LoadLeaderIDByBotGroupID(const uint32 group_id, uint32& leader
|
||||
bool BotDatabase::LoadBotGroupNameByBotGroupID(const uint32 group_id, std::string& botgroup_name)
|
||||
{
|
||||
if (!group_id) {
|
||||
false;
|
||||
return false;
|
||||
}
|
||||
|
||||
query = fmt::format(
|
||||
@ -2624,7 +2624,7 @@ bool BotDatabase::LoadBotGroupsListByOwnerID(const uint32 owner_id, std::list<st
|
||||
|
||||
|
||||
query = fmt::format(
|
||||
"SELECT group_name, group_leader_id FROM "
|
||||
"SELECT DISTINCT(group_name), group_leader_id FROM "
|
||||
"bot_groups bg INNER JOIN bot_group_members bgm "
|
||||
"ON bg.groups_index = bgm.groups_index "
|
||||
"WHERE bgm.bot_id IN "
|
||||
|
||||
@ -2901,14 +2901,16 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
|
||||
since effect can potentially kill caster.
|
||||
*/
|
||||
case SE_Health_Transfer: {
|
||||
effect_value = spells[spell_id].limit_value[i];
|
||||
int64 amt = std::abs(caster->GetMaxHP() * effect_value / 1000);
|
||||
if (caster) {
|
||||
effect_value = spells[spell_id].limit_value[i];
|
||||
int64 amt = std::abs(caster->GetMaxHP() * effect_value / 1000);
|
||||
|
||||
if (effect_value < 0) {
|
||||
Damage(caster, amt, spell_id, spell.skill, false, buffslot, false);
|
||||
}
|
||||
else {
|
||||
HealDamage(amt, caster);
|
||||
if (effect_value < 0) {
|
||||
Damage(caster, amt, spell_id, spell.skill, false, buffslot, false);
|
||||
}
|
||||
else {
|
||||
HealDamage(amt, caster);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user