源战役客户端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
1.1 KiB

  1. //this source code was auto-generated by tolua#, do not modify it
  2. using System;
  3. using LuaInterface;
  4. public class ViewWrap
  5. {
  6. public static void Register(LuaState L)
  7. {
  8. L.BeginClass(typeof(View), typeof(Base));
  9. L.RegFunction("OnMessage", OnMessage);
  10. L.RegFunction("__eq", op_Equality);
  11. L.RegFunction("__tostring", ToLua.op_ToString);
  12. L.EndClass();
  13. }
  14. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  15. static int OnMessage(IntPtr L)
  16. {
  17. try
  18. {
  19. ToLua.CheckArgsCount(L, 2);
  20. View obj = (View)ToLua.CheckObject(L, 1, typeof(View));
  21. IMessage arg0 = (IMessage)ToLua.CheckObject(L, 2, typeof(IMessage));
  22. obj.OnMessage(arg0);
  23. return 0;
  24. }
  25. catch(Exception e)
  26. {
  27. return LuaDLL.toluaL_exception(L, e);
  28. }
  29. }
  30. [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
  31. static int op_Equality(IntPtr L)
  32. {
  33. try
  34. {
  35. ToLua.CheckArgsCount(L, 2);
  36. UnityEngine.Object arg0 = (UnityEngine.Object)ToLua.ToObject(L, 1);
  37. UnityEngine.Object arg1 = (UnityEngine.Object)ToLua.ToObject(L, 2);
  38. bool o = arg0 == arg1;
  39. LuaDLL.lua_pushboolean(L, o);
  40. return 1;
  41. }
  42. catch(Exception e)
  43. {
  44. return LuaDLL.toluaL_exception(L, e);
  45. }
  46. }
  47. }