mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-19 00:48:56 +01:00
Core/Misc: Warning fixes
This commit is contained in:
@@ -367,7 +367,7 @@ bool AchievementCriteriaData::Meets(uint32 criteria_id, Player const* source, Wo
|
||||
Unit const* unitTarget = target->ToUnit();
|
||||
if (!unitTarget)
|
||||
return false;
|
||||
return unitTarget->GetGender() == gender.gender;
|
||||
return unitTarget->GetGender() == Gender(gender.gender);
|
||||
}
|
||||
case ACHIEVEMENT_CRITERIA_DATA_TYPE_SCRIPT:
|
||||
{
|
||||
|
||||
@@ -201,7 +201,7 @@ bool Condition::Meets(ConditionSourceInfo& sourceInfo) const
|
||||
case CONDITION_GENDER:
|
||||
{
|
||||
if (Player* player = object->ToPlayer())
|
||||
condMeets = player->GetNativeGender() == ConditionValue1;
|
||||
condMeets = player->GetNativeGender() == Gender(ConditionValue1);
|
||||
break;
|
||||
}
|
||||
case CONDITION_SKILL:
|
||||
|
||||
@@ -1278,17 +1278,17 @@ void WorldSession::HandleAlterAppearance(WorldPacket& recvData)
|
||||
|
||||
BarberShopStyleEntry const* bs_hair = sBarberShopStyleStore.LookupEntry(Hair);
|
||||
|
||||
if (!bs_hair || bs_hair->Type != 0 || bs_hair->Race != _player->GetRace() || bs_hair->Sex != _player->GetNativeGender())
|
||||
if (!bs_hair || bs_hair->Type != 0 || bs_hair->Race != _player->GetRace() || Gender(bs_hair->Sex) != _player->GetNativeGender())
|
||||
return;
|
||||
|
||||
BarberShopStyleEntry const* bs_facialHair = sBarberShopStyleStore.LookupEntry(FacialHair);
|
||||
|
||||
if (!bs_facialHair || bs_facialHair->Type != 2 || bs_facialHair->Race != _player->GetRace() || bs_facialHair->Sex != _player->GetNativeGender())
|
||||
if (!bs_facialHair || bs_facialHair->Type != 2 || bs_facialHair->Race != _player->GetRace() || Gender(bs_facialHair->Sex) != _player->GetNativeGender())
|
||||
return;
|
||||
|
||||
BarberShopStyleEntry const* bs_skinColor = sBarberShopStyleStore.LookupEntry(SkinColor);
|
||||
|
||||
if (bs_skinColor && (bs_skinColor->Type != 3 || bs_skinColor->Race != _player->GetRace() || bs_skinColor->Sex != _player->GetNativeGender()))
|
||||
if (bs_skinColor && (bs_skinColor->Type != 3 || bs_skinColor->Race != _player->GetRace() || Gender(bs_skinColor->Sex) != _player->GetNativeGender()))
|
||||
return;
|
||||
|
||||
if (!Player::ValidateAppearance(_player->GetRace(), _player->GetClass(), _player->GetNativeGender(),
|
||||
|
||||
@@ -394,7 +394,7 @@ bool SpellEffectInfo::IsEffect() const
|
||||
|
||||
bool SpellEffectInfo::IsEffect(SpellEffects effectName) const
|
||||
{
|
||||
return Effect == uint32(effectName);
|
||||
return Effect == effectName;
|
||||
}
|
||||
|
||||
bool SpellEffectInfo::IsAura() const
|
||||
|
||||
Reference in New Issue
Block a user