static int __CreateInstance(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); if (LuaAPI.lua_gettop(L) == 1) { var gen_ret = new Vector2Binder(); 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 Vector2Binder constructor!")); }
private unsafe StackObject *Set_Position(ILIntepreter intp, StackObject *esp, IList <object> mStack, CLRMethod method, bool isnewobj) { ILRuntime.Runtime.Enviorment.AppDomain __domain = intp.AppDomain; var ret = ILIntepreter.Minus(esp, 2); var ptr = ILIntepreter.Minus(esp, 1); Vector2 @value = new Vector2(); Vector2Binder.ParseValue(ref @value, intp, ptr, mStack); ptr = ILIntepreter.Minus(esp, 2); UnityEngine.Rect instance_of_this_method; ParseRect(out instance_of_this_method, intp, ptr, mStack); instance_of_this_method.position = @value; WriteBackValue(__domain, ptr, mStack, ref instance_of_this_method); return(ret); }
private unsafe StackObject *Contains_Vector2(ILIntepreter intp, StackObject *esp, IList <object> mStack, CLRMethod method, bool isnewobj) { var ret = ILIntepreter.Minus(esp, 2); var ptr = ILIntepreter.Minus(esp, 1); Vector2 @point = new Vector2(); Vector2Binder.ParseVector2(out @point, intp, ptr, mStack); ptr = ILIntepreter.Minus(esp, 2); Rect mRect; ParseRect(out mRect, intp, ptr, mStack); var result = mRect.Contains(@point); ret->ObjectType = ObjectTypes.Integer; ret->Value = result ? 1 : 0; return(ret + 1); }
static int _m_RegisterCLRRedirection(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Vector2Binder gen_to_be_invoked = (Vector2Binder)translator.FastGetCSObj(L, 1); { ILRuntime.Runtime.Enviorment.AppDomain _appdomain = (ILRuntime.Runtime.Enviorment.AppDomain)translator.GetObject(L, 2, typeof(ILRuntime.Runtime.Enviorment.AppDomain)); gen_to_be_invoked.RegisterCLRRedirection(_appdomain); return(0); } } catch (System.Exception gen_e) { return(LuaAPI.luaL_error(L, "c# exception:" + gen_e)); } }