UnityEngine_Camera_Binding.cs 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Reflection;
  5. using System.Runtime.InteropServices;
  6. using ILRuntime.CLR.TypeSystem;
  7. using ILRuntime.CLR.Method;
  8. using ILRuntime.Runtime.Enviorment;
  9. using ILRuntime.Runtime.Intepreter;
  10. using ILRuntime.Runtime.Stack;
  11. using ILRuntime.Reflection;
  12. using ILRuntime.CLR.Utils;
  13. namespace ILRuntime.Runtime.Generated
  14. {
  15. unsafe class UnityEngine_Camera_Binding
  16. {
  17. public static void Register(ILRuntime.Runtime.Enviorment.AppDomain app)
  18. {
  19. BindingFlags flag = BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly;
  20. MethodBase method;
  21. Type[] args;
  22. Type type = typeof(UnityEngine.Camera);
  23. args = new Type[]{};
  24. method = type.GetMethod("get_main", flag, null, args, null);
  25. app.RegisterCLRMethodRedirection(method, get_main_0);
  26. args = new Type[]{typeof(UnityEngine.Vector3)};
  27. method = type.GetMethod("ScreenPointToRay", flag, null, args, null);
  28. app.RegisterCLRMethodRedirection(method, ScreenPointToRay_1);
  29. }
  30. static StackObject* get_main_0(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
  31. {
  32. ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
  33. StackObject* __ret = ILIntepreter.Minus(__esp, 0);
  34. var result_of_this_method = UnityEngine.Camera.main;
  35. return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
  36. }
  37. static StackObject* ScreenPointToRay_1(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
  38. {
  39. ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
  40. StackObject* ptr_of_this_method;
  41. StackObject* __ret = ILIntepreter.Minus(__esp, 2);
  42. ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
  43. UnityEngine.Vector3 @pos = (UnityEngine.Vector3)typeof(UnityEngine.Vector3).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
  44. __intp.Free(ptr_of_this_method);
  45. ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
  46. UnityEngine.Camera instance_of_this_method = (UnityEngine.Camera)typeof(UnityEngine.Camera).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
  47. __intp.Free(ptr_of_this_method);
  48. var result_of_this_method = instance_of_this_method.ScreenPointToRay(@pos);
  49. return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
  50. }
  51. }
  52. }