c1_unity/Assets/XLua/Gen/UnityEngine_Playables_PlayableWrap.cs
2023-04-03 11:04:31 +08:00

234 lines
7.1 KiB
C#

#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 UnityEnginePlayablesPlayableWrap
{
public static void __Register(RealStatePtr L)
{
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
System.Type type = typeof(UnityEngine.Playables.Playable);
Utils.BeginObjectRegister(type, L, translator, 0, 3, 0, 0);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetHandle", _m_GetHandle);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetPlayableType", _m_GetPlayableType);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "Equals", _m_Equals);
Utils.EndObjectRegister(type, L, translator, null, null,
null, null, null);
Utils.BeginClassRegister(type, L, __CreateInstance, 2, 1, 0);
Utils.RegisterFunc(L, Utils.CLS_IDX, "Create", _m_Create_xlua_st_);
Utils.RegisterFunc(L, Utils.CLS_GETTER_IDX, "Null", _g_get_Null);
Utils.EndClassRegister(type, L, translator);
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int __CreateInstance(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
if (LuaAPI.lua_gettop(L) == 1)
{
translator.Push(L, default(UnityEngine.Playables.Playable));
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.Playables.Playable constructor!");
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_Create_xlua_st_(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
int gen_param_count = LuaAPI.lua_gettop(L);
if(gen_param_count == 2&& translator.Assignable<UnityEngine.Playables.PlayableGraph>(L, 1)&& LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 2))
{
UnityEngine.Playables.PlayableGraph _graph;translator.Get(L, 1, out _graph);
int _inputCount = LuaAPI.xlua_tointeger(L, 2);
var gen_ret = UnityEngine.Playables.Playable.Create( _graph, _inputCount );
translator.Push(L, gen_ret);
return 1;
}
if(gen_param_count == 1&& translator.Assignable<UnityEngine.Playables.PlayableGraph>(L, 1))
{
UnityEngine.Playables.PlayableGraph _graph;translator.Get(L, 1, out _graph);
var gen_ret = UnityEngine.Playables.Playable.Create( _graph );
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.Playables.Playable.Create!");
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_GetHandle(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
UnityEngine.Playables.Playable gen_to_be_invoked;translator.Get(L, 1, out gen_to_be_invoked);
{
var gen_ret = gen_to_be_invoked.GetHandle( );
translator.Push(L, gen_ret);
translator.Update(L, 1, gen_to_be_invoked);
return 1;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_GetPlayableType(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
UnityEngine.Playables.Playable gen_to_be_invoked;translator.Get(L, 1, out gen_to_be_invoked);
{
var gen_ret = gen_to_be_invoked.GetPlayableType( );
translator.Push(L, gen_ret);
translator.Update(L, 1, gen_to_be_invoked);
return 1;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_Equals(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
UnityEngine.Playables.Playable gen_to_be_invoked;translator.Get(L, 1, out gen_to_be_invoked);
{
UnityEngine.Playables.Playable _other;translator.Get(L, 2, out _other);
var gen_ret = gen_to_be_invoked.Equals( _other );
LuaAPI.lua_pushboolean(L, gen_ret);
translator.Update(L, 1, gen_to_be_invoked);
return 1;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _g_get_Null(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
translator.Push(L, UnityEngine.Playables.Playable.Null);
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
return 1;
}
}
}