master 分支适用,根据版本不同可能会略有差别,详细解释参见源码 SmartScriptMgr.h
name | Value | param1 | param2 | param3 | param4 | param5 | ParamString | comments |
SMART_EVENT_UPDATE_IC | 0 | InitialMin | InitialMax | RepeatMin | RepeatMax | 战斗中触发 | ||
SMART_EVENT_UPDATE_OOC | 1 | InitialMin | InitialMax | RepeatMin | RepeatMax | 非战斗状态下触发 | ||
SMART_EVENT_HEALTH_PCT | 2 | HPMin% | HPMax% | RepeatMin | RepeatMax | 生命值百分比触发 | ||
SMART_EVENT_MANA_PCT | 3 | ManaMin% | ManaMax% | RepeatMin | RepeatMax | 魔法值百分比触发 | ||
SMART_EVENT_AGGRO | 4 | 获得仇恨后触发 | ||||||
SMART_EVENT_KILL | 5 | CooldownMin | CooldownMax | Player only? (0/1) | creature_template.entry (If Param3 is 0) | 杀死玩家或其他生物后触发 | ||
SMART_EVENT_DEATH | 6 | 死亡后触发 | ||||||
SMART_EVENT_EVADE | 7 | 脱离战斗后触发 | ||||||
SMART_EVENT_SPELLHIT | 8 | SpellID | School | CooldownMin | CooldownMax | 被特定技能击中后触发,School参数如下 (0:普通 1:神圣 2:火焰 3:自然 4:冰霜 5:暗影 6:秘法) | ||
SMART_EVENT_RANGE | 9 | MinDist | MaxDist | RepeatMin | RepeatMax | 与玩家相隔特定距离后触发 | ||
SMART_EVENT_OOC_LOS | 10 | HostilityMode: 1: NotHostile 2: Any | MaxRange | CooldownMin | CooldownMax | Player Only? (0/1) | 非战斗状态下与玩家相隔特定距离后触发 | |
SMART_EVENT_RESPAWN | 11 | type 0: None 1: Map 2: Area | MapId | ZoneId | 当刷新、重新刷新、被召唤时触发 | |||
SMART_EVENT_TARGET_HEALTH_PCT | 12 | HPMin% | HPMax% | RepeatMin | RepeatMax | 对象当前目标生命值百分比后触发 UNUSED, DO NOT REUSE | ||
SMART_EVENT_VICTIM_CASTING | 13 | RepeatMin | RepeatMax | SpellID (0: any) | 当前目标施放特定法术后触发 | |||
SMART_EVENT_FRIENDLY_HEALTH | 14 | HPDeficit | Radius | RepeatMin | RepeatMax | 范围内友方生命值亏损后触发 UNUSED, DO NOT REUSE | ||
SMART_EVENT_FRIENDLY_IS_CC | 15 | Radius | RepeatMin | RepeatMax | 范围内友方被控制后触发 | |||
SMART_EVENT_FRIENDLY_MISSING_BUFF | 16 | SpellID | Radius | RepeatMin | RepeatMax | 范围内友方失去指定buff法术后触发 | ||
SMART_EVENT_SUMMONED_UNIT | 17 | creature_template.entry (0 any) | CooldownMin | CooldownMax | 召唤出特定对象后触发 | |||
SMART_EVENT_TARGET_MANA_PCT | 18 | ManaMin% | ManaMax% | RepeatMin | RepeatMax | 对象当前目标魔法值百分比时触发 UNUSED, DO NOT REUSE | ||
SMART_EVENT_ACCEPTED_QUEST | 19 | QuestID (0: any) | RepeatMin | RepeatMax | 接到任务后触发 | |||
SMART_EVENT_REWARD_QUEST | 20 | QuestID (0: any) | RepeatMin | RepeatMax | 获得任务奖励后触发 | |||
SMART_EVENT_REACHED_HOME | 21 | (传送)回家后触发 | ||||||
SMART_EVENT_RECEIVE_EMOTE | 22 | EmoteID | CooldownMin | CooldownMax | 接收到动作表情后触发 | |||
SMART_EVENT_HAS_AURA | 23 | SpellID | Stack amount | RepeatMin | RepeatMax | 拥有特定法术光环后触发 | ||
SMART_EVENT_TARGET_BUFFED | 24 | SpellID | Stack amount | RepeatMin | RepeatMax | 当前目标获得法术后触发 | ||
SMART_EVENT_RESET | 25 | 战斗结束后,生物(重新)刷新后触发 | ||||||
SMART_EVENT_IC_LOS | 26 | HostilityMode: 1: NotHostile 2: Any | MaxRange | CooldownMin | CooldownMax | Player Only? (0/1) | 在战斗状态下,与目标相隔特定距离后触发 | |
SMART_EVENT_PASSENGER_BOARDED | 27 | CooldownMin | CooldownMax | |||||
SMART_EVENT_PASSENGER_REMOVED | 28 | CooldownMin | CooldownMax | |||||
SMART_EVENT_CHARMED | 29 | 0: on charm apply 1: on charm remove | 对象被控制后触发(0:被控制 1:控制解除) | |||||
SMART_EVENT_CHARMED_TARGET | 30 | 对象当前目标被控制后触发 UNUSED, DO NOT REUSE | ||||||
SMART_EVENT_SPELLHIT_TARGET | 31 | SpellId | School | RepeatMin | RepeatMax | 对象当前目标被特定技能击中后触发,School参数如下 (0:普通 1:神圣 2:火焰 3:自然 4:冰霜 5:暗影 6:秘法) | ||
SMART_EVENT_DAMAGED | 32 | MinDmg | MaxDmg | RepeatMin | RepeatMax | 对象受到特定伤害后触发 | ||
SMART_EVENT_DAMAGED_TARGET | 33 | MinDmg | MaxDmg | RepeatMin | RepeatMax | 对象当前目标受到特定伤害后触发 | ||
SMART_EVENT_MOVEMENTINFORM | 34 | MovementType 1: Random 2: Waypoint 16: Effect (Jump) | PointID | 按指定的移动方式移动后触发 MovementType 取值参见源码 MovementDefines.h 的 MovementType 定义 | ||||
SMART_EVENT_SUMMON_DESPAWNED | 35 | creature_template.entry | CooldownMin | CooldownMax | 召唤的对象消失后触发 | |||
SMART_EVENT_CORPSE_REMOVED | 36 | 尸体消失后触发 | ||||||
SMART_EVENT_AI_INIT | 37 | AI初始化后触发 | ||||||
SMART_EVENT_DATA_SET | 38 | Field | Value | CooldownMin | CooldownMax | 当被设置未特定数据后触发,应与以下动作联用:SMART_ACTION_SET_DATA | ||
SMART_EVENT_WAYPOINT_START | 39 | PointId (0: any) | pathId (0: any) | 对象开始按设定路径移动后触发 UNUSED, DO NOT REUSE | ||||
SMART_EVENT_WAYPOINT_REACHED | 40 | PointId (0: any) | pathId (0: any) | 生物到达设定路径点后触发 | ||||
SMART_EVENT_TRANSPORT_ADDPLAYER | 41 | 功能暂未实现 | ||||||
SMART_EVENT_TRANSPORT_ADDCREATURE | 42 | Entry (0: any) | 功能暂未实现 | |||||
SMART_EVENT_TRANSPORT_REMOVE_PLAYER | 43 | 功能暂未实现 | ||||||
SMART_EVENT_TRANSPORT_RELOCATE | 44 | PointId | 功能暂未实现 | |||||
SMART_EVENT_INSTANCE_PLAYER_ENTER | 45 | Team (0: any) | CooldownMin | CooldownMax | 功能暂未实现 | |||
SMART_EVENT_AREATRIGGER_ONTRIGGER | 46 | TriggerId (0: any) | 区域触发器触发后触发 | |||||
SMART_EVENT_QUEST_ACCEPTED | 47 | (任意)任务接取后触发 | ||||||
SMART_EVENT_QUEST_OBJ_COMPLETION | 48 | quest_objectives.ID | 任务目标达成后触发 | |||||
SMART_EVENT_QUEST_COMPLETION | 49 | (任意)任务完成后触发(未提交前) | ||||||
SMART_EVENT_QUEST_REWARDED | 50 | (任意)任务获取奖励后触发(提交后) | ||||||
SMART_EVENT_QUEST_FAIL | 51 | (任意)任务失败后触发 | ||||||
SMART_EVENT_TEXT_OVER | 52 | creature_text.GroupID | creature_text.CreatureID (0 any) | action_type=1(SMART_ACTION_TALK)触发后,文字显示完后触发 | ||||
SMART_EVENT_RECEIVE_HEAL | 53 | MinHeal | MaxHeal | CooldownMin | CooldownMax | 受到特定治疗量后触发 | ||
SMART_EVENT_JUST_SUMMONED | 54 | 召唤后触发 | ||||||
SMART_EVENT_WAYPOINT_PAUSED | 55 | PointId (0: any) | pathID (0: any) | 在特定路径点停留后触发(恢复后可继续沿路径点移动) | ||||
SMART_EVENT_WAYPOINT_RESUMED | 56 | PointId (0: any) | pathID (0: any) | 恢复沿路径点移动后触发 | ||||
SMART_EVENT_WAYPOINT_STOPPED | 57 | PointId (0: any) | pathID (0: any) | 在特定路径点终止移动后触发(不可恢复) | ||||
SMART_EVENT_WAYPOINT_ENDED | 58 | PointId (0: any) | pathID (0: any) | (整个)移动路径结束时触发 | ||||
SMART_EVENT_TIMED_EVENT_TRIGGERED | 59 | id | On timed event triggered (See SMART_ACTION_TRIGGER_TIMED_EVENT) | |||||
SMART_EVENT_UPDATE | 60 | InitialMin | InitialMax | RepeatMin | RepeatMax | 当事件 update 时触发 | ||
SMART_EVENT_LINK | 61 | 用来连接多个事件, 用前一事件的 link 值进行关联 | ||||||
SMART_EVENT_GOSSIP_SELECT | 62 | gossip_menu_option.MenuID | gossip_menu_option.OptionID | 选择对话面板特定选项后触发 | ||||
SMART_EVENT_JUST_CREATED | 63 | 当刷新、重新刷新、被召唤时触发 | ||||||
SMART_EVENT_GOSSIP_HELLO | 64 | for gameobject only 0: On gossip hello and on report use 1: On gossip hello 2: On report use | 对设置有对话面板的对象单击右键后触发 | |||||
SMART_EVENT_FOLLOW_COMPLETED | 65 | 当跟随动作完成后触发 | ||||||
SMART_EVENT_EVENT_PHASE_CHANGE | 66 | event phase mask | 事件阶段改变后触发 UNUSED, DO NOT REUSE | |||||
SMART_EVENT_IS_BEHIND_TARGET (unused on 3.3.5) | 67 | CooldownMin | CooldownMax | On Creature is behind target UNUSED, DO NOT REUSE | ||||
SMART_EVENT_GAME_EVENT_START | 68 | game_event.eventEntry | 当游戏事件开始时触发 | |||||
SMART_EVENT_GAME_EVENT_END | 69 | game_event.eventEntry | 当游戏事件结束时触发 | |||||
SMART_EVENT_GO_LOOT_STATE_CHANGED | 70 | State: 1: Ready 3: Just deactivated | 当 gameobject 的 state 发生改变时触发 | |||||
SMART_EVENT_GO_EVENT_INFORM | 71 | EventId | On go event inform | |||||
SMART_EVENT_ACTION_DONE | 72 | ActionId | On action done (See SMART_ACTION_DO_ACTION) | |||||
SMART_EVENT_ON_SPELLCLICK | 73 | On spellclick | ||||||
SMART_EVENT_FRIENDLY_HEALTH_PCT | 74 | MinHpPct | MaxHpPct | RepeatMin | RepeatMax | Radius | 当友方生命值百分比为特定值时触发 | |
SMART_EVENT_DISTANCE_CREATURE | 75 | creature.guid | creature_template.entry | Distance | Repeat interval (ms) | On creature guid OR any instance of creature entry is within distance. | ||
SMART_EVENT_DISTANCE_GAMEOBJECT | 76 | gameobject.guid | gameobject_template.entry | Distance | Repeat interval (ms) | On gameobject guid OR any instance of gameobject entry is within distance. | ||
SMART_EVENT_COUNTER_SET | 77 | CounterID | Value | CooldownMin | CooldownMax | 当计数器等于特定值时触发,应与以下动作联用:SMART_ACTION_SET_COUNTER | ||
SMART_EVENT_SCENE_START | 78 | 当场景开始时触发 | ||||||
SMART_EVENT_SCENE_TRIGGER | 79 | triggerName | 当触发场景时触发 | |||||
SMART_EVENT_SCENE_CANCEL | 80 | 当场景取消时触发 | ||||||
SMART_EVENT_SCENE_COMPLETE | 81 | 当场景完成时触发 | ||||||
SMART_EVENT_SUMMONED_UNIT_DIES | 82 | CreatureId(0 all) | CooldownMin | CooldownMax | 当召唤的生物死亡时触发 | |||
SMART_EVENT_ON_SPELL_CAST | 83 | SpellID | CooldownMin | CooldownMax | 当成功施放特定法术时触发 | |||
SMART_EVENT_ON_SPELL_FAILED | 84 | SpellID | CooldownMin | CooldownMax | 当施放特定法术失败时触发 | |||
SMART_EVENT_ON_SPELL_START | 85 | SpellID | CooldownMin | CooldownMax | 当特定法术开始(获得)时触发 | |||
SMART_EVENT_ON_DESPAWN | 86 | 当 despawn 时触发 | ||||||
SMART_EVENT_SEND_EVENT_TRIGGER | 87 | 当 GameEvent 触发时触发 |