Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Core/Scripts: Meathook and Salramm should patrol once they spawn. #942

Closed
wants to merge 7 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Core/Scripts: Meathook and Salramm should patrol once they spawn.
  • Loading branch information
FALL1N1 committed Jun 24, 2018
commit 516025d689384933411bf019629f1983b2d5493f
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,25 @@ class boss_meathook : public CreatureScript
return new boss_meathookAI (creature);
}

struct boss_meathookAI : public ScriptedAI
struct boss_meathookAI : public npc_escortAI
{
boss_meathookAI(Creature* c) : ScriptedAI(c)
boss_meathookAI(Creature* c) : npc_escortAI(c)
{
Talk(SAY_SPAWN);

AddWaypoint(1, 2349.07f, 1181.84f, 130.416f, 0);
AddWaypoint(2, 2240.9f, 1173.33f, 137.171f, 0);
AddWaypoint(3, 2171.15f, 1251.85f, 135.168f, 0);
AddWaypoint(4, 2180.95f, 1329.96f, 129.991f, 0);
AddWaypoint(5, 2219.12f, 1331.17f, 128.11f, 0);
AddWaypoint(6, 2139.14f, 1351.94f, 132.072f, 0);
AddWaypoint(7, 2186.49f, 1335.78f, 130.049f, 0);
AddWaypoint(8, 2170.9f, 1255.13f, 134.816f, 0);
AddWaypoint(9, 2245.52f, 1169.46f, 137.59f, 0);
AddWaypoint(10, 2325.94f, 1176.1f, 132.979f, 0);
AddWaypoint(11, 2351.52f, 1197.95f, 130.444f, 0);

Start(true, false, 0, NULL, false, true);
}

EventMap events;
Expand All @@ -71,7 +85,9 @@ class boss_meathook : public CreatureScript
Talk(SAY_SLAY);
}

Copy link
Contributor

@PkllonG PkllonG Jun 28, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+void WaypointReached(uint32 waypointId) { }

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix build

void UpdateAI(uint32 diff)
void WaypointReached(uint32 Point) { /* do something? idk.. */ }

void UpdateEscortAI(uint32 diff)
{
if (!UpdateVictim())
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,28 @@ class boss_salramm : public CreatureScript

CreatureAI* GetAI(Creature* creature) const
{
return new boss_salrammAI (creature);
return new boss_salrammAI(creature);
}

struct boss_salrammAI : public ScriptedAI
struct boss_salrammAI : public npc_escortAI
{
boss_salrammAI(Creature* c) : ScriptedAI(c), summons(me)
boss_salrammAI(Creature* c) : npc_escortAI(c), summons(me)
{
Talk(SAY_SPAWN);

AddWaypoint(1, 2349.07f, 1181.84f, 130.416f, 0);
AddWaypoint(2, 2240.9f, 1173.33f, 137.171f, 0);
AddWaypoint(3, 2171.15f, 1251.85f, 135.168f, 0);
AddWaypoint(4, 2180.95f, 1329.96f, 129.991f, 0);
AddWaypoint(5, 2219.12f, 1331.17f, 128.11f, 0);
AddWaypoint(6, 2139.14f, 1351.94f, 132.072f, 0);
AddWaypoint(7, 2186.49f, 1335.78f, 130.049f, 0);
AddWaypoint(8, 2170.9f, 1255.13f, 134.816f, 0);
AddWaypoint(9, 2245.52f, 1169.46f, 137.59f, 0);
AddWaypoint(10, 2325.94f, 1176.1f, 132.979f, 0);
AddWaypoint(11, 2351.52f, 1197.95f, 130.444f, 0);

Start(true, false, 0, NULL, false, true);
}

EventMap events;
Expand Down Expand Up @@ -103,7 +117,9 @@ class boss_salramm : public CreatureScript
}
}

Copy link
Contributor

@PkllonG PkllonG Jun 28, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+void WaypointReached(uint32 waypointId) { }

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix build

void UpdateAI(uint32 diff)
void WaypointReached(uint32 Point) { /* do something? idk.. */ }

void UpdateEscortAI(uint32 diff)
{
if (!UpdateVictim())
return;
Expand Down