mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-19 00:48:56 +01:00
DB/Conditions: quests Southern Sabotage and Toppling the Towers are only available if the respective faction is defending Wintergrasp.
Also codestyle stealthfix.
This commit is contained in:
7
sql/updates/world/3.3.5/2016_10_04_02_world.sql
Normal file
7
sql/updates/world/3.3.5/2016_10_04_02_world.sql
Normal file
@@ -0,0 +1,7 @@
|
||||
--
|
||||
DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN (19, 20) AND `SourceEntry` IN (13538, 13539);
|
||||
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
|
||||
(19, 0, 13538, 0, 0, 48, 0, 0, 0, 0, 1, 0, 0, "", "Alliance quest 'Southern Sabotage' is available if Wintergrasp is held by Alliance"),
|
||||
(20, 0, 13538, 0, 0, 48, 0, 0, 0, 0, 1, 0, 0, "", "Quest mark for Alliance quest 'Southern Sabotage' is available if Wintergrasp is held by Alliance"),
|
||||
(19, 0, 13539, 0, 0, 48, 0, 0, 0, 0, 0, 0, 0, "", "Horde quest 'Toppling the Towers' is available if Wintergrasp is held by Horde"),
|
||||
(20, 0, 13539, 0, 0, 48, 0, 0, 0, 0, 0, 0, 0, "", "Quest mark for Horde quest 'Toppling the Towers' is available if Wintergrasp is held by Horde");
|
||||
@@ -504,7 +504,7 @@ bool Condition::Meets(ConditionSourceInfo& sourceInfo) const
|
||||
case CONDITION_WINTERGRASP_HORDE:
|
||||
{
|
||||
condMeets = false;
|
||||
if (object->ToPlayer())
|
||||
if (object->GetTypeId() == TYPEID_PLAYER)
|
||||
if (Battlefield* wintergrasp = sBattlefieldMgr->GetBattlefieldByBattleId(BATTLEFIELD_BATTLEID_WG))
|
||||
if (wintergrasp->IsEnabled())
|
||||
if (wintergrasp->GetDefenderTeam() == TEAM_HORDE)
|
||||
|
||||
Reference in New Issue
Block a user