#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 FeatureNoticeModelWrap
|
{
|
public static void __Register(RealStatePtr L)
|
{
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
System.Type type = typeof(FeatureNoticeModel);
|
Utils.BeginObjectRegister(type, L, translator, 0, 9, 6, 6);
|
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "Init", _m_Init);
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "OnBeforePlayerDataInitialize", _m_OnBeforePlayerDataInitialize);
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "OnPlayerLoginOk", _m_OnPlayerLoginOk);
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "UnInit", _m_UnInit);
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "WhetherToPlayTheBox", _m_WhetherToPlayTheBox);
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetOpenLv", _m_GetOpenLv);
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "OpenFuncAwardState", _m_OpenFuncAwardState);
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "SendGetAward", _m_SendGetAward);
|
|
Utils.RegisterFunc(L, Utils.METHOD_IDX, "UpdateAwarfItem", _e_UpdateAwarfItem);
|
|
Utils.RegisterFunc(L, Utils.GETTER_IDX, "FunctionList", _g_get_FunctionList);
|
Utils.RegisterFunc(L, Utils.GETTER_IDX, "DicAwardItem", _g_get_DicAwardItem);
|
Utils.RegisterFunc(L, Utils.GETTER_IDX, "DicOpenFuncState", _g_get_DicOpenFuncState);
|
Utils.RegisterFunc(L, Utils.GETTER_IDX, "DicRedPoint", _g_get_DicRedPoint);
|
Utils.RegisterFunc(L, Utils.GETTER_IDX, "redPointStre1", _g_get_redPointStre1);
|
Utils.RegisterFunc(L, Utils.GETTER_IDX, "FunctionForecastIndex", _g_get_FunctionForecastIndex);
|
|
Utils.RegisterFunc(L, Utils.SETTER_IDX, "FunctionList", _s_set_FunctionList);
|
Utils.RegisterFunc(L, Utils.SETTER_IDX, "DicAwardItem", _s_set_DicAwardItem);
|
Utils.RegisterFunc(L, Utils.SETTER_IDX, "DicOpenFuncState", _s_set_DicOpenFuncState);
|
Utils.RegisterFunc(L, Utils.SETTER_IDX, "DicRedPoint", _s_set_DicRedPoint);
|
Utils.RegisterFunc(L, Utils.SETTER_IDX, "redPointStre1", _s_set_redPointStre1);
|
Utils.RegisterFunc(L, Utils.SETTER_IDX, "FunctionForecastIndex", _s_set_FunctionForecastIndex);
|
|
|
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)
|
{
|
|
FeatureNoticeModel gen_ret = new FeatureNoticeModel();
|
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 FeatureNoticeModel constructor!");
|
|
}
|
|
|
|
|
|
|
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _m_Init(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
|
gen_to_be_invoked.Init( );
|
|
|
|
return 0;
|
}
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _m_OnBeforePlayerDataInitialize(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
|
gen_to_be_invoked.OnBeforePlayerDataInitialize( );
|
|
|
|
return 0;
|
}
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _m_OnPlayerLoginOk(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
|
gen_to_be_invoked.OnPlayerLoginOk( );
|
|
|
|
return 0;
|
}
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _m_UnInit(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
|
gen_to_be_invoked.UnInit( );
|
|
|
|
return 0;
|
}
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _m_WhetherToPlayTheBox(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
|
System.Collections.IEnumerator gen_ret = gen_to_be_invoked.WhetherToPlayTheBox( );
|
translator.PushAny(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_GetOpenLv(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
int _Inedx = LuaAPI.xlua_tointeger(L, 2);
|
|
int gen_ret = gen_to_be_invoked.GetOpenLv( _Inedx );
|
LuaAPI.xlua_pushinteger(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_OpenFuncAwardState(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
HA302_tagMCFuncOpenStateList _info = (HA302_tagMCFuncOpenStateList)translator.GetObject(L, 2, typeof(HA302_tagMCFuncOpenStateList));
|
|
gen_to_be_invoked.OpenFuncAwardState( _info );
|
|
|
|
return 0;
|
}
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _m_SendGetAward(RealStatePtr L)
|
{
|
try {
|
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
|
|
|
{
|
int _OpenFuncId = LuaAPI.xlua_tointeger(L, 2);
|
|
gen_to_be_invoked.SendGetAward( _OpenFuncId );
|
|
|
|
return 0;
|
}
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
|
}
|
|
|
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _g_get_FunctionList(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
translator.Push(L, gen_to_be_invoked.FunctionList);
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 1;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _g_get_DicAwardItem(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
translator.Push(L, gen_to_be_invoked.DicAwardItem);
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 1;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _g_get_DicOpenFuncState(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
translator.Push(L, gen_to_be_invoked.DicOpenFuncState);
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 1;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _g_get_DicRedPoint(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
translator.Push(L, gen_to_be_invoked.DicRedPoint);
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 1;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _g_get_redPointStre1(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
translator.Push(L, gen_to_be_invoked.redPointStre1);
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 1;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _g_get_FunctionForecastIndex(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.FunctionForecastIndex);
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 1;
|
}
|
|
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _s_set_FunctionList(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
gen_to_be_invoked.FunctionList = (System.Collections.Generic.List<TableConfig.FunctionForecastConfig>)translator.GetObject(L, 2, typeof(System.Collections.Generic.List<TableConfig.FunctionForecastConfig>));
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 0;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _s_set_DicAwardItem(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
gen_to_be_invoked.DicAwardItem = (System.Collections.Generic.Dictionary<int, Snxxz.UI.ImpactRankModel.RankAwardItem>)translator.GetObject(L, 2, typeof(System.Collections.Generic.Dictionary<int, Snxxz.UI.ImpactRankModel.RankAwardItem>));
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 0;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _s_set_DicOpenFuncState(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
gen_to_be_invoked.DicOpenFuncState = (System.Collections.Generic.Dictionary<int, FeatureNoticeModel.OpenFuncState>)translator.GetObject(L, 2, typeof(System.Collections.Generic.Dictionary<int, FeatureNoticeModel.OpenFuncState>));
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 0;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _s_set_DicRedPoint(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
gen_to_be_invoked.DicRedPoint = (System.Collections.Generic.Dictionary<int, Snxxz.UI.Redpoint>)translator.GetObject(L, 2, typeof(System.Collections.Generic.Dictionary<int, Snxxz.UI.Redpoint>));
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 0;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _s_set_redPointStre1(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
gen_to_be_invoked.redPointStre1 = (Snxxz.UI.Redpoint)translator.GetObject(L, 2, typeof(Snxxz.UI.Redpoint));
|
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
return 0;
|
}
|
|
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
static int _s_set_FunctionForecastIndex(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
gen_to_be_invoked.FunctionForecastIndex = 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 _e_UpdateAwarfItem(RealStatePtr L)
|
{
|
try {
|
ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
|
int gen_param_count = LuaAPI.lua_gettop(L);
|
FeatureNoticeModel gen_to_be_invoked = (FeatureNoticeModel)translator.FastGetCSObj(L, 1);
|
System.Action gen_delegate = translator.GetDelegate<System.Action>(L, 3);
|
if (gen_delegate == null) {
|
return LuaAPI.luaL_error(L, "#3 need System.Action!");
|
}
|
|
if (gen_param_count == 3)
|
{
|
|
if (LuaAPI.xlua_is_eq_str(L, 2, "+")) {
|
gen_to_be_invoked.UpdateAwarfItem += gen_delegate;
|
return 0;
|
}
|
|
|
if (LuaAPI.xlua_is_eq_str(L, 2, "-")) {
|
gen_to_be_invoked.UpdateAwarfItem -= gen_delegate;
|
return 0;
|
}
|
|
}
|
} catch(System.Exception gen_e) {
|
return LuaAPI.luaL_error(L, "c# exception:" + gen_e);
|
}
|
LuaAPI.luaL_error(L, "invalid arguments to FeatureNoticeModel.UpdateAwarfItem!");
|
return 0;
|
}
|
|
|
|
}
|
}
|