fix(DB/Scripts): CoS Stephanie Sindree and citizen now talk (#24045)
Co-authored-by: blinkysc <blinkysc@users.noreply.github.com> Co-authored-by: sudlud <sudlud@users.noreply.github.com>
This commit is contained in:
@@ -0,0 +1,12 @@
|
|||||||
|
-- Add creature_text for Stephanie Sindree (31019)
|
||||||
|
DELETE FROM `creature_text` WHERE `CreatureID` = 31019;
|
||||||
|
INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES
|
||||||
|
(31019, 0, 0, 'It wasn''t my food!', 12, 0, 100, 6, 0, 0, 31838, 0, 'Stephanie Sindree - Stephanie Crowd'),
|
||||||
|
(31019, 1, 0, 'Please, it''s not my fault! If... if I give you a refund, maybe you can speak to a healer? I don''t know what you expect me to do!', 12, 0, 100, 20, 0, 0, 31840, 0, 'Stephanie Sindree - Stephanie Crowd');
|
||||||
|
|
||||||
|
-- Add creature_text for Agitated Stratholme Citizen (31126) - Stephanie Crowd
|
||||||
|
DELETE FROM `creature_text` WHERE `CreatureID` = 31126 AND `GroupID` IN (4, 5, 6);
|
||||||
|
INSERT INTO `creature_text` (`CreatureID`, `GroupID`, `ID`, `Text`, `Type`, `Language`, `Probability`, `Emote`, `Duration`, `Sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES
|
||||||
|
(31126, 4, 0, 'My wife and children are sick in bed because of the poison you sold me!', 12, 0, 100, 5, 0, 0, 31837, 0, 'Agitated Stratholme Citizen - Stephanie Crowd'),
|
||||||
|
(31126, 5, 0, 'Don''t try to weasel out of this!', 12, 0, 100, 25, 0, 0, 31839, 0, 'Agitated Stratholme Citizen - Stephanie Crowd'),
|
||||||
|
(31126, 6, 0, 'That... no, keep your filthy money! It won''t help my family!', 12, 0, 100, 5, 0, 0, 31842, 0, 'Agitated Stratholme Citizen - Stephanie Crowd');
|
||||||
+57
@@ -176,6 +176,14 @@ enum Misc
|
|||||||
|
|
||||||
POINT_CHRONOS = 1,
|
POINT_CHRONOS = 1,
|
||||||
|
|
||||||
|
// Stephanie Sindree crowd
|
||||||
|
NPC_STEPHANIE_SINDREE = 31019,
|
||||||
|
SAY_STEPHANIE_CROWD_1 = 4,
|
||||||
|
SAY_STEPHANIE_CROWD_2 = 5,
|
||||||
|
SAY_STEPHANIE_CROWD_3 = 6,
|
||||||
|
SAY_STEPHANIE_RESPONSE_1 = 0,
|
||||||
|
SAY_STEPHANIE_RESPONSE_2 = 1,
|
||||||
|
|
||||||
// Brandon Eiredeck crowd
|
// Brandon Eiredeck crowd
|
||||||
NPC_BRANDON_EIREDECK = 31023,
|
NPC_BRANDON_EIREDECK = 31023,
|
||||||
SAY_BRANDON_CROWD_AMBIENT = 3,
|
SAY_BRANDON_CROWD_AMBIENT = 3,
|
||||||
@@ -1526,6 +1534,10 @@ public:
|
|||||||
if (!pInstance || pInstance->GetData(DATA_ARTHAS_EVENT) < COS_PROGRESS_FINISHED_CITY_INTRO)
|
if (!pInstance || pInstance->GetData(DATA_ARTHAS_EVENT) < COS_PROGRESS_FINISHED_CITY_INTRO)
|
||||||
allowTimer++;
|
allowTimer++;
|
||||||
|
|
||||||
|
isStephanieCrowd = me->GetEntry() == NPC_CITY_MAN3 && me->GetDistance(2149.56f, 1339.46f, 132.531f) < 10.0f;
|
||||||
|
stephanieDialogueTimer = isStephanieCrowd ? urand(5000, 15000) : 0;
|
||||||
|
stephanieDialoguePhase = 0;
|
||||||
|
|
||||||
isBrandonCrowd = me->GetDistance(2267.86f, 1144.93f, 138.403f) < 10.0f;
|
isBrandonCrowd = me->GetDistance(2267.86f, 1144.93f, 138.403f) < 10.0f;
|
||||||
ambientTalkTimer = isBrandonCrowd ? urand(5000, 15000) : 0;
|
ambientTalkTimer = isBrandonCrowd ? urand(5000, 15000) : 0;
|
||||||
}
|
}
|
||||||
@@ -1534,6 +1546,9 @@ public:
|
|||||||
uint32 changeTimer;
|
uint32 changeTimer;
|
||||||
InstanceScript* pInstance;
|
InstanceScript* pInstance;
|
||||||
uint32 allowTimer;
|
uint32 allowTimer;
|
||||||
|
bool isStephanieCrowd;
|
||||||
|
uint32 stephanieDialogueTimer;
|
||||||
|
uint8 stephanieDialoguePhase;
|
||||||
bool isBrandonCrowd;
|
bool isBrandonCrowd;
|
||||||
uint32 ambientTalkTimer;
|
uint32 ambientTalkTimer;
|
||||||
|
|
||||||
@@ -1596,6 +1611,48 @@ public:
|
|||||||
{
|
{
|
||||||
ScriptedAI::UpdateAI(diff);
|
ScriptedAI::UpdateAI(diff);
|
||||||
|
|
||||||
|
if (isStephanieCrowd && stephanieDialogueTimer)
|
||||||
|
{
|
||||||
|
if (stephanieDialogueTimer <= diff)
|
||||||
|
{
|
||||||
|
Creature* stephanie = me->FindNearestCreature(NPC_STEPHANIE_SINDREE, 10.0f);
|
||||||
|
switch (stephanieDialoguePhase)
|
||||||
|
{
|
||||||
|
case 0:
|
||||||
|
Talk(SAY_STEPHANIE_CROWD_1);
|
||||||
|
stephanieDialogueTimer = 5000;
|
||||||
|
stephanieDialoguePhase = 1;
|
||||||
|
break;
|
||||||
|
case 1:
|
||||||
|
if (stephanie)
|
||||||
|
stephanie->AI()->Talk(SAY_STEPHANIE_RESPONSE_1);
|
||||||
|
stephanieDialogueTimer = 5000;
|
||||||
|
stephanieDialoguePhase = 2;
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
|
Talk(SAY_STEPHANIE_CROWD_2);
|
||||||
|
stephanieDialogueTimer = 5000;
|
||||||
|
stephanieDialoguePhase = 3;
|
||||||
|
break;
|
||||||
|
case 3:
|
||||||
|
if (stephanie)
|
||||||
|
stephanie->AI()->Talk(SAY_STEPHANIE_RESPONSE_2);
|
||||||
|
stephanieDialogueTimer = 8000;
|
||||||
|
stephanieDialoguePhase = 4;
|
||||||
|
break;
|
||||||
|
case 4:
|
||||||
|
Talk(SAY_STEPHANIE_CROWD_3);
|
||||||
|
stephanieDialogueTimer = urand(45000, 60000);
|
||||||
|
stephanieDialoguePhase = 0;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
stephanieDialogueTimer -= diff;
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (isBrandonCrowd && ambientTalkTimer)
|
if (isBrandonCrowd && ambientTalkTimer)
|
||||||
{
|
{
|
||||||
if (ambientTalkTimer <= diff)
|
if (ambientTalkTimer <= diff)
|
||||||
|
|||||||
Reference in New Issue
Block a user