Core/SmartAI: Fixed SMART_ACTION_SET_RANGED_MOVEMENT parameters

This commit is contained in:
Shauren
2012-06-23 12:15:52 +02:00
parent 29bfb9854c
commit ea9339b171
2 changed files with 11 additions and 8 deletions
@@ -1543,8 +1543,8 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
if (!IsSmart())
break;
float attackDistance = (float)e.action.setRangedMovement.distance;
float attackAngle = e.action.setRangedMovement.angle / 180.0f * M_PI;
float attackDistance = float(e.action.setRangedMovement.distance);
float attackAngle = float(e.action.setRangedMovement.angle) / 180.0f * M_PI;
ObjectList* targets = GetTargets(e, unit);
if (targets)
@@ -356,11 +356,11 @@ struct SmartEvent
uint32 eventId;
} eventInform;
struct
struct
{
uint32 eventId;
} doAction;
struct
{
uint32 param1;
@@ -857,9 +857,9 @@ struct SmartAction
struct
{
bool withDelayed;
uint32 withDelayed;
uint32 spell_id;
bool withInstant;
uint32 withInstant;
} interruptSpellCasting;
struct
@@ -906,10 +906,13 @@ struct SmartAction
struct
{
float distance;
float angle;
uint32 distance;
uint32 angle;
} setRangedMovement;
//! Note for any new future actions
//! All parameters must have type uint32
struct
{
uint32 param1;