mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
Merge pull request #15191 from Rushor/action
Core/SAI: Add SMART_ACTION_RISE_UP for Z Axis
This commit is contained in:
@@ -1164,6 +1164,14 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
me->GetMotionMaster()->MovePoint(SMART_RANDOM_POINT, x, y, z);
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_RISE_UP:
|
||||
{
|
||||
if (!me)
|
||||
break;
|
||||
|
||||
me->GetMotionMaster()->MovePoint(SMART_RANDOM_POINT, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ() + (float)e.action.moveRandom.distance);
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_SET_VISIBILITY:
|
||||
{
|
||||
if (me)
|
||||
|
||||
@@ -1235,6 +1235,7 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e)
|
||||
case SMART_ACTION_ADD_GO_FLAG:
|
||||
case SMART_ACTION_REMOVE_GO_FLAG:
|
||||
case SMART_ACTION_SUMMON_CREATURE_GROUP:
|
||||
case SMART_ACTION_RISE_UP:
|
||||
break;
|
||||
default:
|
||||
TC_LOG_ERROR("sql.sql", "SmartAIMgr: Not handled action_type(%u), event_type(%u), Entry " SI64FMTD " SourceType %u Event %u, skipped.", e.GetActionType(), e.GetEventType(), e.entryOrGuid, e.GetScriptType(), e.event_id);
|
||||
|
||||
@@ -540,8 +540,9 @@ enum SMART_ACTION
|
||||
SMART_ACTION_GAME_EVENT_STOP = 111, // GameEventId
|
||||
SMART_ACTION_GAME_EVENT_START = 112, // GameEventId
|
||||
SMART_ACTION_START_CLOSEST_WAYPOINT = 113, // wp1, wp2, wp3, wp4, wp5, wp6, wp7
|
||||
SMART_ACTION_RISE_UP = 114, // distance
|
||||
|
||||
SMART_ACTION_END = 114
|
||||
SMART_ACTION_END = 115
|
||||
};
|
||||
|
||||
struct SmartAction
|
||||
|
||||
Reference in New Issue
Block a user