3#include "Game/LiveActor/Spine.hpp"
18class name : public Nerve\
23 virtual void execute(Spine *) const;\
24 static name sInstance;\
28#define NERVE_EXECEND(name)\
29class name : public Nerve\
34 virtual void execute(Spine *) const;\
35 virtual void executeOnEnd(Spine *) const;\
36 static name sInstance;\
40#define INIT_NERVE(name)\
41 name name::sInstance;\
44#define INIT_NERVE_NEW(name, parent_class, func)\
45 name name::sInstance;\
46 void name::execute(Spine *pSpine) const { \
47 parent_class* actor = reinterpret_cast<parent_class*>(pSpine->mExecutor);\
52#define NERVE_DECL(name, parent_class, func)\
53class name : public Nerve\
58 virtual void execute(Spine *pSpine) const {\
59 parent_class* actor = reinterpret_cast<parent_class*>(pSpine->mExecutor);\
62 static name sInstance;\
66#define NERVE_DECL_ONEND(name, parent_class, func, onEndFunc)\
67class name : public Nerve\
72 virtual void execute(Spine *pSpine) const {\
73 parent_class* actor = reinterpret_cast<parent_class*>(pSpine->mExecutor);\
76 virtual void executeOnEnd(Spine *pSpine) const {\
77 parent_class* actor = reinterpret_cast<parent_class*>(pSpine->mExecutor);\
80 static name sInstance;\
84#define NERVE_DECL_NULL(name)\
85class name : public Nerve\
90 virtual void execute(Spine *pSpine) const {\
92 static name sInstance;\
Used for executing states of a LiveActor.
virtual void execute(Spine *pSpine) const =0
Executes a state based on the host actor.
virtual void executeOnEnd(Spine *pSpine) const
Executes after the last iteration of a state before it executes another state.