| | |
| | | { |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | System.Type type = typeof(PrepareHandler); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 5, 8, 7); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 7, 8, 7); |
| | | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "TriggerOnShowCollect", _m_TriggerOnShowCollect); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "Init", _m_Init); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "HandleCallback", _m_HandleCallback); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "Arrive", _m_Arrive); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "Leave", _m_Leave); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "ServerPrepareStart", _m_ServerPrepareStart); |
| | |
| | | |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_TriggerOnShowCollect(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | PrepareHandler gen_to_be_invoked = (PrepareHandler)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | |
| | | { |
| | | uint _sid = LuaAPI.xlua_touint(L, 2); |
| | | int _npcId = LuaAPI.xlua_tointeger(L, 3); |
| | | |
| | | gen_to_be_invoked.TriggerOnShowCollect( _sid, _npcId ); |
| | | |
| | | |
| | | |
| | | return 0; |
| | | } |
| | | |
| | | } catch(System.Exception gen_e) { |
| | | return LuaAPI.luaL_error(L, "c# exception:" + gen_e); |
| | | } |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_Init(RealStatePtr L) |
| | | { |
| | | try { |
| | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_HandleCallback(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | PrepareHandler gen_to_be_invoked = (PrepareHandler)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | |
| | | { |
| | | E_NpcType _type;translator.Get(L, 2, out _type); |
| | | int _npcID = LuaAPI.xlua_tointeger(L, 3); |
| | | uint _sid = LuaAPI.xlua_touint(L, 4); |
| | | |
| | | gen_to_be_invoked.HandleCallback( _type, _npcID, _sid ); |
| | | |
| | | |
| | | |
| | | return 0; |
| | | } |
| | | |
| | | } catch(System.Exception gen_e) { |
| | | return LuaAPI.luaL_error(L, "c# exception:" + gen_e); |
| | | } |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_Arrive(RealStatePtr L) |
| | | { |
| | | try { |