mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-15 04:32:35 -04:00
Core/SmartAI:
- Fixed some issues with SMART_ACTION_SET_FLY (#1073) - Fixed allowing 0 as input for SMART_EVENT_ACCEPTED_QUEST and SMART_EVENT_REWARD_QUEST (#2680) - Some cleanup
This commit is contained in:
@@ -1782,7 +1782,12 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
}
|
||||
case SMART_ACTION_JUMP_TO_POS:
|
||||
{
|
||||
if (!me)
|
||||
return;
|
||||
|
||||
me->GetMotionMaster()->Clear();
|
||||
me->GetMotionMaster()->MoveJump(e.target.x, e.target.y, e.target.z, (float)e.action.jump.speedxy, (float)e.action.jump.speedz);
|
||||
// TODO: Resume path when reached jump location
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_SEND_GOSSIP_MENU:
|
||||
@@ -1795,7 +1800,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
return;
|
||||
|
||||
for (ObjectList::const_iterator itr = targets->begin(); itr != targets->end(); ++itr)
|
||||
if(Player* player = (*itr)->ToPlayer())
|
||||
if (Player* player = (*itr)->ToPlayer())
|
||||
{
|
||||
if (e.action.sendGossipMenu.gossipMenuId)
|
||||
player->PrepareGossipMenu(GetBaseObject(), e.action.sendGossipMenu.gossipMenuId, true);
|
||||
|
||||
Reference in New Issue
Block a user