Exemplo n.º 1
0
    static int OnWaypointChange(IntPtr L)
    {
        try
        {
            ToLua.CheckArgsCount(L, 2);
            ToLua_DG_Tweening_Tween         obj  = (ToLua_DG_Tweening_Tween)ToLua.CheckObject(L, 1, typeof(ToLua_DG_Tweening_Tween));
            DG.Tweening.TweenCallback <int> arg0 = null;
            LuaTypes funcType2 = LuaDLL.lua_type(L, 2);

            if (funcType2 != LuaTypes.LUA_TFUNCTION)
            {
                arg0 = (DG.Tweening.TweenCallback <int>)ToLua.CheckObject(L, 2, typeof(DG.Tweening.TweenCallback <int>));
            }
            else
            {
                LuaFunction func = ToLua.ToLuaFunction(L, 2);
                arg0 = DelegateFactory.CreateDelegate(typeof(DG.Tweening.TweenCallback <int>), func) as DG.Tweening.TweenCallback <int>;
            }

            DG.Tweening.Tween o = obj.OnWaypointChange(arg0);
            ToLua.PushObject(L, o);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }