diff options
author | megamage <none@none> | 2009-04-17 15:36:10 -0500 |
---|---|---|
committer | megamage <none@none> | 2009-04-17 15:36:10 -0500 |
commit | b9d8bdeddde70359c4a3b115ccb646abb59357cc (patch) | |
tree | bf8572ad03523f0b86ad9d7ea72b481148d123ee /src | |
parent | f0cbed1ad8376200bb450768d7b77198e6754113 (diff) |
*Remove event_ai from script folder.
--HG--
branch : trunk
Diffstat (limited to 'src')
-rw-r--r-- | src/bindings/scripts/CMakeLists.txt | 2 | ||||
-rw-r--r-- | src/bindings/scripts/VC80/80ScriptDev2.vcproj | 8 | ||||
-rw-r--r-- | src/bindings/scripts/VC90/90ScriptDev2.vcproj | 8 | ||||
-rw-r--r-- | src/bindings/scripts/scripts/creature/mob_event_ai.cpp | 15 | ||||
-rw-r--r-- | src/bindings/scripts/scripts/creature/mob_event_ai.h | 5 | ||||
-rw-r--r-- | src/game/CreatureEventAI.cpp | 14 | ||||
-rw-r--r-- | src/game/CreatureEventAI.h | 7 |
7 files changed, 18 insertions, 41 deletions
diff --git a/src/bindings/scripts/CMakeLists.txt b/src/bindings/scripts/CMakeLists.txt index fd941cd8164..cae1c65f4dc 100644 --- a/src/bindings/scripts/CMakeLists.txt +++ b/src/bindings/scripts/CMakeLists.txt @@ -15,8 +15,6 @@ SET(trinityscript_LIB_SRCS scripts/boss/boss_lethon.cpp scripts/boss/boss_taerar.cpp scripts/boss/boss_ysondre.cpp - scripts/creature/mob_event_ai.cpp - scripts/creature/mob_event_ai.h scripts/creature/mob_generic_creature.cpp scripts/creature/simple_ai.cpp scripts/creature/simple_ai.h diff --git a/src/bindings/scripts/VC80/80ScriptDev2.vcproj b/src/bindings/scripts/VC80/80ScriptDev2.vcproj index 8fd97430dbc..b07fb701c75 100644 --- a/src/bindings/scripts/VC80/80ScriptDev2.vcproj +++ b/src/bindings/scripts/VC80/80ScriptDev2.vcproj @@ -387,14 +387,6 @@ Name="creature" > <File - RelativePath="..\scripts\creature\mob_event_ai.cpp" - > - </File> - <File - RelativePath="..\scripts\creature\mob_event_ai.h" - > - </File> - <File RelativePath="..\scripts\creature\mob_generic_creature.cpp" > </File> diff --git a/src/bindings/scripts/VC90/90ScriptDev2.vcproj b/src/bindings/scripts/VC90/90ScriptDev2.vcproj index 57b7db8f253..423f64fc077 100644 --- a/src/bindings/scripts/VC90/90ScriptDev2.vcproj +++ b/src/bindings/scripts/VC90/90ScriptDev2.vcproj @@ -386,14 +386,6 @@ Name="creature" > <File - RelativePath="..\scripts\creature\mob_event_ai.cpp" - > - </File> - <File - RelativePath="..\scripts\creature\mob_event_ai.h" - > - </File> - <File RelativePath="..\scripts\creature\mob_generic_creature.cpp" > </File> diff --git a/src/bindings/scripts/scripts/creature/mob_event_ai.cpp b/src/bindings/scripts/scripts/creature/mob_event_ai.cpp deleted file mode 100644 index dc88ed98679..00000000000 --- a/src/bindings/scripts/scripts/creature/mob_event_ai.cpp +++ /dev/null @@ -1,15 +0,0 @@ -#include "precompiled.h" - case ACTION_T_SUMMON_GO: - { - GameObject* pObject = NULL; - - float x,y,z; - m_creature->GetPosition(x,y,z); - pObject = m_creature->SummonGameObject(param1, x, y, z, 0, 0, 0, 0, 0, param2); - if (!pObject) - { - if (EAI_ErrorLevel > 0) - error_db_log( "SD2: EventAI failed to spawn object %u. Spawn event %d is on creature %d", param1, EventId, m_creature->GetEntry()); - } - } - break; diff --git a/src/bindings/scripts/scripts/creature/mob_event_ai.h b/src/bindings/scripts/scripts/creature/mob_event_ai.h deleted file mode 100644 index 9dc89f8cad3..00000000000 --- a/src/bindings/scripts/scripts/creature/mob_event_ai.h +++ /dev/null @@ -1,5 +0,0 @@ -#ifndef SC_EVENTAI_H -#define SC_EVENTAI_H - ACTION_T_SUMMON_GO = 39, //GameObjectID, DespawnTime in ms -#endif - diff --git a/src/game/CreatureEventAI.cpp b/src/game/CreatureEventAI.cpp index f39948dabd7..88e922bc16b 100644 --- a/src/game/CreatureEventAI.cpp +++ b/src/game/CreatureEventAI.cpp @@ -984,6 +984,20 @@ void CreatureEventAI::ProcessAction(uint16 type, uint32 param1, uint32 param2, u case ACTION_T_ATTACK_START_PULSE: AttackStart(me->SelectNearestTarget((float)param1)); break; + case ACTION_T_SUMMON_GO: + { + GameObject* pObject = NULL; + + float x,y,z; + m_creature->GetPosition(x,y,z); + pObject = m_creature->SummonGameObject(param1, x, y, z, 0, 0, 0, 0, 0, param2); + if (!pObject) + { + if (EAI_ErrorLevel > 0) + error_db_log( "SD2: EventAI failed to spawn object %u. Spawn event %d is on creature %d", param1, EventId, m_creature->GetEntry()); + } + } + break; } } diff --git a/src/game/CreatureEventAI.h b/src/game/CreatureEventAI.h index f5e89026508..056748631ee 100644 --- a/src/game/CreatureEventAI.h +++ b/src/game/CreatureEventAI.h @@ -103,9 +103,10 @@ enum EventAI_ActionType ACTION_T_DIE = 37, //No Params ACTION_T_ZONE_COMBAT_PULSE = 38, //No Params - ACTION_T_SET_ACTIVE = 101, //Apply - ACTION_T_SET_AGGRESSIVE = 102, //Apply - ACTION_T_ATTACK_START_PULSE = 103, //Distance + ACTION_T_SET_ACTIVE = 101, //Apply + ACTION_T_SET_AGGRESSIVE = 102, //Apply + ACTION_T_ATTACK_START_PULSE = 103, //Distance + ACTION_T_SUMMON_GO = 104, //GameObjectID, DespawnTime in ms ACTION_T_END, }; |