Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //hpp
- template<class T>
- class CEntityMetaLib
- {
- private:
- const char *name;
- static int (*func)(lua_State*);
- static DynArray<const char*, lua_CFunction> members;
- public:
- CEntityMetaLib()
- {
- name = typeid(T).name();
- }
- /*CEntityMetaLib(const char *key, lua_CFunction int)
- {
- members.insert(cont char *key, func);
- }*/
- };
- #define NewMeta CEntityMetaLib
- //cpp
- NewMeta<IEntity> META;
- META["Spawn"]()
- {
- return 1;
- }
Add Comment
Please, Sign In to add comment