typo exiles reach fix
This commit is contained in:
@@ -29,37 +29,9 @@ class exiles_reach_north_sea_playerscript : public PlayerScript
|
|||||||
public:
|
public:
|
||||||
exiles_reach_north_sea_playerscript() : PlayerScript("exiles_reach_north_sea_playerscript") {}
|
exiles_reach_north_sea_playerscript() : PlayerScript("exiles_reach_north_sea_playerscript") {}
|
||||||
|
|
||||||
void GiveExileShipIntroQuest(Player* player)
|
|
||||||
{
|
|
||||||
uint32 const questId = player->IsInHorde() ? QUEST_H_WARMING_UP : QUEST_WARMING_UP;
|
|
||||||
if (player->GetQuestStatus(questId) != QUEST_STATUS_NONE)
|
|
||||||
return;
|
|
||||||
|
|
||||||
uint32 const laterQuests[] =
|
|
||||||
{
|
|
||||||
player->IsInHorde() ? QUEST_H_STAND_YOUR_GROUND : QUEST_STAND_YOUR_GROUND,
|
|
||||||
player->IsInHorde() ? QUEST_H_BRACE_FOR_IMPACT : QUEST_BRACE_FOR_IMPACT,
|
|
||||||
player->IsInHorde() ? QUEST_H_MURLOC_MANIA : QUEST_MURLOC_MANIA,
|
|
||||||
player->IsInHorde() ? QUEST_H_AN_END_TO_BEGINNINGS : QUEST_AN_END_TO_BEGINNINGS,
|
|
||||||
};
|
|
||||||
|
|
||||||
for (uint32 laterQuestId : laterQuests)
|
|
||||||
if (player->GetQuestStatus(laterQuestId) != QUEST_STATUS_NONE)
|
|
||||||
return;
|
|
||||||
|
|
||||||
Quest const* quest = sObjectMgr->GetQuestTemplate(questId);
|
|
||||||
if (!quest || !player->CanTakeQuest(quest, false) || !player->CanAddQuest(quest, false))
|
|
||||||
return;
|
|
||||||
|
|
||||||
player->AddQuestAndCheckCompletion(quest, nullptr);
|
|
||||||
}
|
|
||||||
|
|
||||||
void CheckExilesReachPhaseShift(Player* player)
|
void CheckExilesReachPhaseShift(Player* player)
|
||||||
{
|
{
|
||||||
// A new character has no quest yet. Hand out Warming Up before the phase
|
|
||||||
// update so the ship quest giver and the combat dummy stay visible.
|
|
||||||
GiveExileShipIntroQuest(player);
|
|
||||||
|
|
||||||
if (player->GetMapId() == MAP_EXILES_REACH)
|
if (player->GetMapId() == MAP_EXILES_REACH)
|
||||||
{
|
{
|
||||||
switch (player->GetAreaId())
|
switch (player->GetAreaId())
|
||||||
@@ -72,8 +44,8 @@ public:
|
|||||||
WowCommunity::PhaseShift(player, { PHASE_GENERAL_SHIP }, true);
|
WowCommunity::PhaseShift(player, { PHASE_GENERAL_SHIP }, true);
|
||||||
if (player->IsInHorde())
|
if (player->IsInHorde())
|
||||||
{
|
{
|
||||||
// PhaseShift no longer removes phases. Drop the Alliance ship
|
// A Horde character must not keep Jaina's crew. These phases are
|
||||||
// phases here so a Horde character does not keep Jaina's crew.
|
// only added for Alliance, so dropping them here is safe.
|
||||||
uint32 const allianceShipPhases[] =
|
uint32 const allianceShipPhases[] =
|
||||||
{
|
{
|
||||||
PHASE_ALLIANCE_SHIP_COLE,
|
PHASE_ALLIANCE_SHIP_COLE,
|
||||||
@@ -89,8 +61,8 @@ public:
|
|||||||
if (player->GetPhaseShift().HasPhase(phaseId))
|
if (player->GetPhaseShift().HasPhase(phaseId))
|
||||||
PhasingHandler::RemovePhase(player, phaseId, true);
|
PhasingHandler::RemovePhase(player, phaseId, true);
|
||||||
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_15514 }, !QuestRewarded(player, QUEST_H_WARMING_UP));
|
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_15514 }, !QuestRewarded(player, QUEST_H_WARMING_UP));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_THROG }, !QuestAccepted(player, QUEST_H_STAND_YOUR_GROUND) && !QuestCompleted(player, QUEST_H_BRACE_FOR_IMPACT));
|
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_THROG }, !QuestAccepted(player, QUEST_H_STAND_YOUR_GROUND) && !QuestCompletedOrRewarded(player, QUEST_H_BRACE_FOR_IMPACT));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_15287 }, QuestRewarded(player, QUEST_H_WARMING_UP) && !QuestCompleted(player, QUEST_H_BRACE_FOR_IMPACT));
|
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_15287 }, QuestRewarded(player, QUEST_H_WARMING_UP) && !QuestCompletedOrRewarded(player, QUEST_H_BRACE_FOR_IMPACT));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_15516 }, QuestAcceptedOrCompleted(player, QUEST_H_BRACE_FOR_IMPACT));
|
WowCommunity::PhaseShift(player, { PHASE_HORDE_SHIP_15516 }, QuestAcceptedOrCompleted(player, QUEST_H_BRACE_FOR_IMPACT));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -100,11 +72,11 @@ public:
|
|||||||
WowCommunity::PhaseShift(player, { PHASE_GENERAL_SHIP }, true);
|
WowCommunity::PhaseShift(player, { PHASE_GENERAL_SHIP }, true);
|
||||||
if (player->IsInAlliance())
|
if (player->IsInAlliance())
|
||||||
{
|
{
|
||||||
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_COLE }, !QuestAccepted(player, QUEST_STAND_YOUR_GROUND) && !QuestCompleted(player, QUEST_BRACE_FOR_IMPACT));
|
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_COLE }, !QuestAccepted(player, QUEST_STAND_YOUR_GROUND) && !QuestCompletedOrRewarded(player, QUEST_BRACE_FOR_IMPACT));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_13619 }, QuestRewarded(player, QUEST_WARMING_UP) && !QuestAccepted(player, QUEST_STAND_YOUR_GROUND));
|
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_13619 }, QuestRewarded(player, QUEST_WARMING_UP) && player->GetQuestStatus(QUEST_STAND_YOUR_GROUND) == QUEST_STATUS_NONE && !QuestCompletedOrRewarded(player, QUEST_BRACE_FOR_IMPACT));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_14350 }, QuestRewarded(player, QUEST_WARMING_UP) && !QuestCompleted(player, QUEST_BRACE_FOR_IMPACT));
|
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_14350 }, QuestRewarded(player, QUEST_WARMING_UP) && !QuestCompletedOrRewarded(player, QUEST_BRACE_FOR_IMPACT));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_GARRICK_1 }, !QuestRewarded(player, QUEST_WARMING_UP));
|
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_GARRICK_1 }, !QuestRewarded(player, QUEST_WARMING_UP));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_CREW_OUTSIDE }, !QuestCompleted(player, QUEST_BRACE_FOR_IMPACT));
|
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_CREW_OUTSIDE }, !QuestCompletedOrRewarded(player, QUEST_BRACE_FOR_IMPACT));
|
||||||
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_GARRICK_2, PHASE_ALLIANCE_SHIP_CREW_INSIDE }, QuestCompleted(player, QUEST_BRACE_FOR_IMPACT));
|
WowCommunity::PhaseShift(player, { PHASE_ALLIANCE_SHIP_GARRICK_2, PHASE_ALLIANCE_SHIP_CREW_INSIDE }, QuestCompleted(player, QUEST_BRACE_FOR_IMPACT));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user