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

350 lines
11 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 BFUIEraserTextureWrap
{
public static void __Register(RealStatePtr L)
{
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
System.Type type = typeof(BF.UIEraserTexture);
Utils.BeginObjectRegister(type, L, translator, 0, 7, 2, 2);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "AddTouchEventListener", _m_AddTouchEventListener);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "RemoveEventListener", _m_RemoveEventListener);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "OnPointerDown", _m_OnPointerDown);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "OnPointerUp", _m_OnPointerUp);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "OnCancel", _m_OnCancel);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "ContainsPos", _m_ContainsPos);
Utils.RegisterFunc(L, Utils.METHOD_IDX, "Reset", _m_Reset);
Utils.RegisterFunc(L, Utils.GETTER_IDX, "brushScale", _g_get_brushScale);
Utils.RegisterFunc(L, Utils.GETTER_IDX, "eraseScale", _g_get_eraseScale);
Utils.RegisterFunc(L, Utils.SETTER_IDX, "brushScale", _s_set_brushScale);
Utils.RegisterFunc(L, Utils.SETTER_IDX, "eraseScale", _s_set_eraseScale);
Utils.EndObjectRegister(type, L, translator, null, null,
null, null, null);
Utils.BeginClassRegister(type, L, __CreateInstance, 1, 0, 0);
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)
{
var gen_ret = new BF.UIEraserTexture();
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 BF.UIEraserTexture constructor!");
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_AddTouchEventListener(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
{
System.Action<int, float, float> _func = translator.GetDelegate<System.Action<int, float, float>>(L, 2);
gen_to_be_invoked.AddTouchEventListener( _func );
return 0;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_RemoveEventListener(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
{
gen_to_be_invoked.RemoveEventListener( );
return 0;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_OnPointerDown(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
{
UnityEngine.EventSystems.PointerEventData _eventData = (UnityEngine.EventSystems.PointerEventData)translator.GetObject(L, 2, typeof(UnityEngine.EventSystems.PointerEventData));
gen_to_be_invoked.OnPointerDown( _eventData );
return 0;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_OnPointerUp(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
{
UnityEngine.EventSystems.PointerEventData _eventData = (UnityEngine.EventSystems.PointerEventData)translator.GetObject(L, 2, typeof(UnityEngine.EventSystems.PointerEventData));
gen_to_be_invoked.OnPointerUp( _eventData );
return 0;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_OnCancel(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
{
UnityEngine.EventSystems.BaseEventData _eventData = (UnityEngine.EventSystems.BaseEventData)translator.GetObject(L, 2, typeof(UnityEngine.EventSystems.BaseEventData));
gen_to_be_invoked.OnCancel( _eventData );
return 0;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_ContainsPos(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
{
int _x = LuaAPI.xlua_tointeger(L, 2);
int _y = LuaAPI.xlua_tointeger(L, 3);
var gen_ret = gen_to_be_invoked.ContainsPos( _x, _y );
LuaAPI.lua_pushboolean(L, gen_ret);
return 1;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _m_Reset(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
{
gen_to_be_invoked.Reset( );
return 0;
}
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _g_get_brushScale(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.brushScale);
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
return 1;
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _g_get_eraseScale(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
LuaAPI.lua_pushnumber(L, gen_to_be_invoked.eraseScale);
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
return 1;
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _s_set_brushScale(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
gen_to_be_invoked.brushScale = LuaAPI.xlua_tointeger(L, 2);
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
return 0;
}
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
static int _s_set_eraseScale(RealStatePtr L)
{
try {
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
BF.UIEraserTexture gen_to_be_invoked = (BF.UIEraserTexture)translator.FastGetCSObj(L, 1);
gen_to_be_invoked.eraseScale = (float)LuaAPI.lua_tonumber(L, 2);
} catch(System.Exception gen_e) {
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
}
return 0;
}
}
}