mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 09:44:45 +01:00
DB/NPC: Spawn npc 25589 and fix some issues in its core script.
Closes #784.
This commit is contained in:
6
sql/updates/world/2011_09_11_08_world_creature.sql
Normal file
6
sql/updates/world/2011_09_11_08_world_creature.sql
Normal file
@@ -0,0 +1,6 @@
|
||||
DELETE FROM `creature` WHERE `id`=25589;
|
||||
INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`currentwaypoint`,`curhealth`,`curmana`,`MovementType`) VALUES
|
||||
(2017,25589,571,1,1,0,0,4464.63,5378.07,-15.2737,6.05299,600,0,0,1,0,0);
|
||||
DELETE FROM `creature_template_addon` WHERE `entry`=25589;
|
||||
INSERT INTO `creature_template_addon` (`entry`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES
|
||||
(25589,0,1,1,0, ''); -- sitting
|
||||
@@ -1899,13 +1899,13 @@ public:
|
||||
|
||||
enum Bonker_Togglevolt_Entries
|
||||
{
|
||||
NPC_BONKER_TOGGLEVOLT =25589,
|
||||
QUEST_GET_ME_OUTA_HERE =11673
|
||||
NPC_BONKER_TOGGLEVOLT = 25589,
|
||||
QUEST_GET_ME_OUTA_HERE = 11673
|
||||
};
|
||||
enum Script_Texts_Bonker_Togglevolt
|
||||
{
|
||||
SAY_bonker_1 =-1700002,
|
||||
SAY_bonker_2 =-1700003
|
||||
SAY_bonker_1 = -1700002,
|
||||
SAY_bonker_2 = -1700003
|
||||
};
|
||||
|
||||
class npc_bonker_togglevolt : public CreatureScript
|
||||
@@ -1917,15 +1917,7 @@ public:
|
||||
{
|
||||
if (quest->GetQuestId() == QUEST_GET_ME_OUTA_HERE)
|
||||
{
|
||||
switch (player->GetTeam())
|
||||
{
|
||||
case ALLIANCE:
|
||||
creature->setFaction(FACTION_ESCORTEE_A);
|
||||
break;
|
||||
case HORDE:
|
||||
creature->setFaction(FACTION_ESCORTEE_H);
|
||||
break;
|
||||
}
|
||||
creature->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
DoScriptText(SAY_bonker_2, creature, player);
|
||||
CAST_AI(npc_escortAI, (creature->AI()))->Start(true, true, player->GetGUID());
|
||||
}
|
||||
@@ -1939,8 +1931,8 @@ public:
|
||||
|
||||
void Reset()
|
||||
{
|
||||
Bonker_agro=0;
|
||||
SetDespawnAtFar(false);
|
||||
Bonker_agro=0;
|
||||
SetDespawnAtFar(false);
|
||||
}
|
||||
|
||||
void JustDied(Unit* /*killer*/)
|
||||
@@ -1972,10 +1964,10 @@ public:
|
||||
|
||||
switch(i)
|
||||
{
|
||||
case 29:
|
||||
if (player)
|
||||
player->GroupEventHappens(QUEST_GET_ME_OUTA_HERE, me);
|
||||
break;
|
||||
case 29:
|
||||
if (player)
|
||||
player->GroupEventHappens(QUEST_GET_ME_OUTA_HERE, me);
|
||||
break;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user