Revert "Build/Clang: fixed 96 warnings + improved code readability"

This reverts commit a4589f71d5.
This commit is contained in:
ShinDarth
2016-09-04 10:11:10 +02:00
parent e5fd1095c9
commit 5802a37698
28 changed files with 62 additions and 132 deletions

View File

@@ -275,9 +275,11 @@ class boss_algalon_the_observer : public CreatureScript
{
if (!item) // should not happen, but checked in GetAverageItemLevel()
return true;
if (item->ItemLevel <= 226 || (item->ItemLevel <= 232 && (item->InventoryType == INVTYPE_SHIELD ||
item->Class == ITEM_CLASS_WEAPON ||
(item->Class == ITEM_CLASS_ARMOR && (item->InventoryType == INVTYPE_RELIC || item->InventoryType == INVTYPE_HOLDABLE)))))
if (item->ItemLevel <= 226 || item->ItemLevel <= 232 && (
item->InventoryType == INVTYPE_SHIELD ||
item->Class == ITEM_CLASS_WEAPON ||
item->Class == ITEM_CLASS_ARMOR && (item->InventoryType == INVTYPE_RELIC || item->InventoryType == INVTYPE_HOLDABLE)
))
return true;
return false;
}

View File

@@ -470,8 +470,8 @@ public:
if( faction )
for( uint8 k=0; k<4; ++k )
{
if((faction == 'A' && ( k>1 || (k==1 && RAID_MODE(1,0)) )) ||
(faction == 'H' && ( k<2 || (k==3 && RAID_MODE(1,0)) )) )
if( faction == 'A' && ( k>1 || k==1 && RAID_MODE(1,0) ) ||
faction == 'H' && ( k<2 || k==3 && RAID_MODE(1,0) ) )
continue;
for( uint8 i=0; i<4; ++i )
@@ -639,8 +639,7 @@ public:
if (me->IsSummon())
if (Unit* s = me->ToTempSummon()->GetSummoner())
{
if ((s->GetTypeId() == TYPEID_PLAYER && !s->HasAura(SPELL_FLASH_FREEZE_TRAPPED_PLAYER)) ||
(s->GetTypeId() == TYPEID_UNIT && !s->HasAura(SPELL_FLASH_FREEZE_TRAPPED_NPC)))
if (s->GetTypeId() == TYPEID_PLAYER && !s->HasAura(SPELL_FLASH_FREEZE_TRAPPED_PLAYER) || s->GetTypeId() == TYPEID_UNIT && !s->HasAura(SPELL_FLASH_FREEZE_TRAPPED_NPC))
me->DespawnOrUnsummon(2000);
else if (s->GetTypeId() == TYPEID_PLAYER)
if (InstanceScript* pInstance = me->GetInstanceScript())

View File

@@ -484,7 +484,7 @@ public:
if (!summon || summon->GetEntry() != NPC_OMINOUS_CLOUD || me->GetDistance(summon) < 20)
continue;
if ((!cloud || (urand(0,1) && !summon->HasAura(SPELL_SUMMON_GUARDIAN_OF_YS))))
if ((!cloud || urand(0,1) && !summon->HasAura(SPELL_SUMMON_GUARDIAN_OF_YS)))
cloud = summon;
}