Feat(AllCreatureEvent): Add RegisterAllCreatureEvent and support for CreatureTemplate object. (#312)

This commit is contained in:
iThorgrim
2025-09-17 11:54:52 +02:00
committed by GitHub
parent 1153fcaef7
commit 313596f86e
7 changed files with 207 additions and 20 deletions

View File

@@ -88,6 +88,7 @@ namespace Hooks
REGTYPE_INSTANCE,
REGTYPE_TICKET,
REGTYPE_SPELL,
REGTYPE_ALL_CREATURE,
REGTYPE_COUNT
};
@@ -398,6 +399,15 @@ namespace Hooks
SPELL_EVENT_ON_CAST_CANCEL = 3, // (event, caster, spell, bySelf)
SPELL_EVENT_COUNT
};
enum AllCreatureEvents
{
ALL_CREATURE_EVENT_ON_ADD = 1, // (event, creature)
ALL_CREATURE_EVENT_ON_REMOVE = 2, // (event, creature)
ALL_CREATURE_EVENT_ON_SELECT_LEVEL = 3, // (event, creature_template, creature)
ALL_CREATURE_EVENT_ON_BEFORE_SELECT_LEVEL = 4, // (event, creature_template, creature, level) - Can return the new level
ALL_CREATURE_EVENT_COUNT
};
};
#endif // _HOOKS_H