| | |
| | | { |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | System.Type type = typeof(UnityEngine.Transform); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 21, 19, 13); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 25, 19, 13); |
| | | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "SetParent", _m_SetParent); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "SetPositionAndRotation", _m_SetPositionAndRotation); |
| | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsChildOf", _m_IsChildOf); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetEnumerator", _m_GetEnumerator); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetChild", _m_GetChild); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "SetParentEx", _m_SetParentEx); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetChildTransformDeeply", _m_GetChildTransformDeeply); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "SetPosition", _m_SetPosition); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetRoot", _m_GetRoot); |
| | | |
| | | |
| | | Utils.RegisterFunc(L, Utils.GETTER_IDX, "position", _g_get_position); |
| | |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_SetParentEx(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | UnityEngine.Transform gen_to_be_invoked = (UnityEngine.Transform)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | int gen_param_count = LuaAPI.lua_gettop(L); |
| | | |
| | | if(gen_param_count == 5&& translator.Assignable<UnityEngine.Transform>(L, 2)&& translator.Assignable<UnityEngine.Vector3>(L, 3)&& translator.Assignable<UnityEngine.Quaternion>(L, 4)&& translator.Assignable<UnityEngine.Vector3>(L, 5)) |
| | | { |
| | | UnityEngine.Transform _parent = (UnityEngine.Transform)translator.GetObject(L, 2, typeof(UnityEngine.Transform)); |
| | | UnityEngine.Vector3 _localPosition;translator.Get(L, 3, out _localPosition); |
| | | UnityEngine.Quaternion _rotation;translator.Get(L, 4, out _rotation); |
| | | UnityEngine.Vector3 _scale;translator.Get(L, 5, out _scale); |
| | | |
| | | gen_to_be_invoked.SetParentEx( _parent, _localPosition, _rotation, _scale ); |
| | | |
| | | |
| | | |
| | | return 0; |
| | | } |
| | | if(gen_param_count == 5&& translator.Assignable<UnityEngine.Transform>(L, 2)&& translator.Assignable<UnityEngine.Vector3>(L, 3)&& translator.Assignable<UnityEngine.Vector3>(L, 4)&& translator.Assignable<UnityEngine.Vector3>(L, 5)) |
| | | { |
| | | UnityEngine.Transform _parent = (UnityEngine.Transform)translator.GetObject(L, 2, typeof(UnityEngine.Transform)); |
| | | UnityEngine.Vector3 _localPosition;translator.Get(L, 3, out _localPosition); |
| | | UnityEngine.Vector3 _eulerAngles;translator.Get(L, 4, out _eulerAngles); |
| | | UnityEngine.Vector3 _scale;translator.Get(L, 5, out _scale); |
| | | |
| | | gen_to_be_invoked.SetParentEx( _parent, _localPosition, _eulerAngles, _scale ); |
| | | |
| | | |
| | | |
| | | return 0; |
| | | } |
| | | |
| | | } catch(System.Exception gen_e) { |
| | | return LuaAPI.luaL_error(L, "c# exception:" + gen_e); |
| | | } |
| | | |
| | | return LuaAPI.luaL_error(L, "invalid arguments to UnityEngine.Transform.SetParentEx!"); |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_GetChildTransformDeeply(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | UnityEngine.Transform gen_to_be_invoked = (UnityEngine.Transform)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | int gen_param_count = LuaAPI.lua_gettop(L); |
| | | |
| | | if(gen_param_count == 3&& (LuaAPI.lua_isnil(L, 2) || LuaAPI.lua_type(L, 2) == LuaTypes.LUA_TSTRING)&& LuaTypes.LUA_TBOOLEAN == LuaAPI.lua_type(L, 3)) |
| | | { |
| | | string _childName = LuaAPI.lua_tostring(L, 2); |
| | | bool _includeSelf = LuaAPI.lua_toboolean(L, 3); |
| | | |
| | | UnityEngine.Transform gen_ret = gen_to_be_invoked.GetChildTransformDeeply( _childName, _includeSelf ); |
| | | translator.Push(L, gen_ret); |
| | | |
| | | |
| | | |
| | | return 1; |
| | | } |
| | | if(gen_param_count == 2&& (LuaAPI.lua_isnil(L, 2) || LuaAPI.lua_type(L, 2) == LuaTypes.LUA_TSTRING)) |
| | | { |
| | | string _childName = LuaAPI.lua_tostring(L, 2); |
| | | |
| | | UnityEngine.Transform gen_ret = gen_to_be_invoked.GetChildTransformDeeply( _childName ); |
| | | 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 UnityEngine.Transform.GetChildTransformDeeply!"); |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_SetPosition(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | UnityEngine.Transform gen_to_be_invoked = (UnityEngine.Transform)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | int gen_param_count = LuaAPI.lua_gettop(L); |
| | | |
| | | if(gen_param_count == 5&& LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 2)&& LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 3)&& LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 4)&& LuaTypes.LUA_TBOOLEAN == LuaAPI.lua_type(L, 5)) |
| | | { |
| | | float _x = (float)LuaAPI.lua_tonumber(L, 2); |
| | | float _y = (float)LuaAPI.lua_tonumber(L, 3); |
| | | float _z = (float)LuaAPI.lua_tonumber(L, 4); |
| | | bool _isLocal = LuaAPI.lua_toboolean(L, 5); |
| | | |
| | | gen_to_be_invoked.SetPosition( _x, _y, _z, _isLocal ); |
| | | |
| | | |
| | | |
| | | return 0; |
| | | } |
| | | if(gen_param_count == 4&& LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 2)&& LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 3)&& LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 4)) |
| | | { |
| | | float _x = (float)LuaAPI.lua_tonumber(L, 2); |
| | | float _y = (float)LuaAPI.lua_tonumber(L, 3); |
| | | float _z = (float)LuaAPI.lua_tonumber(L, 4); |
| | | |
| | | gen_to_be_invoked.SetPosition( _x, _y, _z ); |
| | | |
| | | |
| | | |
| | | return 0; |
| | | } |
| | | |
| | | } catch(System.Exception gen_e) { |
| | | return LuaAPI.luaL_error(L, "c# exception:" + gen_e); |
| | | } |
| | | |
| | | return LuaAPI.luaL_error(L, "invalid arguments to UnityEngine.Transform.SetPosition!"); |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_GetRoot(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | UnityEngine.Transform gen_to_be_invoked = (UnityEngine.Transform)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | |
| | | { |
| | | |
| | | UnityEngine.Transform gen_ret = gen_to_be_invoked.GetRoot( ); |
| | | translator.Push(L, gen_ret); |
| | | |
| | | |
| | | |
| | | return 1; |
| | | } |
| | | |
| | | } catch(System.Exception gen_e) { |
| | | return LuaAPI.luaL_error(L, "c# exception:" + gen_e); |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |