Scripts/Misc: Use new movement flag setting methods in scripts
This commit is contained in:
1 parent
d9df460694
commit
b6aadc6698
18 files changed
+34
-44
No files matched your search
@@ -724,27 +724,18 @@ uint64 SmartAI::GetGUID(int32 /*id*/) const
|
||||
|
||||
void SmartAI::SetRun(bool run)
|
||||
{
|
||||
if (run)
|
||||
me->SetWalk(false);
|
||||
else
|
||||
me->SetWalk(true);
|
||||
|
||||
me->SetWalk(!run);
|
||||
mRun = run;
|
||||
}
|
||||
|
||||
void SmartAI::SetFly(bool fly)
|
||||
{
|
||||
me->SetDisableGravity(fly);
|
||||
me->SendMovementFlagUpdate();
|
||||
}
|
||||
|
||||
void SmartAI::SetSwim(bool swim)
|
||||
{
|
||||
if (swim)
|
||||
me->AddUnitMovementFlag(MOVEMENTFLAG_SWIMMING);
|
||||
else
|
||||
me->RemoveUnitMovementFlag(MOVEMENTFLAG_SWIMMING);
|
||||
me->SendMovementFlagUpdate();
|
||||
me->SetSwim(swim);
|
||||
}
|
||||
|
||||
void SmartAI::sGossipHello(Player* player)
|
||||
|
||||
Reference in new issue
Block a user