diff options
Diffstat (limited to 'src')
74 files changed, 175 insertions, 205 deletions
diff --git a/src/game/AI/CoreAI/GameObjectAI.h b/src/game/AI/CoreAI/GameObjectAI.h index 2489f34526..9b0024d3ee 100644 --- a/src/game/AI/CoreAI/GameObjectAI.h +++ b/src/game/AI/CoreAI/GameObjectAI.h @@ -35,7 +35,7 @@ class GameObjectAI static int Permissible(GameObject const* go); - virtual bool GossipHello(Player* /*player*/, bool reportUse) { return false; } + virtual bool GossipHello(Player* /*player*/, bool /*reportUse*/) { return false; } virtual bool GossipSelect(Player* /*player*/, uint32 /*sender*/, uint32 /*action*/) { return false; } virtual bool GossipSelectCode(Player* /*player*/, uint32 /*sender*/, uint32 /*action*/, char const* /*code*/) { return false; } virtual bool QuestAccept(Player* /*player*/, Quest const* /*quest*/) { return false; } @@ -49,7 +49,7 @@ class GameObjectAI virtual void OnGameEvent(bool /*start*/, uint16 /*eventId*/) {} virtual void OnStateChanged(uint32 /*state*/, Unit* /*unit*/) {} virtual void EventInform(uint32 /*eventId*/) {} - virtual void SpellHit(Unit* unit, const SpellInfo* spellInfo) {} + virtual void SpellHit(Unit* /*unit*/, const SpellInfo* /*spellInfo*/) {} }; class NullGameObjectAI : public GameObjectAI diff --git a/src/game/AI/CoreAI/TotemAI.cpp b/src/game/AI/CoreAI/TotemAI.cpp index 455e1253d5..5d5c302465 100644 --- a/src/game/AI/CoreAI/TotemAI.cpp +++ b/src/game/AI/CoreAI/TotemAI.cpp @@ -28,11 +28,11 @@ TotemAI::TotemAI(Creature* c) : CreatureAI(c), i_victimGuid(0) ASSERT(c->IsTotem()); } -void TotemAI::SpellHit(Unit* /*caster*/, const SpellInfo* spellInfo) +void TotemAI::SpellHit(Unit* /*caster*/, const SpellInfo* /*spellInfo*/) { } -void TotemAI::DoAction(int32 param) +void TotemAI::DoAction(int32 /*param*/) { } diff --git a/src/game/AI/CoreAI/TotemAI.h b/src/game/AI/CoreAI/TotemAI.h index 3fbc080839..7e153cca24 100644 --- a/src/game/AI/CoreAI/TotemAI.h +++ b/src/game/AI/CoreAI/TotemAI.h @@ -36,7 +36,7 @@ class KillMagnetEvent : public BasicEvent { public: KillMagnetEvent(Unit& self) : _self(self) { } - bool Execute(uint64 e_time, uint32 p_time) + bool Execute(uint64 /*e_time*/, uint32 /*p_time*/) { _self.setDeathState(JUST_DIED); return true; diff --git a/src/game/AI/ScriptedAI/ScriptedEscortAI.cpp b/src/game/AI/ScriptedAI/ScriptedEscortAI.cpp index 9e0b88d154..763c8644a2 100644 --- a/src/game/AI/ScriptedAI/ScriptedEscortAI.cpp +++ b/src/game/AI/ScriptedAI/ScriptedEscortAI.cpp @@ -506,7 +506,6 @@ bool npc_escortAI::SetNextWaypoint(uint32 pointId, bool setPosition) if (WaypointList.empty()) return false; - size_t const size = WaypointList.size(); Escort_Waypoint waypoint(0, 0, 0, 0, 0); for (CurrentWP = WaypointList.begin(); CurrentWP != WaypointList.end(); ++CurrentWP) { diff --git a/src/game/AI/SmartScripts/SmartScript.cpp b/src/game/AI/SmartScripts/SmartScript.cpp index 960cde20af..0bcdeb1d2f 100644 --- a/src/game/AI/SmartScripts/SmartScript.cpp +++ b/src/game/AI/SmartScripts/SmartScript.cpp @@ -4202,7 +4202,6 @@ void SmartScript::OnInitialize(WorldObject* obj, AreaTriggerEntry const* at) GetScript();//load copy of script - const SpellInfo* spellInfo = NULL; uint32 maxDisableDist = 0; uint32 minEnableDist = 0; for (SmartAIEventList::iterator i = mEvents.begin(); i != mEvents.end(); ++i) diff --git a/src/game/AI/SmartScripts/SmartScript.h b/src/game/AI/SmartScripts/SmartScript.h index 16617e7402..548e123317 100644 --- a/src/game/AI/SmartScripts/SmartScript.h +++ b/src/game/AI/SmartScripts/SmartScript.h @@ -165,7 +165,7 @@ class SmartScript CellCoord p(Trinity::ComputeCellCoord(searchObject->GetPositionX(), searchObject->GetPositionY())); Cell cell(p); - Trinity::GameObjectWithDbGUIDCheck goCheck(*searchObject, guid); + Trinity::GameObjectWithDbGUIDCheck goCheck(guid); Trinity::GameObjectSearcher<Trinity::GameObjectWithDbGUIDCheck> checker(searchObject, gameObject, goCheck); TypeContainerVisitor<Trinity::GameObjectSearcher<Trinity::GameObjectWithDbGUIDCheck>, GridTypeMapContainer > objectChecker(checker); @@ -180,7 +180,7 @@ class SmartScript CellCoord p(Trinity::ComputeCellCoord(searchObject->GetPositionX(), searchObject->GetPositionY())); Cell cell(p); - Trinity::CreatureWithDbGUIDCheck target_check(searchObject, guid); + Trinity::CreatureWithDbGUIDCheck target_check(guid); Trinity::CreatureSearcher<Trinity::CreatureWithDbGUIDCheck> checker(searchObject, creature, target_check); TypeContainerVisitor<Trinity::CreatureSearcher <Trinity::CreatureWithDbGUIDCheck>, GridTypeMapContainer > unit_checker(checker); diff --git a/src/game/Achievements/AchievementMgr.cpp b/src/game/Achievements/AchievementMgr.cpp index 7d009b3524..1545767891 100644 --- a/src/game/Achievements/AchievementMgr.cpp +++ b/src/game/Achievements/AchievementMgr.cpp @@ -705,7 +705,7 @@ void AchievementMgr::SendCriteriaUpdate(AchievementCriteriaEntry const* entry, C if (!entry->timeLimit) data << uint32(0); else - data << uint32(/* xinef: timedCompleted ? 0 : 1*/ 0); // this are some flags, 1 is for keeping the counter at 0 in client + data << uint32(timedCompleted ? 0 : 1); // 1 is for keeping the counter at 0 in client data.AppendPackedTime(progress->date); data << uint32(timeElapsed); // time elapsed in seconds data << uint32(0); // unk @@ -2036,7 +2036,7 @@ void AchievementMgr::SetCriteriaProgress(AchievementCriteriaEntry const* entry, m_timedAchievements.erase(timedIter); } - SendCriteriaUpdate(entry, progress, timeElapsed, timedCompleted); + SendCriteriaUpdate(entry, progress, timeElapsed, true); sScriptMgr->OnCriteriaProgress(GetPlayer(), entry); } diff --git a/src/game/Battlefield/Battlefield.h b/src/game/Battlefield/Battlefield.h index 4d4b6c924f..7655678ff4 100644 --- a/src/game/Battlefield/Battlefield.h +++ b/src/game/Battlefield/Battlefield.h @@ -75,6 +75,8 @@ class BfCapturePoint public: BfCapturePoint(Battlefield* bf); + virtual ~BfCapturePoint() { } + virtual void FillInitialWorldStates(WorldPacket& /*data*/) {} // Send world state update to all players present diff --git a/src/game/Battlefield/Zones/BattlefieldWG.cpp b/src/game/Battlefield/Zones/BattlefieldWG.cpp index 6edcbc004d..1f98dca924 100644 --- a/src/game/Battlefield/Zones/BattlefieldWG.cpp +++ b/src/game/Battlefield/Zones/BattlefieldWG.cpp @@ -697,7 +697,6 @@ void BattlefieldWG::HandleKill(Player* killer, Unit* victim) if (killer == victim) return; - bool again = false; TeamId killerTeam = killer->GetTeamId(); // xinef: tower cannons also grant rank diff --git a/src/game/Battlefield/Zones/BattlefieldWG.h b/src/game/Battlefield/Zones/BattlefieldWG.h index 054252c34f..87658e3b22 100644 --- a/src/game/Battlefield/Zones/BattlefieldWG.h +++ b/src/game/Battlefield/Zones/BattlefieldWG.h @@ -410,6 +410,37 @@ class BattlefieldWG : public Battlefield uint32 GetAreaByGraveyardId(uint8 gId) const; uint32 GetData(uint32 data) const; + + bool IsKeepNpc(uint32 entry) + { + switch (entry) + { + case BATTLEFIELD_WG_NPC_GUARD_H: + case BATTLEFIELD_WG_NPC_GUARD_A: + case BATTLEFIELD_WG_NPC_VIERON_BLAZEFEATHER: + case BATTLEFIELD_WG_NPC_BOWYER_RANDOLPH: + case BATTLEFIELD_WG_NPC_STONE_GUARD_MUKAR: + case BATTLEFIELD_WG_NPC_KNIGHT_DAMERON: + case BATTLEFIELD_WG_NPC_HOODOO_MASTER_FU_JIN: + case BATTLEFIELD_WG_NPC_SORCERESS_KAYLANA: + case BATTLEFIELD_WG_NPC_CHAMPION_ROS_SLAI: + case BATTLEFIELD_WG_NPC_MARSHAL_MAGRUDER: + case BATTLEFIELD_WG_NPC_COMMANDER_DARDOSH: + case BATTLEFIELD_WG_NPC_COMMANDER_ZANNETH: + case BATTLEFIELD_WG_NPC_TACTICAL_OFFICER_KILRATH: + case BATTLEFIELD_WG_NPC_TACTICAL_OFFICER_AHBRAMIS: + case BATTLEFIELD_WG_NPC_HORDE_WARBRINGER: + case BATTLEFIELD_WG_NPC_BRIGADIER_GENERAL: + case BATTLEFIELD_WG_NPC_SIEGESMITH_STRONGHOOF: + case BATTLEFIELD_WG_NPC_SIEGE_MASTER_STOUTHANDLE: + case BATTLEFIELD_WG_NPC_PRIMALIST_MULFORT: + case BATTLEFIELD_WG_NPC_ANCHORITE_TESSA: + case BATTLEFIELD_WG_NPC_LIEUTENANT_MURP: + case BATTLEFIELD_WG_NPC_SENIOR_DEMOLITIONIST_LEGOSO: + return true; + } + return false; + } protected: bool m_isRelicInteractible; @@ -628,37 +659,6 @@ const Position WGTurret[WG_MAX_TURRET] = { { 5352.22f, 3061.46f, 421.102f, 1.52235f } }; -static bool IsKeepNpc(uint32 entry) -{ - switch (entry) - { - case BATTLEFIELD_WG_NPC_GUARD_H: - case BATTLEFIELD_WG_NPC_GUARD_A: - case BATTLEFIELD_WG_NPC_VIERON_BLAZEFEATHER: - case BATTLEFIELD_WG_NPC_BOWYER_RANDOLPH: - case BATTLEFIELD_WG_NPC_STONE_GUARD_MUKAR: - case BATTLEFIELD_WG_NPC_KNIGHT_DAMERON: - case BATTLEFIELD_WG_NPC_HOODOO_MASTER_FU_JIN: - case BATTLEFIELD_WG_NPC_SORCERESS_KAYLANA: - case BATTLEFIELD_WG_NPC_CHAMPION_ROS_SLAI: - case BATTLEFIELD_WG_NPC_MARSHAL_MAGRUDER: - case BATTLEFIELD_WG_NPC_COMMANDER_DARDOSH: - case BATTLEFIELD_WG_NPC_COMMANDER_ZANNETH: - case BATTLEFIELD_WG_NPC_TACTICAL_OFFICER_KILRATH: - case BATTLEFIELD_WG_NPC_TACTICAL_OFFICER_AHBRAMIS: - case BATTLEFIELD_WG_NPC_HORDE_WARBRINGER: - case BATTLEFIELD_WG_NPC_BRIGADIER_GENERAL: - case BATTLEFIELD_WG_NPC_SIEGESMITH_STRONGHOOF: - case BATTLEFIELD_WG_NPC_SIEGE_MASTER_STOUTHANDLE: - case BATTLEFIELD_WG_NPC_PRIMALIST_MULFORT: - case BATTLEFIELD_WG_NPC_ANCHORITE_TESSA: - case BATTLEFIELD_WG_NPC_LIEUTENANT_MURP: - case BATTLEFIELD_WG_NPC_SENIOR_DEMOLITIONIST_LEGOSO: - return true; - } - return false; -} - // Here there is all npc keeper spawn point const WintergraspObjectPositionData WGKeepNPC[WG_MAX_KEEP_NPC] = { @@ -1060,10 +1060,10 @@ const WGWorkshopData WorkshopsData[WG_MAX_WORKSHOP] = {BATTLEFIELD_WG_WORKSHOP_SE, WORLDSTATE_WORKSHOP_SE, BATTLEFIELD_WG_TEXT_WORKSHOP_SE_ATTACK, BATTLEFIELD_WG_TEXT_WORKSHOP_SE_TAKEN}, // SW {BATTLEFIELD_WG_WORKSHOP_SW, WORLDSTATE_WORKSHOP_SW, BATTLEFIELD_WG_TEXT_WORKSHOP_SW_ATTACK, BATTLEFIELD_WG_TEXT_WORKSHOP_SW_TAKEN}, - // KEEP WEST - It can't be taken, so it doesn't have a textid - {BATTLEFIELD_WG_WORKSHOP_KEEP_WEST, WORLDSTATE_WORKSHOP_K_W, 0}, - // KEEP EAST - It can't be taken, so it doesn't have a textid - {BATTLEFIELD_WG_WORKSHOP_KEEP_EAST, WORLDSTATE_WORKSHOP_K_E, 0} + // KEEP WEST - It can't be taken + {BATTLEFIELD_WG_WORKSHOP_KEEP_WEST, WORLDSTATE_WORKSHOP_K_W, 0, BATTLEFIELD_WG_TEXT_WORKSHOP_NE_TAKEN}, + // KEEP EAST - It can't be taken + {BATTLEFIELD_WG_WORKSHOP_KEEP_EAST, WORLDSTATE_WORKSHOP_K_E, 0, BATTLEFIELD_WG_TEXT_WORKSHOP_NE_TAKEN} }; // ******************************************************************** diff --git a/src/game/Battlegrounds/Battleground.cpp b/src/game/Battlegrounds/Battleground.cpp index 92ea2721ee..1d38161491 100644 --- a/src/game/Battlegrounds/Battleground.cpp +++ b/src/game/Battlegrounds/Battleground.cpp @@ -289,7 +289,6 @@ inline void Battleground::_CheckSafePositions(uint32 diff) m_ValidStartPositionTimer = 0; Position pos; - Player* player; float x, y, z, o; for (BattlegroundPlayerMap::const_iterator itr = GetPlayers().begin(); itr != GetPlayers().end(); ++itr) { diff --git a/src/game/Battlegrounds/BattlegroundMgr.cpp b/src/game/Battlegrounds/BattlegroundMgr.cpp index 28c0d1abd0..84b338b067 100644 --- a/src/game/Battlegrounds/BattlegroundMgr.cpp +++ b/src/game/Battlegrounds/BattlegroundMgr.cpp @@ -737,7 +737,6 @@ void BattlegroundMgr::BuildBattlegroundListPacket(WorldPacket* data, uint64 guid if (PvPDifficultyEntry const* bracketEntry = GetBattlegroundBracketByLevel(bgt->GetMapId(), player->getLevel())) { uint32 count = 0; - BattlegroundBracketId bracketId = bracketEntry->GetBracketId(); /*for (BattlegroundClientIdsContainer::const_iterator itr = clientIds.begin(); itr != clientIds.end(); ++itr) { *data << uint32(*itr); diff --git a/src/game/Battlegrounds/BattlegroundQueue.cpp b/src/game/Battlegrounds/BattlegroundQueue.cpp index 6a22a720a8..5bbcffb095 100644 --- a/src/game/Battlegrounds/BattlegroundQueue.cpp +++ b/src/game/Battlegrounds/BattlegroundQueue.cpp @@ -989,8 +989,6 @@ bool BGQueueRemoveEvent::Execute(uint64 /*e_time*/, uint32 /*p_time*/) if (!player) return true; - Battleground* bg = sBattlegroundMgr->GetBattleground(m_BgInstanceGUID); - // battleground can be already deleted, bg may be NULL! // check if still in queue for this battleground diff --git a/src/game/Battlegrounds/Zones/BattlegroundIC.cpp b/src/game/Battlegrounds/Zones/BattlegroundIC.cpp index 48be109ae9..9c29cd3559 100644 --- a/src/game/Battlegrounds/Zones/BattlegroundIC.cpp +++ b/src/game/Battlegrounds/Zones/BattlegroundIC.cpp @@ -298,7 +298,6 @@ bool BattlegroundIC::AllNodesConrolledByTeam(TeamId teamId) const bool BattlegroundIC::IsResourceGlutAllowed(TeamId teamId) const { - uint32 count = 0; ICNodeState controlledState = teamId == TEAM_ALLIANCE ? NODE_STATE_CONTROLLED_A : NODE_STATE_CONTROLLED_H; return nodePoint[NODE_TYPE_QUARRY].nodeState == controlledState && nodePoint[NODE_TYPE_REFINERY].nodeState == controlledState; } diff --git a/src/game/Battlegrounds/Zones/BattlegroundSA.cpp b/src/game/Battlegrounds/Zones/BattlegroundSA.cpp index 6f2c2a6d59..47f2b3437b 100644 --- a/src/game/Battlegrounds/Zones/BattlegroundSA.cpp +++ b/src/game/Battlegrounds/Zones/BattlegroundSA.cpp @@ -763,7 +763,6 @@ void BattlegroundSA::DestroyGate(Player* player, GameObject* go) WorldSafeLocsEntry const* BattlegroundSA::GetClosestGraveyard(Player* player) { - uint32 safeloc = 0; WorldSafeLocsEntry const* closest = NULL; float mindist = 999999.0f; float x, y; diff --git a/src/game/Battlegrounds/Zones/BattlegroundWS.cpp b/src/game/Battlegrounds/Zones/BattlegroundWS.cpp index d3d14a4a49..16bb9c7e0b 100644 --- a/src/game/Battlegrounds/Zones/BattlegroundWS.cpp +++ b/src/game/Battlegrounds/Zones/BattlegroundWS.cpp @@ -229,8 +229,6 @@ void BattlegroundWS::EventPlayerClickedOnFlag(Player* player, GameObject* gameOb if (GetStatus() != STATUS_IN_PROGRESS) return; - int32 message_id = 0; - ChatMsg type = CHAT_MSG_BG_SYSTEM_NEUTRAL; player->RemoveAurasWithInterruptFlags(AURA_INTERRUPT_FLAG_ENTER_PVP_COMBAT); // Alliance Flag picked up from base diff --git a/src/game/Chat/Channels/Channel.cpp b/src/game/Chat/Channels/Channel.cpp index 6570d8ca14..420d436a10 100644 --- a/src/game/Chat/Channels/Channel.cpp +++ b/src/game/Chat/Channels/Channel.cpp @@ -517,7 +517,6 @@ void Channel::UnBan(uint64 guid) void Channel::Password(Player const* player, std::string const& pass) { - uint32 sec = player->GetSession()->GetSecurity(); uint64 guid = player->GetGUID(); ChatHandler chat(player->GetSession()); diff --git a/src/game/Chat/Chat.cpp b/src/game/Chat/Chat.cpp index 7ab9baaf49..9e94ec8ee3 100644 --- a/src/game/Chat/Chat.cpp +++ b/src/game/Chat/Chat.cpp @@ -895,7 +895,7 @@ GameObject* ChatHandler::GetObjectGlobalyWithGuidOrNearWithDbGuid(uint32 lowguid CellCoord p(Trinity::ComputeCellCoord(pl->GetPositionX(), pl->GetPositionY())); Cell cell(p); - Trinity::GameObjectWithDbGUIDCheck go_check(*pl, lowguid); + Trinity::GameObjectWithDbGUIDCheck go_check(lowguid); Trinity::GameObjectSearcher<Trinity::GameObjectWithDbGUIDCheck> checker(pl, obj, go_check); TypeContainerVisitor<Trinity::GameObjectSearcher<Trinity::GameObjectWithDbGUIDCheck>, GridTypeMapContainer > object_checker(checker); diff --git a/src/game/DungeonFinding/LFG.h b/src/game/DungeonFinding/LFG.h index 50a4f15274..955a8ce574 100644 --- a/src/game/DungeonFinding/LFG.h +++ b/src/game/DungeonFinding/LFG.h @@ -107,7 +107,7 @@ public: Lfg5Guids() { memset(&guid, 0, 5*8); roles = NULL; } Lfg5Guids(uint64 g) { memset(&guid, 0, 5*8); guid[0] = g; roles = NULL; } Lfg5Guids(Lfg5Guids const& x) { memcpy(guid, x.guid, 5*8); if (x.roles) roles = new LfgRolesMap(*(x.roles)); else roles = NULL; } - Lfg5Guids(Lfg5Guids const& x, bool copyRoles) { memcpy(guid, x.guid, 5*8); roles = NULL; } + Lfg5Guids(Lfg5Guids const& x, bool /*copyRoles*/) { memcpy(guid, x.guid, 5*8); roles = NULL; } ~Lfg5Guids() { delete roles; } void addRoles(LfgRolesMap const& r) { roles = new LfgRolesMap(r); } void clear() { memset(&guid, 0, 5*8); } diff --git a/src/game/Entities/Creature/GossipDef.cpp b/src/game/Entities/Creature/GossipDef.cpp index b685e2654b..209c9d3b10 100644 --- a/src/game/Entities/Creature/GossipDef.cpp +++ b/src/game/Entities/Creature/GossipDef.cpp @@ -180,7 +180,6 @@ void PlayerMenu::SendGossipMenu(uint32 titleTextId, uint64 objectGUID) const data << item.BoxMessage; // accept text (related to money) pop up box, 2.0.3 } - size_t count_pos = data.wpos(); data << uint32(_questMenu.GetMenuItemCount()); // max count 0x20 uint32 count = 0; diff --git a/src/game/Entities/Player/Player.cpp b/src/game/Entities/Player/Player.cpp index 9c9f304593..0907fd855c 100644 --- a/src/game/Entities/Player/Player.cpp +++ b/src/game/Entities/Player/Player.cpp @@ -3314,7 +3314,6 @@ void Player::GiveLevel(uint8 level) void Player::InitTalentForLevel() { - uint8 level = getLevel(); uint32 talentPointsForLevel = CalculateTalentsPoints(); // xinef: more talent points that we have are used, reset @@ -16953,7 +16952,7 @@ void Player::KilledPlayerCredit() if (q_status.Status == QUEST_STATUS_INCOMPLETE && (!GetGroup() || !GetGroup()->isRaidGroup() || qInfo->IsAllowedInRaid(GetMap()->GetDifficulty()))) { // Xinef: PvP Killing quest require player to be in same zone as quest zone (only 2 quests so no doubt, can be extended to conditions in cata ;s) - if (qInfo->HasSpecialFlag(QUEST_SPECIAL_FLAGS_PLAYER_KILL) && GetZoneId() == qInfo->GetZoneOrSort()) + if (qInfo->HasSpecialFlag(QUEST_SPECIAL_FLAGS_PLAYER_KILL) && (qInfo->GetZoneOrSort() >= 0 && GetZoneId() == uint32(qInfo->GetZoneOrSort()))) { uint32 reqkill = qInfo->GetPlayersSlain(); uint16 curkill = q_status.PlayerCount; @@ -16978,8 +16977,6 @@ void Player::KilledPlayerCredit() void Player::KillCreditGO(uint32 entry, uint64 guid) { - bool isCreature = IS_CRE_OR_VEH_GUID(guid); - uint16 addCastCount = 1; for (uint8 i = 0; i < MAX_QUEST_LOG_SIZE; ++i) { @@ -18806,6 +18803,7 @@ void Player::_LoadMailAsynch(PreparedQueryResult result) { do { + bool has_items = false; Field* fields = result->Fetch(); if (fields[14].GetUInt32() != prevMailID) { @@ -18820,7 +18818,7 @@ void Player::_LoadMailAsynch(PreparedQueryResult result) m->receiver = fields[17].GetUInt32(); m->subject = fields[18].GetString(); m->body = fields[19].GetString(); - bool has_items = fields[20].GetBool(); + has_items = fields[20].GetBool(); m->expire_time = time_t(fields[21].GetUInt32()); m->deliver_time = time_t(fields[22].GetUInt32()); m->money = fields[23].GetUInt32(); @@ -18838,7 +18836,7 @@ void Player::_LoadMailAsynch(PreparedQueryResult result) m->state = MAIL_STATE_UNCHANGED; } - if (m && fields[20].GetBool() /*has_items*/ && fields[12].GetUInt32() /*itemEntry*/) + if (m && has_items && fields[12].GetUInt32() /*itemEntry*/) { uint32 itemGuid = fields[11].GetUInt32(); uint32 itemTemplate = fields[12].GetUInt32(); @@ -26814,11 +26812,7 @@ void Player::PrepareCharmAISpells() m_charmAISpells[i] = 0; uint32 damage_type[4] = {0, 0, 0, 0}; - uint32 stun_duration = 0; uint32 periodic_damage = 0; - uint32 b = 0; - uint32 temp_spell = 0; - uint32 temp_damage = 0; for (PlayerSpellMap::iterator itr = m_spells.begin(); itr != m_spells.end(); ++itr) { @@ -26832,8 +26826,6 @@ void Player::PrepareCharmAISpells() if (!spellInfo->SpellFamilyName || spellInfo->IsPassive() || spellInfo->NeedsComboPoints() || (spellInfo->Stances && !spellInfo->HasAttribute(SPELL_ATTR2_NOT_NEED_SHAPESHIFT))) continue; - bool allow = false; - uint8 type = 0; float cast = spellInfo->CalcCastTime() / 1000.0f; if (cast > 3.0f) continue; @@ -26905,7 +26897,7 @@ void Player::PrepareCharmAISpells() m_charmAISpells[SPELL_ROOT_OR_FEAR] = spellInfo->Id; break; } - } + } } } diff --git a/src/game/Entities/Unit/Unit.cpp b/src/game/Entities/Unit/Unit.cpp index 87a519d704..a48b08144d 100644 --- a/src/game/Entities/Unit/Unit.cpp +++ b/src/game/Entities/Unit/Unit.cpp @@ -4042,7 +4042,7 @@ void Unit::_UnapplyAura(AuraApplication * aurApp, AuraRemoveMode removeMode) void Unit::_RemoveNoStackAurasDueToAura(Aura* aura) { - SpellInfo const* spellProto = aura->GetSpellInfo(); + //SpellInfo const* spellProto = aura->GetSpellInfo(); // passive spell special case (only non stackable with ranks) @@ -15015,8 +15015,8 @@ void Unit::ProcDamageAndSpellFor(bool isVictim, Unit* target, uint32 procFlag, u continue; // Triggered spells not triggering additional spells - bool triggered = !spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_WITH_TRIGGERED) ? - (procExtra & PROC_EX_INTERNAL_TRIGGERED && !(procFlag & PROC_FLAG_DONE_TRAP_ACTIVATION)) : false; + //bool triggered = !spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_WITH_TRIGGERED) ? + // (procExtra & PROC_EX_INTERNAL_TRIGGERED && !(procFlag & PROC_FLAG_DONE_TRAP_ACTIVATION)) : false; for (uint8 i = 0; i < MAX_SPELL_EFFECTS; ++i) { diff --git a/src/game/Entities/Unit/Unit.h b/src/game/Entities/Unit/Unit.h index 7f9a8b55b2..8fc08182ec 100644 --- a/src/game/Entities/Unit/Unit.h +++ b/src/game/Entities/Unit/Unit.h @@ -919,7 +919,12 @@ public: m_heal -= amount; } - uint32 GetHeal() const { return m_heal; }; + Unit* GetHealer() const { return m_healer; } + Unit* GetTarget() const { return m_target; } + uint32 GetHeal() const { return m_heal; } + uint32 GetAbsorb() const { return m_absorb; } + SpellInfo const* GetSpellInfo() const { return m_spellInfo; }; + SpellSchoolMask GetSchoolMask() const { return m_schoolMask; }; }; class ProcEventInfo @@ -1323,7 +1328,7 @@ class SafeUnitPointer { public: explicit SafeUnitPointer(Unit* defVal) : ptr(defVal), defaultValue(defVal) {} - SafeUnitPointer(const SafeUnitPointer& p) { ASSERT(false); } + SafeUnitPointer(const SafeUnitPointer& /*p*/) { ASSERT(false); } void Initialize(Unit* defVal) { defaultValue = defVal; ptr = defVal; } ~SafeUnitPointer(); void SetPointedTo(Unit* u); @@ -2405,7 +2410,7 @@ class Unit : public WorldObject // cooldowns virtual bool HasSpellCooldown(uint32 /*spell_id*/) const { return false; } virtual bool HasSpellItemCooldown(uint32 /*spell_id*/, uint32 /*itemid*/) const { return false; } - virtual void AddSpellCooldown(uint32 /*spell_id*/, uint32 /*itemid*/, uint32 /*end_time*/, bool needSendToClient = false, bool forceSendToSpectator = false) {} + virtual void AddSpellCooldown(uint32 /*spell_id*/, uint32 /*itemid*/, uint32 /*end_time*/, bool needSendToClient = false, bool forceSendToSpectator = false); bool CanApplyResilience() const { return m_applyResilience; } diff --git a/src/game/Globals/ObjectMgr.h b/src/game/Globals/ObjectMgr.h index bca5b23522..d85705b00c 100644 --- a/src/game/Globals/ObjectMgr.h +++ b/src/game/Globals/ObjectMgr.h @@ -61,8 +61,8 @@ struct TempSummonGroupKey bool operator<(TempSummonGroupKey const& rhs) const { - // memcmp is only reliable if struct doesn't have any padding (packed) - return memcmp(this, &rhs, sizeof(TempSummonGroupKey)) < 0; + return std::tie(_summonerEntry, _summonerType, _summonGroup) < + std::tie(rhs._summonerEntry, rhs._summonerType, rhs._summonGroup); } private: diff --git a/src/game/Grids/Notifiers/GridNotifiers.h b/src/game/Grids/Notifiers/GridNotifiers.h index a011e71a4a..18ea36ba1f 100644 --- a/src/game/Grids/Notifiers/GridNotifiers.h +++ b/src/game/Grids/Notifiers/GridNotifiers.h @@ -720,13 +720,12 @@ namespace Trinity class GameObjectWithDbGUIDCheck { public: - GameObjectWithDbGUIDCheck(WorldObject const& obj, uint32 db_guid) : i_obj(obj), i_db_guid(db_guid) {} + GameObjectWithDbGUIDCheck(uint32 db_guid) : i_db_guid(db_guid) {} bool operator()(GameObject const* go) const { return go->GetDBTableGUIDLow() == i_db_guid; } private: - WorldObject const& i_obj; uint32 i_db_guid; }; @@ -862,13 +861,12 @@ namespace Trinity class CreatureWithDbGUIDCheck { public: - CreatureWithDbGUIDCheck(WorldObject const* obj, uint32 lowguid) : i_obj(obj), i_lowguid(lowguid) {} + CreatureWithDbGUIDCheck(uint32 lowguid) : i_lowguid(lowguid) {} bool operator()(Creature* u) { return u->GetDBTableGUIDLow() == i_lowguid; } private: - WorldObject const* i_obj; uint32 i_lowguid; }; @@ -1441,7 +1439,7 @@ namespace Trinity { public: explicit RandomCheck(uint8 chance) : _chance(chance) { } - bool operator()(WorldObject const* object) const + bool operator()(WorldObject const* /*object*/) const { return roll_chance_i(_chance); } diff --git a/src/game/Grids/ObjectGridLoader.cpp b/src/game/Grids/ObjectGridLoader.cpp index ca9748a84a..0c97bdf2b2 100644 --- a/src/game/Grids/ObjectGridLoader.cpp +++ b/src/game/Grids/ObjectGridLoader.cpp @@ -23,7 +23,7 @@ class ObjectWorldLoader { public: explicit ObjectWorldLoader(ObjectGridLoader& gloader) - : i_cell(gloader.i_cell), i_grid(gloader.i_grid), i_map(gloader.i_map), i_corpses (0) + : i_cell(gloader.i_cell), i_map(gloader.i_map), i_grid(gloader.i_grid), i_corpses (0) {} void Visit(CorpseMapType &m); @@ -32,9 +32,9 @@ class ObjectWorldLoader private: Cell i_cell; - NGridType &i_grid; Map* i_map; public: + NGridType &i_grid; uint32 i_corpses; }; diff --git a/src/game/Guilds/Guild.h b/src/game/Guilds/Guild.h index f0359ebda7..c2f66ffe79 100644 --- a/src/game/Guilds/Guild.h +++ b/src/game/Guilds/Guild.h @@ -457,6 +457,7 @@ private: ~LogHolder(); uint8 GetSize() const { return uint8(m_log.size()); } + uint32 GetGuildId() const { return m_guildId; } // Checks if new log entry can be added to holder when loading from DB inline bool CanInsert() const { return m_log.size() < m_maxRecords; } // Adds event from DB to collection diff --git a/src/game/Handlers/AuctionHouseHandler.cpp b/src/game/Handlers/AuctionHouseHandler.cpp index d3d6a7446a..f8c0b178a1 100644 --- a/src/game/Handlers/AuctionHouseHandler.cpp +++ b/src/game/Handlers/AuctionHouseHandler.cpp @@ -578,7 +578,6 @@ void WorldSession::HandleAuctionRemoveItem(WorldPacket & recvData) auction->DeleteFromDB(trans); CharacterDatabase.CommitTransaction(trans); - uint32 item_template = auction->item_template; sAuctionMgr->RemoveAItem(auction->item_guidlow); auctionHouse->RemoveAuction(auction); } diff --git a/src/game/Loot/LootMgr.cpp b/src/game/Loot/LootMgr.cpp index 3d5d4f73ae..f1f2875dcf 100644 --- a/src/game/Loot/LootMgr.cpp +++ b/src/game/Loot/LootMgr.cpp @@ -869,7 +869,7 @@ ByteBuffer& operator<<(ByteBuffer& b, LootView const& lv) { if (!l.items[i].is_looted && !l.items[i].freeforall && l.items[i].conditions.empty() && l.items[i].AllowedForPlayer(lv.viewer)) { - uint8 slot_type; + uint8 slot_type = 0; if (l.items[i].is_blocked) // for ML & restricted is_blocked = !is_underthreshold { diff --git a/src/game/Maps/Map.cpp b/src/game/Maps/Map.cpp index 02733b7aea..c073d7a842 100644 --- a/src/game/Maps/Map.cpp +++ b/src/game/Maps/Map.cpp @@ -107,7 +107,7 @@ bool Map::ExistVMap(uint32 mapid, int gx, int gy) void Map::LoadMMap(int gx, int gy) { - if (!MMAP::MMapFactory::IsPathfindingEnabled(this, true)) // pussywizard + if (!MMAP::MMapFactory::IsPathfindingEnabled(this)) // pussywizard return; int mmapLoadResult = MMAP::MMapFactory::createOrGetMMapManager()->loadMap(GetId(), gx, gy); diff --git a/src/game/Misc/AsyncAuctionListing.h b/src/game/Misc/AsyncAuctionListing.h index 710f531733..3fb59e028e 100644 --- a/src/game/Misc/AsyncAuctionListing.h +++ b/src/game/Misc/AsyncAuctionListing.h @@ -13,6 +13,7 @@ class AuctionListOwnerItemsDelayEvent : public BasicEvent virtual bool Execute(uint64 e_time, uint32 p_time); virtual void Abort(uint64 e_time) {} + bool getOwner() { return owner; } private: WorldPacket data; diff --git a/src/game/Scripting/MapScripts.cpp b/src/game/Scripting/MapScripts.cpp index 918b6ef2bd..9e9e9f28a4 100644 --- a/src/game/Scripting/MapScripts.cpp +++ b/src/game/Scripting/MapScripts.cpp @@ -262,7 +262,7 @@ inline GameObject* Map::_FindGameObject(WorldObject* searchObject, uint32 guid) CellCoord p(Trinity::ComputeCellCoord(searchObject->GetPositionX(), searchObject->GetPositionY())); Cell cell(p); - Trinity::GameObjectWithDbGUIDCheck goCheck(*searchObject, guid); + Trinity::GameObjectWithDbGUIDCheck goCheck(guid); Trinity::GameObjectSearcher<Trinity::GameObjectWithDbGUIDCheck> checker(searchObject, gameobject, goCheck); TypeContainerVisitor<Trinity::GameObjectSearcher<Trinity::GameObjectWithDbGUIDCheck>, GridTypeMapContainer > objectChecker(checker); @@ -825,7 +825,7 @@ void Map::ScriptsProcess() CellCoord p(Trinity::ComputeCellCoord(wSource->GetPositionX(), wSource->GetPositionY())); Cell cell(p); - Trinity::CreatureWithDbGUIDCheck target_check(wSource, step.script->CallScript.CreatureEntry); + Trinity::CreatureWithDbGUIDCheck target_check(step.script->CallScript.CreatureEntry); Trinity::CreatureSearcher<Trinity::CreatureWithDbGUIDCheck> checker(wSource, cTarget, target_check); TypeContainerVisitor<Trinity::CreatureSearcher <Trinity::CreatureWithDbGUIDCheck>, GridTypeMapContainer > unit_checker(checker); diff --git a/src/game/Scripting/ScriptMgr.h b/src/game/Scripting/ScriptMgr.h index 7727935e90..260d8d666c 100644 --- a/src/game/Scripting/ScriptMgr.h +++ b/src/game/Scripting/ScriptMgr.h @@ -289,7 +289,7 @@ class FormulaScript : public ScriptObject virtual void OnGroupRateCalculation(float& /*rate*/, uint32 /*count*/, bool /*isRaid*/) { } // Called after calculating arena rating changes - virtual void OnAfterArenaRatingCalculation(Battleground *const bg, int32 &winnerMatchmakerChange, int32 &loserMatchmakerChange, int32 &winnerChange, int32 &loserChange) { }; + virtual void OnAfterArenaRatingCalculation(Battleground *const /*bg*/, int32& /*winnerMatchmakerChange*/, int32& /*loserMatchmakerChange*/, int32& /*winnerChange*/, int32& /*loserChange*/) { }; }; template<class TMap> class MapScript : public UpdatableScript<TMap> @@ -446,7 +446,7 @@ public: virtual void ModifyHealRecieved(Unit* /*target*/, Unit* /*attacker*/, uint32& /*damage*/) { } //Called when Damage is Dealt - virtual uint32 DealDamage(Unit* AttackerUnit, Unit *pVictim, uint32 damage, DamageEffectType damagetype) { return damage; } + virtual uint32 DealDamage(Unit* /*AttackerUnit*/, Unit* /*pVictim*/, uint32 damage, DamageEffectType /*damagetype*/) { return damage; } virtual void OnBeforeRollMeleeOutcomeAgainst(const Unit* /*attacker*/, const Unit* /*victim*/, WeaponAttackType /*attType*/, int32 &/*attackerMaxSkillValueForLevel*/, int32 &/*victimMaxSkillValueForLevel*/, int32 &/*attackerWeaponSkill*/, int32 &/*victimDefenseSkill*/, int32& /*crit_chance*/, int32& /*miss_chance*/ , int32& /*dodge_chance*/ , int32& /*parry_chance*/ , int32& /*block_chance*/ ) { }; }; @@ -887,13 +887,13 @@ class PlayerScript : public ScriptObject virtual void OnPlayerJoinArena(Player* /*player*/) { } //After looting item - virtual void OnLootItem(Player* player, Item* item, uint32 count, uint64 lootguid) { } + virtual void OnLootItem(Player* /*player*/, Item* /*item*/, uint32 /*count*/, uint64 /*lootguid*/) { } //After creating item (eg profession item creation) - virtual void OnCreateItem(Player* player, Item* item, uint32 count) { } + virtual void OnCreateItem(Player* /*player*/, Item* /*item*/, uint32 /*count*/) { } //After receiving item as a quest reward - virtual void OnQuestRewardItem(Player* player, Item* item, uint32 count) { } + virtual void OnQuestRewardItem(Player* /*player*/, Item* /*item*/, uint32 /*count*/) { } //Before buying something from any vendor virtual void OnBeforeBuyItemFromVendor(Player* /*player*/, uint64 /*vendorguid*/, uint32 /*vendorslot*/, uint32 &/*item*/, uint8 /*count*/, uint8 /*bag*/, uint8 /*slot*/) { }; diff --git a/src/game/Server/WorldSocket.cpp b/src/game/Server/WorldSocket.cpp index 0e3f05e840..c774ba134e 100644 --- a/src/game/Server/WorldSocket.cpp +++ b/src/game/Server/WorldSocket.cpp @@ -475,7 +475,7 @@ int WorldSocket::handle_input_header (void) if ((header.size < 4) || (header.size > 10240) || (header.cmd > 10240)) { Player* _player = m_Session ? m_Session->GetPlayer() : NULL; - //sLog->outError("WorldSocket::handle_input_header(): client (account: %u, char [GUID: %u, name: %s]) sent malformed packet (size: %d, cmd: %d)", m_Session ? m_Session->GetAccountId() : 0, _player ? _player->GetGUIDLow() : 0, _player ? _player->GetName().c_str() : "<none>", header.size, header.cmd); + sLog->outError("WorldSocket::handle_input_header(): client (account: %u, char [GUID: %u, name: %s]) sent malformed packet (size: %d, cmd: %d)", m_Session ? m_Session->GetAccountId() : 0, _player ? _player->GetGUIDLow() : 0, _player ? _player->GetName().c_str() : "<none>", header.size, header.cmd); errno = EINVAL; return -1; @@ -752,8 +752,8 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket) recvPacket >> account; recvPacket >> loginServerType; recvPacket >> clientSeed; - recvPacket >> loginServerType; recvPacket >> regionID; + recvPacket >> battlegroupID; recvPacket >> realm; recvPacket >> DosResponse; recvPacket.read(digest, 20); diff --git a/src/game/Spells/Spell.cpp b/src/game/Spells/Spell.cpp index 29f0825621..0674b238c0 100644 --- a/src/game/Spells/Spell.cpp +++ b/src/game/Spells/Spell.cpp @@ -5750,7 +5750,7 @@ SpellCastResult Spell::CheckCast(bool strict) return SPELL_FAILED_BAD_TARGETS; // Xinef: Pass only explicit unit target spells // pussywizard: - if (MMAP::MMapFactory::IsPathfindingEnabled(m_caster->FindMap(), true) && m_spellInfo->NeedsExplicitUnitTarget()) + if (MMAP::MMapFactory::IsPathfindingEnabled(m_caster->FindMap()) && m_spellInfo->NeedsExplicitUnitTarget()) { Unit* target = m_targets.GetUnitTarget(); if (!target) diff --git a/src/game/Spells/Spell.h b/src/game/Spells/Spell.h index d431117207..a2d648f93b 100644 --- a/src/game/Spells/Spell.h +++ b/src/game/Spells/Spell.h @@ -506,7 +506,7 @@ class Spell void CleanupTargetList(); void SetSpellValue(SpellValueMod mod, int32 value); - SpellValue const* const GetSpellValue() { return m_spellValue; } + SpellValue const* GetSpellValue() { return m_spellValue; } // xinef: moved to public void LoadScripts(); diff --git a/src/game/Spells/SpellEffects.cpp b/src/game/Spells/SpellEffects.cpp index a6e97b7121..b107ae230b 100644 --- a/src/game/Spells/SpellEffects.cpp +++ b/src/game/Spells/SpellEffects.cpp @@ -2872,8 +2872,6 @@ void Spell::EffectEnchantItemPrismatic(SpellEffIndex effIndex) if (!itemTarget) return; - Player* p_caster = m_caster->ToPlayer(); - uint32 enchant_id = m_spellInfo->Effects[effIndex].MiscValue; if (!enchant_id) return; diff --git a/src/game/Spells/SpellInfo.cpp b/src/game/Spells/SpellInfo.cpp index c61e9463b5..46d5b708b4 100644 --- a/src/game/Spells/SpellInfo.cpp +++ b/src/game/Spells/SpellInfo.cpp @@ -2018,7 +2018,7 @@ AuraStateType SpellInfo::LoadAuraState() const uint32 StealthPreventionSpellList[] = { 9991, 35331, 9806, 35325 }; // Goes through each of the spells and identifies them as Stealth Prevention Spell. - for (int i = 0; i < sizeof(StealthPreventionSpellList) / sizeof(uint32); i++) { + for (uint32 i = 0; i < sizeof(StealthPreventionSpellList) / sizeof(uint32); i++) { if (Id == StealthPreventionSpellList[i]) { return AURA_STATE_FAERIE_FIRE; } diff --git a/src/scripts/Commands/cs_misc.cpp b/src/scripts/Commands/cs_misc.cpp index 0a58963834..a1f36e64ff 100644 --- a/src/scripts/Commands/cs_misc.cpp +++ b/src/scripts/Commands/cs_misc.cpp @@ -3082,10 +3082,10 @@ public: if (flags.empty()) flags = "None"; - Player* p = ObjectAccessor::FindPlayerInOrOutOfWorld((*itr).guid); + /*Player* p = ObjectAccessor::FindPlayerInOrOutOfWorld((*itr).guid); const char* onlineState = p ? "online" : "offline"; - /*handler->PSendSysMessage(LANG_GROUP_PLAYER_NAME_GUID, slot.name.c_str(), onlineState, + handler->PSendSysMessage(LANG_GROUP_PLAYER_NAME_GUID, slot.name.c_str(), onlineState, GUID_LOPART(slot.guid), flags.c_str(), lfg::GetRolesString(slot.roles).c_str());*/ } } diff --git a/src/scripts/Commands/cs_server.cpp b/src/scripts/Commands/cs_server.cpp index c725bcffed..a0055f594a 100644 --- a/src/scripts/Commands/cs_server.cpp +++ b/src/scripts/Commands/cs_server.cpp @@ -104,7 +104,7 @@ public: handler->PSendSysMessage("Connected players: %u. Characters in world: %u.", activeSessionCount, playerCount); else handler->PSendSysMessage("Connected players: %u. Characters in world: %u. Queue: %u.", activeSessionCount, playerCount, queuedSessionCount); - //handler->PSendSysMessage("Connection peak: %u.", connPeak); + handler->PSendSysMessage("Connection peak: %u.", connPeak); handler->PSendSysMessage(LANG_UPTIME, uptime.c_str()); handler->PSendSysMessage("Update time diff: %ums, average: %ums.", updateTime, avgUpdateTime); @@ -126,14 +126,14 @@ public: return true; } - static bool HandleServerShutDownCancelCommand(ChatHandler* handler, char const* /*args*/) + static bool HandleServerShutDownCancelCommand(ChatHandler* /*handler*/, char const* /*args*/) { sWorld->ShutdownCancel(); return true; } - static bool HandleServerShutDownCommand(ChatHandler* handler, char const* args) + static bool HandleServerShutDownCommand(ChatHandler* /*handler*/, char const* args) { if (!*args) return false; @@ -169,7 +169,7 @@ public: return true; } - static bool HandleServerRestartCommand(ChatHandler* handler, char const* args) + static bool HandleServerRestartCommand(ChatHandler* /*handler*/, char const* args) { if (!*args) return false; diff --git a/src/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp b/src/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp index 221cdfc923..da072be449 100644 --- a/src/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp +++ b/src/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp @@ -105,9 +105,9 @@ static Wave Wave6[]= // 27 sec }; */ -Position const GythLoc = { 211.762f, -397.5885f, 111.1817f, 4.747295f }; +/*Position const GythLoc = { 211.762f, -397.5885f, 111.1817f, 4.747295f }; Position const Teleport1Loc = { 194.2993f, -474.0814f, 121.4505f, -0.01225555f }; -Position const Teleport2Loc = { 216.485f, -434.93f, 110.888f, -0.01225555f }; +Position const Teleport2Loc = { 216.485f, -434.93f, 110.888f, -0.01225555f };*/ enum Events { diff --git a/src/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp b/src/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp index 3e6ccf55d7..9a2e90b6d8 100644 --- a/src/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp +++ b/src/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp @@ -52,7 +52,7 @@ struct InfernalPoint #define INFERNAL_Z 275.5f -static InfernalPoint InfernalPoints[] = +/*static InfernalPoint InfernalPoints[] = { { -10922.8f, -1985.2f }, { -10916.2f, -1996.2f }, @@ -72,7 +72,7 @@ static InfernalPoint InfernalPoints[] = { -10984.0f, -2019.3f }, { -10932.8f, -1979.6f }, { -10935.7f, -1996.0f } -}; +};*/ //---------Infernal code first @@ -237,7 +237,7 @@ public: void SummonAxes() { - Creature* axe = me->SummonCreature(MALCHEZARS_AXE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 10000); + me->SummonCreature(MALCHEZARS_AXE, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 10000); } void EnfeebleHealthEffect() diff --git a/src/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp b/src/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp index fc555b4722..38de299f9c 100644 --- a/src/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp +++ b/src/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp @@ -284,8 +284,8 @@ public: uint32 OperaEvent; uint32 OzDeathCount; uint32 OptionalBossCount; - uint32 m_auiEncounter[MAX_ENCOUNTERS]; - uint32 m_uiTeam; + //uint32 m_auiEncounter[MAX_ENCOUNTERS]; + //uint32 m_uiTeam; uint64 m_uiCurtainGUID; uint64 m_uiStageDoorLeftGUID; uint64 m_uiStageDoorRightGUID; @@ -293,14 +293,14 @@ public: uint64 m_uiTerestianGUID; uint64 m_uiMoroesGUID; uint64 m_uiNightBaneGUID; - uint64 EchoOfMedivhGUID; + //uint64 EchoOfMedivhGUID; uint64 m_uiLibraryDoor; // Door at Shade of Aran uint64 m_uiMassiveDoor; // Door at Netherspite uint64 m_uiSideEntranceDoor; // Side Entrance uint64 m_uiGamesmansDoor; // Door before Chess uint64 m_uiGamesmansExitDoor; // Door after Chess uint64 m_uiNetherspaceDoor; // Door at Malchezaar - uint64 m_uiServantsAccessDoor; // Door to Brocken Stair + //uint64 m_uiServantsAccessDoor; // Door to Brocken Stair uint64 MastersTerraceDoor[2]; uint64 ImageGUID; uint64 DustCoveredChest; diff --git a/src/scripts/EasternKingdoms/Karazhan/karazhan.cpp b/src/scripts/EasternKingdoms/Karazhan/karazhan.cpp index c707be0742..8af6ac53fa 100644 --- a/src/scripts/EasternKingdoms/Karazhan/karazhan.cpp +++ b/src/scripts/EasternKingdoms/Karazhan/karazhan.cpp @@ -411,7 +411,7 @@ public: #define SAY_DIALOG_MEDIVH_9 "He should not have angered me. I must go... recover my strength now..." -static float MedivPos[4] = {-11161.49f, -1902.24f, 91.48f, 1.94f}; +//static float MedivPos[4] = {-11161.49f, -1902.24f, 91.48f, 1.94f}; static float ArcanagosPos[4] = {-11169.75f, -1881.48f, 107.39f, 4.83f}; class npc_image_of_medivh : public CreatureScript diff --git a/src/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp b/src/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp index d352d49198..6f22e93443 100644 --- a/src/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp +++ b/src/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp @@ -310,10 +310,10 @@ enum ZulianProwlerEvents EVENT_ATTACK = 1 }; -Position const PosProwlerCenter[1] = +/*Position const PosProwlerCenter[1] = { { -11556.7f, -1631.344f, 41.2994f, 0.0f } -}; +};*/ class npc_zulian_prowler : public CreatureScript { diff --git a/src/scripts/Events/childrens_week.cpp b/src/scripts/Events/childrens_week.cpp index a2d519ccbd..e6c579cbda 100644 --- a/src/scripts/Events/childrens_week.cpp +++ b/src/scripts/Events/childrens_week.cpp @@ -673,7 +673,6 @@ class npc_the_etymidian : public CreatureScript private: uint32 timer; int8 phase; - uint32 GOtimer; uint64 playerGUID; uint64 orphanGUID; @@ -836,7 +835,6 @@ class npc_alexstraza_the_lifebinder : public CreatureScript uint32 timer; uint64 playerGUID; uint64 orphanGUID; - uint64 alexstraszaGUID; }; diff --git a/src/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp b/src/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp index 545ec39408..cd98b9d8c1 100644 --- a/src/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp +++ b/src/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp @@ -393,8 +393,6 @@ class spell_black_morass_corrupt_medivh : public SpellScriptLoader { OnEffectPeriodic += AuraEffectPeriodicFn(spell_black_morass_corrupt_medivh_AuraScript::PeriodicTick, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); } - - InstanceScript* _instance; }; AuraScript* GetAuraScript() const diff --git a/src/scripts/Kalimdor/zone_moonglade.cpp b/src/scripts/Kalimdor/zone_moonglade.cpp index e93a02a1ca..b432be1aed 100644 --- a/src/scripts/Kalimdor/zone_moonglade.cpp +++ b/src/scripts/Kalimdor/zone_moonglade.cpp @@ -261,7 +261,7 @@ float const Clintar_spirit_WP[41][5] = }; Position const AspectRavenSummon = {7472.96f, -3074.18f, 427.566f, 0.0f}; -Position const ClintarSpiritSummon = {7459.2275f, -3122.5632f, 438.9842f, 0.8594f}; +//Position const ClintarSpiritSummon = {7459.2275f, -3122.5632f, 438.9842f, 0.8594f}; enum ClintarSpirit { diff --git a/src/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp b/src/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp index e2af8e2018..e88d0c1fbb 100644 --- a/src/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp +++ b/src/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp @@ -150,10 +150,10 @@ enum Events const Position portalPos[4] = { - {3247.29f, 529.804f, 58.9595f}, - {3248.62f, 646.739f, 85.2939f}, - {3151.20f, 517.862f, 90.3389f}, - {3351.78f, 517.138f, 99.1620f}, + {3247.29f, 529.804f, 58.9595f, 0.0f}, + {3248.62f, 646.739f, 85.2939f, 0.0f}, + {3151.20f, 517.862f, 90.3389f, 0.0f}, + {3351.78f, 517.138f, 99.1620f, 0.0f}, }; const Position EggsPos[12] = diff --git a/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp b/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp index f94d942b2c..582d068e6c 100644 --- a/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp +++ b/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp @@ -2444,7 +2444,6 @@ public: if (!go->loot.items.size()) return false; - uint8 invalidCount = 0; for( std::vector<LootItem>::iterator itr = go->loot.items.begin(); itr != go->loot.items.end(); ++itr ) if( ItemTemplate const *iProto = sObjectMgr->GetItemTemplate((*itr).itemid) ) if( ((iProto->Flags2 & ITEM_FLAGS_EXTRA_HORDE_ONLY) && plr->GetTeamId() != TEAM_HORDE) || ((iProto->Flags2 & ITEM_FLAGS_EXTRA_ALLIANCE_ONLY) && plr->GetTeamId() != TEAM_ALLIANCE) ) diff --git a/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp b/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp index a5391892e9..f3fcc4aeb2 100644 --- a/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp +++ b/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp @@ -831,7 +831,7 @@ class spell_valkyr_touch : public SpellScriptLoader { uint32 absorb=0; uint32 resist=0; - CleanDamage cleanDamage = CleanDamage(0, 0, BASE_ATTACK, MELEE_HIT_NORMAL); + CleanDamage(0, 0, BASE_ATTACK, MELEE_HIT_NORMAL); int32 dmg = urand(2925,3075)*(caster->GetMap()->GetDifficulty()-1); if (caster->CanApplyResilience()) Unit::ApplyResilience(plr, NULL, &dmg, false, CR_CRIT_TAKEN_SPELL); diff --git a/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp b/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp index b72079e38f..9a5d3953bc 100644 --- a/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp +++ b/src/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp @@ -155,18 +155,17 @@ public: bool IsEncounterInProgress() const { - uint8 aliveCount = 0; Map::PlayerList const &pl = instance->GetPlayers(); for( Map::PlayerList::const_iterator itr = pl.begin(); itr != pl.end(); ++itr ) if( Player* plr = itr->GetSource() ) if( plr->IsAlive() && !plr->IsGameMaster() ) return EncounterStatus == IN_PROGRESS; // found alive player - + if( EncounterStatus != NOT_STARTED ) *(const_cast<uint32*>(&EncounterStatus)) = NOT_STARTED; return false; } - + void OnCreatureCreate(Creature* creature) { switch( creature->GetEntry() ) diff --git a/src/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp b/src/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp index 22cc61f523..d33d4e4d28 100644 --- a/src/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp +++ b/src/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp @@ -158,7 +158,7 @@ public: void SpellHitTarget(Unit* target, const SpellInfo* spell) { - if (spell->Id == SPELL_SARONITE_TRIGGERED) + if (spell->Id == uint32(SPELL_SARONITE_TRIGGERED)) { if (bCanSayBoulderHit) { @@ -166,7 +166,7 @@ public: Talk(SAY_BOULDER_HIT); } } - if (spell->Id == SPELL_FORGE_BLADE) + if (spell->Id == uint32(SPELL_FORGE_BLADE)) { events.RescheduleEvent(EVENT_SPELL_CHILLING_WAVE, 10000); SetEquipmentSlots(false, EQUIP_ID_SWORD); @@ -179,7 +179,7 @@ public: me->SetTarget(me->GetVictim()->GetGUID()); } } - else if (spell->Id == SPELL_FORGE_MACE) + else if (spell->Id == uint32(SPELL_FORGE_MACE)) { events.RescheduleEvent(EVENT_SPELL_DEEP_FREEZE, 10000); SetEquipmentSlots(false, EQUIP_ID_MACE); diff --git a/src/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp b/src/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp index 39afc6c04d..b72aea5b83 100644 --- a/src/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp +++ b/src/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp @@ -954,7 +954,7 @@ public: me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_NONE); me->GetMotionMaster()->MovePoint(2, TSCenterPos); - float ZeroAngle = TSSpawnPos.GetAngle(&TSMidPos); + TSSpawnPos.GetAngle(&TSMidPos); for (std::list<uint64>::iterator itr = summons.begin(); itr != summons.end(); ++itr) if (Creature* c = pInstance->instance->GetCreature(*itr)) @@ -1502,7 +1502,7 @@ public: void HandleEffectPeriodic(AuraEffect const * aurEff) { - if (aurEff->GetTickNumber() == aurEff->GetTotalTicks()) + if (aurEff->GetTotalTicks() >= 0 && aurEff->GetTickNumber() == uint32(aurEff->GetTotalTicks())) if (Unit* target = GetTarget()) target->CastSpell(target, 69604, true); } diff --git a/src/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp b/src/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp index c6f0c4e3ea..886d3a43e9 100644 --- a/src/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp +++ b/src/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp @@ -53,11 +53,11 @@ enum Misc static Position mojoPosition[] = { - {1663.1f, 743.6f, 143.1f}, - {1669.97f, 753.7f, 143.1f}, - {1680.7f, 750.7f, 143.1f}, - {1680.7f, 737.1f, 143.1f}, - {1670.4f, 733.5f, 143.1f} + {1663.1f, 743.6f, 143.1f, 0.0f}, + {1669.97f, 753.7f, 143.1f, 0.0f}, + {1680.7f, 750.7f, 143.1f, 0.0f}, + {1680.7f, 737.1f, 143.1f, 0.0f}, + {1670.4f, 733.5f, 143.1f, 0.0f} }; class RestoreFight : public BasicEvent diff --git a/src/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp b/src/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp index ae4984b6f0..aac8788271 100644 --- a/src/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp +++ b/src/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp @@ -1665,8 +1665,6 @@ class spell_valanar_kinetic_bomb_summon : public SpellScriptLoader { BeforeCast += SpellCastFn(spell_valanar_kinetic_bomb_summon_SpellScript::SelectDest); } - - uint32 _targetCount; }; SpellScript* GetSpellScript() const diff --git a/src/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp b/src/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp index 1a1199d200..58abaa0021 100644 --- a/src/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp +++ b/src/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp @@ -221,7 +221,7 @@ Position const chokePos[6] = {-510.7041f, 2211.069f, 546.5298f, 0.0f} // back right }; -Position const finalPos = {-563.7552f, 2211.328f, 538.7848f, 0.0f}; +//Position const finalPos = {-563.7552f, 2211.328f, 538.7848f, 0.0f}; class boss_deathbringer_saurfang : public CreatureScript { diff --git a/src/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp b/src/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp index 9e1bd9c565..b9f519bbe8 100644 --- a/src/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp +++ b/src/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp @@ -198,34 +198,34 @@ Position const SkybreakerTeleportExit = { -17.55738f, -0.090421f, 21.18366f uint32 const MuradinExitPathSize = 10; Position const MuradinExitPath[MuradinExitPathSize] = { - { 8.130936f, -0.2699585f, 20.31728f }, - { 6.380936f, -0.2699585f, 20.31728f }, - { 3.507703f, 0.02986573f, 20.78463f }, - { -2.767633f, 3.743143f, 20.37663f }, - { -4.017633f, 4.493143f, 20.12663f }, - { -7.242224f, 6.856013f, 20.03468f }, - { -7.742224f, 8.606013f, 20.78468f }, - { -7.992224f, 9.856013f, 21.28468f }, - { -12.24222f, 23.10601f, 21.28468f }, - { -14.88477f, 25.20844f, 21.59985f }, + { 8.130936f, -0.2699585f, 20.31728f, 0.0f }, + { 6.380936f, -0.2699585f, 20.31728f, 0.0f }, + { 3.507703f, 0.02986573f, 20.78463f, 0.0f }, + { -2.767633f, 3.743143f, 20.37663f, 0.0f }, + { -4.017633f, 4.493143f, 20.12663f, 0.0f }, + { -7.242224f, 6.856013f, 20.03468f, 0.0f }, + { -7.742224f, 8.606013f, 20.78468f, 0.0f }, + { -7.992224f, 9.856013f, 21.28468f, 0.0f }, + { -12.24222f, 23.10601f, 21.28468f, 0.0f }, + { -14.88477f, 25.20844f, 21.59985f, 0.0f }, }; uint32 const SaurfangExitPathSize = 13; Position const SaurfangExitPath[SaurfangExitPathSize] = { - { 30.43987f, 0.1475817f, 36.10674f }, - { 21.36141f, -3.056458f, 35.42970f }, - { 19.11141f, -3.806458f, 35.42970f }, - { 19.01736f, -3.299440f, 35.39428f }, - { 18.6747f, -5.862823f, 35.66611f }, - { 18.6747f, -7.862823f, 35.66611f }, - { 18.1747f, -17.36282f, 35.66611f }, - { 18.1747f, -22.61282f, 35.66611f }, - { 17.9247f, -24.36282f, 35.41611f }, - { 17.9247f, -26.61282f, 35.66611f }, - { 17.9247f, -27.86282f, 35.66611f }, - { 17.9247f, -29.36282f, 35.66611f }, - { 15.33203f, -30.42621f, 35.93796f } + { 30.43987f, 0.1475817f, 36.10674f, 0.0f }, + { 21.36141f, -3.056458f, 35.42970f, 0.0f }, + { 19.11141f, -3.806458f, 35.42970f, 0.0f }, + { 19.01736f, -3.299440f, 35.39428f, 0.0f }, + { 18.6747f, -5.862823f, 35.66611f, 0.0f }, + { 18.6747f, -7.862823f, 35.66611f, 0.0f }, + { 18.1747f, -17.36282f, 35.66611f, 0.0f }, + { 18.1747f, -22.61282f, 35.66611f, 0.0f }, + { 17.9247f, -24.36282f, 35.41611f, 0.0f }, + { 17.9247f, -26.61282f, 35.66611f, 0.0f }, + { 17.9247f, -27.86282f, 35.66611f, 0.0f }, + { 17.9247f, -29.36282f, 35.66611f, 0.0f }, + { 15.33203f, -30.42621f, 35.93796f, 0.0f } }; enum PassengerSlots diff --git a/src/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp b/src/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp index a966d55d7a..630abbe68d 100644 --- a/src/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp +++ b/src/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp @@ -926,8 +926,6 @@ class spell_putricide_slime_puddle_spawn : public SpellScriptLoader { BeforeCast += SpellCastFn(spell_putricide_slime_puddle_spawn_SpellScript::SelectDest); } - - uint32 _targetCount; }; SpellScript* GetSpellScript() const diff --git a/src/scripts/Northrend/Naxxramas/boss_maexxna.cpp b/src/scripts/Northrend/Naxxramas/boss_maexxna.cpp index aaad498f29..1596c097be 100644 --- a/src/scripts/Northrend/Naxxramas/boss_maexxna.cpp +++ b/src/scripts/Northrend/Naxxramas/boss_maexxna.cpp @@ -38,9 +38,9 @@ enum Misc const Position PosWrap[3] = { - {3546.796f, -3869.082f, 296.450f}, - {3531.271f, -3847.424f, 299.450f}, - {3497.067f, -3843.384f, 302.384f} + {3546.796f, -3869.082f, 296.450f, 0.0f}, + {3531.271f, -3847.424f, 299.450f, 0.0f}, + {3497.067f, -3843.384f, 302.384f, 0.0f} }; class boss_maexxna : public CreatureScript diff --git a/src/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp b/src/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp index 405a4276f3..10cd42de91 100644 --- a/src/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp +++ b/src/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp @@ -286,7 +286,7 @@ class spell_boss_magus_telestra_gravity_well : public SpellScriptLoader { pos.Relocate(GetCaster()->GetPositionX(), GetCaster()->GetPositionY(), GetCaster()->GetPositionZ()+1.0f); float o = frand(0, 2*M_PI); - target->MovePositionToFirstCollision(pos, 20.0f, frand(0, 2*M_PI)); + target->MovePositionToFirstCollision(pos, 20.0f, o); pos.m_positionZ += frand(5.0f, 15.0f); } else diff --git a/src/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp b/src/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp index 8297d8716a..3bdfbfe350 100644 --- a/src/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp +++ b/src/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp @@ -86,9 +86,9 @@ enum SummonPhases static Position RoomPosition[] = { - {1293.0f, 610.0f, 199.3f}, - {1294.2f, 724.3f, 199.3f}, - {1295.2f, 667.1f, 189.7f}, + {1293.0f, 610.0f, 199.3f, 0.0f}, + {1294.2f, 724.3f, 199.3f, 0.0f}, + {1295.2f, 667.1f, 189.7f, 0.0f}, }; class boss_sjonnir : public CreatureScript diff --git a/src/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp b/src/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp index 12b7136e50..8a01e4493c 100644 --- a/src/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp +++ b/src/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp @@ -781,7 +781,7 @@ public: void SpellHitTarget(Unit* target, const SpellInfo* spellInfo) { - if (spellInfo->Id == SPELL_CHAIN_LIGHTNING || spellInfo->Id == RAID_MODE(61916, 63482)) // Lightning Whirl triggered + if (spellInfo->Id == SPELL_CHAIN_LIGHTNING || spellInfo->Id == uint32(RAID_MODE(61916, 63482))) // Lightning Whirl triggered _stunnedAchievement = false; } diff --git a/src/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp b/src/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp index 42333ac61e..40a1c246b8 100644 --- a/src/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp +++ b/src/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp @@ -232,7 +232,7 @@ public: void EnterCombat(Unit* pWho) { - if (summons.size() != RAID_MODE(8, 16)) + if (summons.size() != uint32(RAID_MODE(8, 16))) { EnterEvadeMode(); return; @@ -1289,7 +1289,7 @@ public: void HandleEffectPeriodic(AuraEffect const * aurEff) { - if (aurEff->GetTickNumber() == aurEff->GetTotalTicks()-1) + if (aurEff->GetTotalTicks() > 0 && aurEff->GetTickNumber() == uint32(aurEff->GetTotalTicks())-1) { Unit* target = GetTarget(); Unit* caster = GetCaster(); diff --git a/src/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp b/src/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp index fee82b6697..c402ea2bab 100644 --- a/src/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp +++ b/src/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp @@ -448,7 +448,7 @@ public: void HandleEffectPeriodic(AuraEffect const * aurEff) { - if (aurEff->GetTickNumber() == aurEff->GetTotalTicks()) + if (aurEff->GetTotalTicks() >= 0 && aurEff->GetTickNumber() == uint32(aurEff->GetTotalTicks())) if (Unit* c = GetCaster()) if (Creature* s = c->SummonCreature(NPC_SCORCHED_GROUND, c->GetPositionX()+20.0f*cos(c->GetOrientation()), c->GetPositionY()+20.0f*sin(c->GetOrientation()), 361.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN, 30000)) { diff --git a/src/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp b/src/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp index 6f643b1517..676fe1aa9c 100644 --- a/src/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp +++ b/src/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp @@ -297,7 +297,7 @@ enum Misc DATA_LOSE_YOUR_ILLUSION = 2, }; -const Position Middle = {2134.68f, -263.13f, 419.44f}; +const Position Middle = {2134.68f, -263.13f, 419.44f, M_PI*1.5f}; const uint32 RollTable[3] = { 32877, 32878, 32876 }; diff --git a/src/scripts/Northrend/Ulduar/Ulduar/boss_yoggsaron.cpp b/src/scripts/Northrend/Ulduar/Ulduar/boss_yoggsaron.cpp index f0bd15facb..23f8809b3d 100644 --- a/src/scripts/Northrend/Ulduar/Ulduar/boss_yoggsaron.cpp +++ b/src/scripts/Northrend/Ulduar/Ulduar/boss_yoggsaron.cpp @@ -295,7 +295,7 @@ enum Misc DATA_GET_SARA_PHASE = 3, }; -const Position Middle = {1980.28f, -25.5868f, 329.397f}; +const Position Middle = {1980.28f, -25.5868f, 329.397f, M_PI*1.5f}; class boss_yoggsaron_sara : public CreatureScript @@ -1098,7 +1098,7 @@ public: me->LowerPlayerDamageReq(me->GetMaxHealth()*0.7f); me->RemoveAura(SPELL_SHADOW_BARRIER); - + events.ScheduleEvent(EVENT_YS_LUNATIC_GAZE, 7000); events.ScheduleEvent(EVENT_YS_SHADOW_BEACON, 20000); events.ScheduleEvent(EVENT_YS_SUMMON_GUARDIAN, 0); diff --git a/src/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp b/src/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp index f02ff773ca..62e7327148 100644 --- a/src/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp +++ b/src/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp @@ -71,16 +71,16 @@ enum Events static Position TrashPosition[]= { - {441.236f, -512.000f, 104.930f}, - {478.436f, -494.475f, 104.730f} + {441.236f, -512.000f, 104.930f, 0.0f}, + {478.436f, -494.475f, 104.730f, 0.0f} }; static Position SkadiPosition[] = { - {338.679f, -507.254f, 124.122f}, - {338.679f, -513.254f, 124.122f}, - {490.096f, -510.86f, 123.368f}, - {490.76f, -517.389f, 123.368f} + {338.679f, -507.254f, 124.122f, 0.0f}, + {338.679f, -513.254f, 124.122f, 0.0f}, + {490.096f, -510.86f, 123.368f, 0.0f}, + {490.76f, -517.389f, 123.368f, 0.0f} }; #define EMOTE_IN_RANGE "Skadi the Ruthless is within range of the harpoon launchers" diff --git a/src/scripts/Northrend/zone_dalaran.cpp b/src/scripts/Northrend/zone_dalaran.cpp index f89c35de47..19cdcb5e8d 100644 --- a/src/scripts/Northrend/zone_dalaran.cpp +++ b/src/scripts/Northrend/zone_dalaran.cpp @@ -229,11 +229,10 @@ public: uint64 _aquanosGUID; uint8 _lCount; uint32 _lSource; - uint32 _resetTime; - + bool _canWash; }; - + bool OnGossipHello(Player* player, Creature* creature) { if (creature->IsQuestGiver()) @@ -251,7 +250,7 @@ public: player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID()); return true; } - + bool OnGossipSelect(Player* player, Creature* creature, uint32 /*sender*/, uint32 action) { switch (action) diff --git a/src/scripts/Northrend/zone_zuldrak.cpp b/src/scripts/Northrend/zone_zuldrak.cpp index ba80febde2..47b0f44edd 100644 --- a/src/scripts/Northrend/zone_zuldrak.cpp +++ b/src/scripts/Northrend/zone_zuldrak.cpp @@ -114,7 +114,7 @@ public: questList[playerGUID] = itemCode; // Decode Item Entry, Get Item Name, Generate Emotes - uint32 itemEntry = GetTaskItemEntry(itemCode); + //uint32 itemEntry = GetTaskItemEntry(itemCode); uint32 auraId = GetTaskAura(itemCode); const char* itemName = GetTaskItemName(itemCode); diff --git a/src/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp b/src/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp index 9475f1f6d6..78ba575811 100644 --- a/src/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp +++ b/src/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp @@ -194,7 +194,6 @@ class spell_ragin_flames_inferno : public SpellScriptLoader void HandlePeriodic(AuraEffect const* aurEff) { - int32 damage = aurEff->GetAmount(); GetUnitOwner()->CastCustomSpell(SPELL_INFERNO_DAMAGE, SPELLVALUE_BASE_POINT0, aurEff->GetAmount(), GetUnitOwner(), TRIGGERED_FULL_MASK); } diff --git a/src/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp b/src/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp index 68a1c75e2d..f34dc51b07 100644 --- a/src/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp +++ b/src/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp @@ -148,7 +148,7 @@ class instance_mechanar : public InstanceMapScript { for (uint8 i = 0; i < 3; ++i) { - Position pos = {135.0f + 2.5f*i, 36.76f, 24.88f}; + Position pos = {135.0f + 2.5f*i, 36.76f, 24.88f, M_PI*1.5f}; if (Creature* creature = instance->SummonCreature(i==1 ? NPC_SUNSEEKER_ASTROMAGE : NPC_BLOODWARDER_PHYSICIAN, pos)) DoSummonAction(creature, player); } diff --git a/src/scripts/Spells/spell_dk.cpp b/src/scripts/Spells/spell_dk.cpp index 7df04d3a18..56af220e42 100644 --- a/src/scripts/Spells/spell_dk.cpp +++ b/src/scripts/Spells/spell_dk.cpp @@ -260,7 +260,7 @@ class spell_dk_raise_ally_trigger : public SpellScriptLoader void HandleEffectRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/) { if (Unit* charm = GetUnitOwner()->GetCharm()) - if (charm->GetEntry() == GetSpellInfo()->Effects[EFFECT_0].MiscValue) + if (GetSpellInfo()->Effects[EFFECT_0].MiscValue >= 0 && charm->GetEntry() == uint32(GetSpellInfo()->Effects[EFFECT_0].MiscValue)) charm->ToCreature()->DespawnOrUnsummon(); } @@ -782,7 +782,7 @@ class spell_dk_dancing_rune_weapon : public SpellScriptLoader Unit* target = eventInfo.GetActionTarget(); Unit* dancingRuneWeapon = NULL; for (Unit::ControlSet::const_iterator itr = player->m_Controlled.begin(); itr != player->m_Controlled.end(); ++itr) - if ((*itr)->GetEntry() == GetSpellInfo()->Effects[EFFECT_0].MiscValue) + if (int32((*itr)->GetEntry()) == GetSpellInfo()->Effects[EFFECT_0].MiscValue) { dancingRuneWeapon = *itr; break; @@ -1569,7 +1569,6 @@ class spell_dk_death_grip : public SpellScriptLoader void HandleDummy(SpellEffIndex /*effIndex*/) { - int32 damage = GetEffectValue(); float casterZ = GetCaster()->GetPositionZ(); // for Ring of Valor WorldLocation gripPos = *GetExplTargetDest(); if (Unit* target = GetHitUnit()) diff --git a/src/scripts/Spells/spell_item.cpp b/src/scripts/Spells/spell_item.cpp index 289d3fe5cb..2748f170a7 100644 --- a/src/scripts/Spells/spell_item.cpp +++ b/src/scripts/Spells/spell_item.cpp @@ -1255,7 +1255,7 @@ class spell_item_summon_or_dismiss : public SpellScriptLoader { for (Unit::ControlSet::iterator itr = GetCaster()->m_Controlled.begin(); itr != GetCaster()->m_Controlled.end(); ++itr) { - if ((*itr)->GetEntry() == GetSpellInfo()->Effects[effIndex].MiscValue) + if (GetSpellInfo()->Effects[effIndex].MiscValue >= 0 && (*itr)->GetEntry() == uint32(GetSpellInfo()->Effects[effIndex].MiscValue)) { (*itr)->ToTempSummon()->UnSummon(); PreventHitDefaultEffect(effIndex); |