BuffParamWrap.cs 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378
  1. //this source code was auto-generated by tolua#, do not modify it
  2. using System;
  3. using LuaInterface;
  4. public class BuffParamWrap
  5. {
  6. public static void Register(LuaState L)
  7. {
  8. L.BeginClass(typeof(BuffParam), null, "BuffParam");
  9. L.RegFunction("ToJson", ToJson);
  10. L.RegFunction("New", _CreateBuffParam);
  11. L.RegFunction("__tostring", ToLua.op_ToString);
  12. L.RegVar("buffId", get_buffId, set_buffId);
  13. L.RegVar("ratio", get_ratio, set_ratio);
  14. L.RegVar("cd", get_cd, set_cd);
  15. L.RegVar("type", get_type, set_type);
  16. L.RegVar("casterType", get_casterType, set_casterType);
  17. L.RegVar("extendPara", get_extendPara, set_extendPara);
  18. L.RegVar("funStr", get_funStr, set_funStr);
  19. L.EndClass();
  20. }
  21. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  22. static int _CreateBuffParam(IntPtr L)
  23. {
  24. try
  25. {
  26. int count = LuaDLL.lua_gettop(L);
  27. if (count == 1)
  28. {
  29. JSONObject arg0 = (JSONObject)ToLua.CheckObject<JSONObject>(L, 1);
  30. BuffParam obj = new BuffParam(arg0);
  31. ToLua.PushValue(L, obj);
  32. return 1;
  33. }
  34. else if (count == 4)
  35. {
  36. int arg0 = (int)LuaDLL.luaL_checknumber(L, 1);
  37. int arg1 = (int)LuaDLL.luaL_checknumber(L, 2);
  38. int arg2 = (int)LuaDLL.luaL_checknumber(L, 3);
  39. int arg3 = (int)LuaDLL.luaL_checknumber(L, 4);
  40. BuffParam obj = new BuffParam(arg0, arg1, arg2, arg3);
  41. ToLua.PushValue(L, obj);
  42. return 1;
  43. }
  44. else if (count == 5)
  45. {
  46. int arg0 = (int)LuaDLL.luaL_checknumber(L, 1);
  47. int arg1 = (int)LuaDLL.luaL_checknumber(L, 2);
  48. int arg2 = (int)LuaDLL.luaL_checknumber(L, 3);
  49. int arg3 = (int)LuaDLL.luaL_checknumber(L, 4);
  50. string arg4 = ToLua.CheckString(L, 5);
  51. BuffParam obj = new BuffParam(arg0, arg1, arg2, arg3, arg4);
  52. ToLua.PushValue(L, obj);
  53. return 1;
  54. }
  55. else if (count == 6)
  56. {
  57. int arg0 = (int)LuaDLL.luaL_checknumber(L, 1);
  58. int arg1 = (int)LuaDLL.luaL_checknumber(L, 2);
  59. int arg2 = (int)LuaDLL.luaL_checknumber(L, 3);
  60. int arg3 = (int)LuaDLL.luaL_checknumber(L, 4);
  61. int arg4 = (int)LuaDLL.luaL_checknumber(L, 5);
  62. string arg5 = ToLua.CheckString(L, 6);
  63. BuffParam obj = new BuffParam(arg0, arg1, arg2, arg3, arg4, arg5);
  64. ToLua.PushValue(L, obj);
  65. return 1;
  66. }
  67. else if (count == 0)
  68. {
  69. BuffParam obj = new BuffParam();
  70. ToLua.PushValue(L, obj);
  71. return 1;
  72. }
  73. else
  74. {
  75. return LuaDLL.luaL_throw(L, "invalid arguments to ctor method: BuffParam.New");
  76. }
  77. }
  78. catch (Exception e)
  79. {
  80. return LuaDLL.toluaL_exception(L, e);
  81. }
  82. }
  83. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  84. static int ToJson(IntPtr L)
  85. {
  86. try
  87. {
  88. ToLua.CheckArgsCount(L, 1);
  89. BuffParam obj = (BuffParam)ToLua.CheckObject(L, 1, typeof(BuffParam));
  90. JSONObject o = obj.ToJson();
  91. ToLua.PushObject(L, o);
  92. ToLua.SetBack(L, 1, obj);
  93. return 1;
  94. }
  95. catch (Exception e)
  96. {
  97. return LuaDLL.toluaL_exception(L, e);
  98. }
  99. }
  100. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  101. static int get_buffId(IntPtr L)
  102. {
  103. object o = null;
  104. try
  105. {
  106. o = ToLua.ToObject(L, 1);
  107. BuffParam obj = (BuffParam)o;
  108. int ret = obj.buffId;
  109. LuaDLL.lua_pushinteger(L, ret);
  110. return 1;
  111. }
  112. catch(Exception e)
  113. {
  114. return LuaDLL.toluaL_exception(L, e, o, "attempt to index buffId on a nil value");
  115. }
  116. }
  117. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  118. static int get_ratio(IntPtr L)
  119. {
  120. object o = null;
  121. try
  122. {
  123. o = ToLua.ToObject(L, 1);
  124. BuffParam obj = (BuffParam)o;
  125. int ret = obj.ratio;
  126. LuaDLL.lua_pushinteger(L, ret);
  127. return 1;
  128. }
  129. catch(Exception e)
  130. {
  131. return LuaDLL.toluaL_exception(L, e, o, "attempt to index ratio on a nil value");
  132. }
  133. }
  134. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  135. static int get_cd(IntPtr L)
  136. {
  137. object o = null;
  138. try
  139. {
  140. o = ToLua.ToObject(L, 1);
  141. BuffParam obj = (BuffParam)o;
  142. int ret = obj.cd;
  143. LuaDLL.lua_pushinteger(L, ret);
  144. return 1;
  145. }
  146. catch(Exception e)
  147. {
  148. return LuaDLL.toluaL_exception(L, e, o, "attempt to index cd on a nil value");
  149. }
  150. }
  151. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  152. static int get_type(IntPtr L)
  153. {
  154. object o = null;
  155. try
  156. {
  157. o = ToLua.ToObject(L, 1);
  158. BuffParam obj = (BuffParam)o;
  159. int ret = obj.type;
  160. LuaDLL.lua_pushinteger(L, ret);
  161. return 1;
  162. }
  163. catch(Exception e)
  164. {
  165. return LuaDLL.toluaL_exception(L, e, o, "attempt to index type on a nil value");
  166. }
  167. }
  168. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  169. static int get_casterType(IntPtr L)
  170. {
  171. object o = null;
  172. try
  173. {
  174. o = ToLua.ToObject(L, 1);
  175. BuffParam obj = (BuffParam)o;
  176. int ret = obj.casterType;
  177. LuaDLL.lua_pushinteger(L, ret);
  178. return 1;
  179. }
  180. catch(Exception e)
  181. {
  182. return LuaDLL.toluaL_exception(L, e, o, "attempt to index casterType on a nil value");
  183. }
  184. }
  185. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  186. static int get_extendPara(IntPtr L)
  187. {
  188. object o = null;
  189. try
  190. {
  191. o = ToLua.ToObject(L, 1);
  192. BuffParam obj = (BuffParam)o;
  193. int ret = obj.extendPara;
  194. LuaDLL.lua_pushinteger(L, ret);
  195. return 1;
  196. }
  197. catch(Exception e)
  198. {
  199. return LuaDLL.toluaL_exception(L, e, o, "attempt to index extendPara on a nil value");
  200. }
  201. }
  202. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  203. static int get_funStr(IntPtr L)
  204. {
  205. object o = null;
  206. try
  207. {
  208. o = ToLua.ToObject(L, 1);
  209. BuffParam obj = (BuffParam)o;
  210. string ret = obj.funStr;
  211. LuaDLL.lua_pushstring(L, ret);
  212. return 1;
  213. }
  214. catch(Exception e)
  215. {
  216. return LuaDLL.toluaL_exception(L, e, o, "attempt to index funStr on a nil value");
  217. }
  218. }
  219. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  220. static int set_buffId(IntPtr L)
  221. {
  222. object o = null;
  223. try
  224. {
  225. o = ToLua.ToObject(L, 1);
  226. BuffParam obj = (BuffParam)o;
  227. int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
  228. obj.buffId = arg0;
  229. ToLua.SetBack(L, 1, obj);
  230. return 0;
  231. }
  232. catch(Exception e)
  233. {
  234. return LuaDLL.toluaL_exception(L, e, o, "attempt to index buffId on a nil value");
  235. }
  236. }
  237. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  238. static int set_ratio(IntPtr L)
  239. {
  240. object o = null;
  241. try
  242. {
  243. o = ToLua.ToObject(L, 1);
  244. BuffParam obj = (BuffParam)o;
  245. int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
  246. obj.ratio = arg0;
  247. ToLua.SetBack(L, 1, obj);
  248. return 0;
  249. }
  250. catch(Exception e)
  251. {
  252. return LuaDLL.toluaL_exception(L, e, o, "attempt to index ratio on a nil value");
  253. }
  254. }
  255. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  256. static int set_cd(IntPtr L)
  257. {
  258. object o = null;
  259. try
  260. {
  261. o = ToLua.ToObject(L, 1);
  262. BuffParam obj = (BuffParam)o;
  263. int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
  264. obj.cd = arg0;
  265. ToLua.SetBack(L, 1, obj);
  266. return 0;
  267. }
  268. catch(Exception e)
  269. {
  270. return LuaDLL.toluaL_exception(L, e, o, "attempt to index cd on a nil value");
  271. }
  272. }
  273. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  274. static int set_type(IntPtr L)
  275. {
  276. object o = null;
  277. try
  278. {
  279. o = ToLua.ToObject(L, 1);
  280. BuffParam obj = (BuffParam)o;
  281. int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
  282. obj.type = arg0;
  283. ToLua.SetBack(L, 1, obj);
  284. return 0;
  285. }
  286. catch(Exception e)
  287. {
  288. return LuaDLL.toluaL_exception(L, e, o, "attempt to index type on a nil value");
  289. }
  290. }
  291. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  292. static int set_casterType(IntPtr L)
  293. {
  294. object o = null;
  295. try
  296. {
  297. o = ToLua.ToObject(L, 1);
  298. BuffParam obj = (BuffParam)o;
  299. int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
  300. obj.casterType = arg0;
  301. ToLua.SetBack(L, 1, obj);
  302. return 0;
  303. }
  304. catch(Exception e)
  305. {
  306. return LuaDLL.toluaL_exception(L, e, o, "attempt to index casterType on a nil value");
  307. }
  308. }
  309. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  310. static int set_extendPara(IntPtr L)
  311. {
  312. object o = null;
  313. try
  314. {
  315. o = ToLua.ToObject(L, 1);
  316. BuffParam obj = (BuffParam)o;
  317. int arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
  318. obj.extendPara = arg0;
  319. ToLua.SetBack(L, 1, obj);
  320. return 0;
  321. }
  322. catch(Exception e)
  323. {
  324. return LuaDLL.toluaL_exception(L, e, o, "attempt to index extendPara on a nil value");
  325. }
  326. }
  327. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  328. static int set_funStr(IntPtr L)
  329. {
  330. object o = null;
  331. try
  332. {
  333. o = ToLua.ToObject(L, 1);
  334. BuffParam obj = (BuffParam)o;
  335. string arg0 = ToLua.CheckString(L, 2);
  336. obj.funStr = arg0;
  337. ToLua.SetBack(L, 1, obj);
  338. return 0;
  339. }
  340. catch(Exception e)
  341. {
  342. return LuaDLL.toluaL_exception(L, e, o, "attempt to index funStr on a nil value");
  343. }
  344. }
  345. }