| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378 |
- //this source code was auto-generated by tolua#, do not modify it
- using System;
- using LuaInterface;
- public class BuffParamWrap
- {
- public static void Register(LuaState L)
- {
- L.BeginClass(typeof(BuffParam), null);
- L.RegFunction("ToJson", ToJson);
- L.RegFunction("New", _CreateBuffParam);
- L.RegFunction("__tostring", ToLua.op_ToString);
- L.RegVar("buffId", get_buffId, set_buffId);
- L.RegVar("ratio", get_ratio, set_ratio);
- L.RegVar("cd", get_cd, set_cd);
- L.RegVar("type", get_type, set_type);
- L.RegVar("casterType", get_casterType, set_casterType);
- L.RegVar("extendPara", get_extendPara, set_extendPara);
- L.RegVar("funStr", get_funStr, set_funStr);
- L.EndClass();
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int _CreateBuffParam(IntPtr L)
- {
- try
- {
- int count = LuaDLL.lua_gettop(L);
- if (count == 1)
- {
- JSONObject arg0 = (JSONObject)ToLua.CheckObject<JSONObject>(L, 1);
- BuffParam obj = new BuffParam(arg0);
- ToLua.PushValue(L, obj);
- return 1;
- }
- else if (count == 4)
- {
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 1);
- int arg1 = (int)LuaDLL.luaL_checknumber(L, 2);
- int arg2 = (int)LuaDLL.luaL_checknumber(L, 3);
- int arg3 = (int)LuaDLL.luaL_checknumber(L, 4);
- BuffParam obj = new BuffParam(arg0, arg1, arg2, arg3);
- ToLua.PushValue(L, obj);
- return 1;
- }
- else if (count == 5)
- {
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 1);
- int arg1 = (int)LuaDLL.luaL_checknumber(L, 2);
- int arg2 = (int)LuaDLL.luaL_checknumber(L, 3);
- int arg3 = (int)LuaDLL.luaL_checknumber(L, 4);
- string arg4 = ToLua.CheckString(L, 5);
- BuffParam obj = new BuffParam(arg0, arg1, arg2, arg3, arg4);
- ToLua.PushValue(L, obj);
- return 1;
- }
- else if (count == 6)
- {
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 1);
- int arg1 = (int)LuaDLL.luaL_checknumber(L, 2);
- int arg2 = (int)LuaDLL.luaL_checknumber(L, 3);
- int arg3 = (int)LuaDLL.luaL_checknumber(L, 4);
- int arg4 = (int)LuaDLL.luaL_checknumber(L, 5);
- string arg5 = ToLua.CheckString(L, 6);
- BuffParam obj = new BuffParam(arg0, arg1, arg2, arg3, arg4, arg5);
- ToLua.PushValue(L, obj);
- return 1;
- }
- else if (count == 0)
- {
- BuffParam obj = new BuffParam();
- ToLua.PushValue(L, obj);
- return 1;
- }
- else
- {
- return LuaDLL.luaL_throw(L, "invalid arguments to ctor method: BuffParam.New");
- }
- }
- catch (Exception e)
- {
- return LuaDLL.toluaL_exception(L, e);
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int ToJson(IntPtr L)
- {
- try
- {
- ToLua.CheckArgsCount(L, 1);
- BuffParam obj = (BuffParam)ToLua.CheckObject(L, 1, typeof(BuffParam));
- JSONObject o = obj.ToJson();
- ToLua.PushObject(L, o);
- ToLua.SetBack(L, 1, obj);
- return 1;
- }
- catch (Exception e)
- {
- return LuaDLL.toluaL_exception(L, e);
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int get_buffId(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int ret = obj.buffId;
- LuaDLL.lua_pushinteger(L, ret);
- return 1;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index buffId on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int get_ratio(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int ret = obj.ratio;
- LuaDLL.lua_pushinteger(L, ret);
- return 1;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index ratio on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int get_cd(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int ret = obj.cd;
- LuaDLL.lua_pushinteger(L, ret);
- return 1;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index cd on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int get_type(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int ret = obj.type;
- LuaDLL.lua_pushinteger(L, ret);
- return 1;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index type on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int get_casterType(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int ret = obj.casterType;
- LuaDLL.lua_pushinteger(L, ret);
- return 1;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index casterType on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int get_extendPara(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int ret = obj.extendPara;
- LuaDLL.lua_pushinteger(L, ret);
- return 1;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index extendPara on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int get_funStr(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- string ret = obj.funStr;
- LuaDLL.lua_pushstring(L, ret);
- return 1;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index funStr on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int set_buffId(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
- obj.buffId = arg0;
- ToLua.SetBack(L, 1, obj);
- return 0;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index buffId on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int set_ratio(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
- obj.ratio = arg0;
- ToLua.SetBack(L, 1, obj);
- return 0;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index ratio on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int set_cd(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
- obj.cd = arg0;
- ToLua.SetBack(L, 1, obj);
- return 0;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index cd on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int set_type(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
- obj.type = arg0;
- ToLua.SetBack(L, 1, obj);
- return 0;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index type on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int set_casterType(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
- obj.casterType = arg0;
- ToLua.SetBack(L, 1, obj);
- return 0;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index casterType on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int set_extendPara(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
- obj.extendPara = arg0;
- ToLua.SetBack(L, 1, obj);
- return 0;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index extendPara on a nil value");
- }
- }
- [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
- static int set_funStr(IntPtr L)
- {
- object o = null;
- try
- {
- o = ToLua.ToObject(L, 1);
- BuffParam obj = (BuffParam)o;
- string arg0 = ToLua.CheckString(L, 2);
- obj.funStr = arg0;
- ToLua.SetBack(L, 1, obj);
- return 0;
- }
- catch(Exception e)
- {
- return LuaDLL.toluaL_exception(L, e, o, "attempt to index funStr on a nil value");
- }
- }
- }
|