Core/Misc: Port cherrypick refactors
This commit is contained in:
@@ -177,7 +177,7 @@ void WorldSession::HandleLootMoneyOpcode(WorldPackets::Loot::LootMoney& /*packet
|
||||
WorldPackets::Loot::LootMoneyNotify packet;
|
||||
packet.Money = goldPerPlayer;
|
||||
packet.MoneyMod = goldMod;
|
||||
packet.SoleLooter = playersNear.size() <= 1 ? true : false;
|
||||
packet.SoleLooter = playersNear.size() <= 1;
|
||||
(*i)->SendDirectMessage(packet.Write());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -142,7 +142,7 @@ namespace WorldPackets
|
||||
class LootMoneyNotify final : public ServerPacket
|
||||
{
|
||||
public:
|
||||
explicit LootMoneyNotify() : ServerPacket(SMSG_LOOT_MONEY_NOTIFY, 5) { }
|
||||
explicit LootMoneyNotify() : ServerPacket(SMSG_LOOT_MONEY_NOTIFY, 8 + 8 + 1) { }
|
||||
|
||||
WorldPacket const* Write() override;
|
||||
|
||||
@@ -154,7 +154,7 @@ namespace WorldPackets
|
||||
class CoinRemoved final : public ServerPacket
|
||||
{
|
||||
public:
|
||||
explicit CoinRemoved() : ServerPacket(SMSG_COIN_REMOVED, 9) { }
|
||||
explicit CoinRemoved() : ServerPacket(SMSG_COIN_REMOVED, 16) { }
|
||||
|
||||
WorldPacket const* Write() override;
|
||||
|
||||
|
||||
@@ -2326,10 +2326,11 @@ void Spell::EffectUntrainTalents()
|
||||
if (effectHandleMode != SPELL_EFFECT_HANDLE_HIT_TARGET)
|
||||
return;
|
||||
|
||||
if (!unitTarget || m_caster->GetTypeId() == TYPEID_PLAYER)
|
||||
if (!unitTarget->IsPlayer())
|
||||
return;
|
||||
|
||||
unitTarget->ToPlayer()->SendRespecWipeConfirm(m_caster->GetGUID(), unitTarget->ToPlayer()->GetNextResetTalentsCost(), SPEC_RESET_TALENTS);
|
||||
Player* playerTarget = unitTarget->ToPlayer();
|
||||
playerTarget->SendRespecWipeConfirm(m_caster->GetGUID(), playerTarget->GetNextResetTalentsCost(), SPEC_RESET_TALENTS);
|
||||
}
|
||||
|
||||
void Spell::EffectTeleUnitsFaceCaster()
|
||||
|
||||
Reference in New Issue
Block a user