mirror of
https://github.com/mod-playerbots/mod-playerbots.git
synced 2026-01-15 09:50:27 +00:00
Fix: prevent MoveSplineInitArgs::Validate velocity asserts (velocity > 0.01f) for bots, pets, and charmed units (#1534)
* MoveSplineInitArgs::Validate: expression 'velocity > 0.01f' failed for GUID Full * Update BotMovementUtils.h
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
#include "RaidNaxxStrategy.h"
|
||||
#include "ScriptedCreature.h"
|
||||
#include "SharedDefines.h"
|
||||
#include "BotMovementUtils.h"
|
||||
|
||||
bool GrobbulusGoBehindAction::Execute(Event event)
|
||||
{
|
||||
@@ -258,11 +259,26 @@ bool RazuviousUseObedienceCrystalAction::Execute(Event event)
|
||||
return false;
|
||||
}
|
||||
if (charm->GetMotionMaster()->GetMotionSlotType(MOTION_SLOT_ACTIVE) == NULL_MOTION_TYPE)
|
||||
{
|
||||
/*{
|
||||
charm->GetMotionMaster()->Clear();
|
||||
charm->GetMotionMaster()->MoveChase(target);
|
||||
charm->GetAI()->AttackStart(target);
|
||||
}*/
|
||||
// [Fix: MoveSplineInitArgs::Validate: expression 'velocity > 0.01f' failed for GUID Full:]
|
||||
{
|
||||
if (CanStartMoveSpline(charm))
|
||||
{
|
||||
charm->GetMotionMaster()->Clear();
|
||||
charm->GetMotionMaster()->MoveChase(target);
|
||||
}
|
||||
else
|
||||
{
|
||||
charm->StopMoving();
|
||||
}
|
||||
|
||||
charm->GetAI()->AttackStart(target);
|
||||
}
|
||||
// End Fix
|
||||
Aura* forceObedience = botAI->GetAura("force obedience", charm);
|
||||
uint32 duration_time;
|
||||
if (!forceObedience)
|
||||
|
||||
Reference in New Issue
Block a user