#if USE_UNI_LUA using LuaAPI = UniLua.Lua; using RealStatePtr = UniLua.ILuaState; using LuaCSFunction = UniLua.CSharpFunctionDelegate; #else using LuaAPI = XLua.LuaDLL.Lua; using RealStatePtr = System.IntPtr; using LuaCSFunction = XLua.LuaDLL.lua_CSFunction; #endif using XLua; using System.Collections.Generic; namespace XLua.CSObjectWrap { using Utils = XLua.Utils; public class UnityEngineScalableBufferManagerWrap { public static void __Register(RealStatePtr L) { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); System.Type type = typeof(UnityEngine.ScalableBufferManager); Utils.BeginObjectRegister(type, L, translator, 0, 0, 0, 0); Utils.EndObjectRegister(type, L, translator, null, null, null, null, null); Utils.BeginClassRegister(type, L, __CreateInstance, 2, 2, 0); Utils.RegisterFunc(L, Utils.CLS_IDX, "ResizeBuffers", _m_ResizeBuffers_xlua_st_); Utils.RegisterFunc(L, Utils.CLS_GETTER_IDX, "widthScaleFactor", _g_get_widthScaleFactor); Utils.RegisterFunc(L, Utils.CLS_GETTER_IDX, "heightScaleFactor", _g_get_heightScaleFactor); Utils.EndClassRegister(type, L, translator); } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int __CreateInstance(RealStatePtr L) { return LuaAPI.luaL_error(L, "UnityEngine.ScalableBufferManager does not have a constructor!"); } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_ResizeBuffers_xlua_st_(RealStatePtr L) { try { { float _widthScale = (float)LuaAPI.lua_tonumber(L, 1); float _heightScale = (float)LuaAPI.lua_tonumber(L, 2); UnityEngine.ScalableBufferManager.ResizeBuffers( _widthScale, _heightScale ); return 0; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_widthScaleFactor(RealStatePtr L) { try { LuaAPI.lua_pushnumber(L, UnityEngine.ScalableBufferManager.widthScaleFactor); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_heightScaleFactor(RealStatePtr L) { try { LuaAPI.lua_pushnumber(L, UnityEngine.ScalableBufferManager.heightScaleFactor); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } } }