static int _s_set_IsFromPool(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.Entity gen_to_be_invoked = (DCET.Model.Entity)translator.FastGetCSObj(L, 1); gen_to_be_invoked.IsFromPool = LuaAPI.lua_toboolean(L, 2); } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } return(0); }
static int _s_set_Domain(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.Entity gen_to_be_invoked = (DCET.Model.Entity)translator.FastGetCSObj(L, 1); gen_to_be_invoked.Domain = (DCET.Model.Entity)translator.GetObject(L, 2, typeof(DCET.Model.Entity)); } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } return(0); }
static int _g_get_Components(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.Entity gen_to_be_invoked = (DCET.Model.Entity)translator.FastGetCSObj(L, 1); translator.Push(L, gen_to_be_invoked.Components); } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } return(1); }
static int _m_Dispose(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.Entity gen_to_be_invoked = (DCET.Model.Entity)translator.FastGetCSObj(L, 1); { gen_to_be_invoked.Dispose( ); return(0); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_ToString(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.Entity gen_to_be_invoked = (DCET.Model.Entity)translator.FastGetCSObj(L, 1); { string gen_ret = gen_to_be_invoked.ToString( ); LuaAPI.lua_pushstring(L, gen_ret); return(1); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_AddComponent(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.Entity gen_to_be_invoked = (DCET.Model.Entity)translator.FastGetCSObj(L, 1); int gen_param_count = LuaAPI.lua_gettop(L); if (gen_param_count == 2 && translator.Assignable <DCET.Model.Entity>(L, 2)) { DCET.Model.Entity _component = (DCET.Model.Entity)translator.GetObject(L, 2, typeof(DCET.Model.Entity)); DCET.Model.Entity gen_ret = gen_to_be_invoked.AddComponent(_component); translator.Push(L, gen_ret); return(1); } if (gen_param_count == 2 && translator.Assignable <System.Type>(L, 2)) { System.Type _type = (System.Type)translator.GetObject(L, 2, typeof(System.Type)); DCET.Model.Entity gen_ret = gen_to_be_invoked.AddComponent(_type); translator.Push(L, gen_ret); return(1); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } return(LuaAPI.luaL_error(L, "invalid arguments to DCET.Model.Entity.AddComponent!")); }
static int _m_Create_xlua_st_(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); { DCET.Model.Entity _domain = (DCET.Model.Entity)translator.GetObject(L, 1, typeof(DCET.Model.Entity)); long _id = LuaAPI.lua_toint64(L, 2); DCET.Model.Unit gen_ret = DCET.Model.UnitFactory.Create(_domain, _id); translator.Push(L, gen_ret); return(1); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_CreateWithParent_xlua_st_(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); { System.Type _type = (System.Type)translator.GetObject(L, 1, typeof(System.Type)); DCET.Model.Entity _parent = (DCET.Model.Entity)translator.GetObject(L, 2, typeof(DCET.Model.Entity)); DCET.Model.Entity gen_ret = DCET.Model.EntityFactory.CreateWithParent(_type, _parent); translator.Push(L, gen_ret); return(1); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_Peek(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.ComponentQueue gen_to_be_invoked = (DCET.Model.ComponentQueue)translator.FastGetCSObj(L, 1); { DCET.Model.Entity gen_ret = gen_to_be_invoked.Peek( ); translator.Push(L, gen_ret); return(1); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_RegisterSystem(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.EventSystem gen_to_be_invoked = (DCET.Model.EventSystem)translator.FastGetCSObj(L, 1); int gen_param_count = LuaAPI.lua_gettop(L); if (gen_param_count == 3 && translator.Assignable <DCET.Model.Entity>(L, 2) && LuaTypes.LUA_TBOOLEAN == LuaAPI.lua_type(L, 3)) { DCET.Model.Entity _component = (DCET.Model.Entity)translator.GetObject(L, 2, typeof(DCET.Model.Entity)); bool _isRegister = LuaAPI.lua_toboolean(L, 3); gen_to_be_invoked.RegisterSystem(_component, _isRegister); return(0); } if (gen_param_count == 2 && translator.Assignable <DCET.Model.Entity>(L, 2)) { DCET.Model.Entity _component = (DCET.Model.Entity)translator.GetObject(L, 2, typeof(DCET.Model.Entity)); gen_to_be_invoked.RegisterSystem(_component); return(0); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } return(LuaAPI.luaL_error(L, "invalid arguments to DCET.Model.EventSystem.RegisterSystem!")); }
static int _m_Destroy(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.EventSystem gen_to_be_invoked = (DCET.Model.EventSystem)translator.FastGetCSObj(L, 1); { DCET.Model.Entity _component = (DCET.Model.Entity)translator.GetObject(L, 2, typeof(DCET.Model.Entity)); gen_to_be_invoked.Destroy(_component); return(0); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_Recycle(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.ObjectPool gen_to_be_invoked = (DCET.Model.ObjectPool)translator.FastGetCSObj(L, 1); { DCET.Model.Entity _obj = (DCET.Model.Entity)translator.GetObject(L, 2, typeof(DCET.Model.Entity)); gen_to_be_invoked.Recycle(_obj); return(0); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_Get(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.EventSystem gen_to_be_invoked = (DCET.Model.EventSystem)translator.FastGetCSObj(L, 1); { long _instanceId = LuaAPI.lua_toint64(L, 2); DCET.Model.Entity gen_ret = gen_to_be_invoked.Get(_instanceId); translator.Push(L, gen_ret); return(1); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }
static int _m_GetComponent(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); DCET.Model.Entity gen_to_be_invoked = (DCET.Model.Entity)translator.FastGetCSObj(L, 1); { System.Type _type = (System.Type)translator.GetObject(L, 2, typeof(System.Type)); DCET.Model.Entity gen_ret = gen_to_be_invoked.GetComponent(_type); translator.Push(L, gen_ret); return(1); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }