Esempio n. 1
0
 private static void OnCompleted()
 {
     if (hotUpdateClass != null)
     {
         if (hotUpdateObject != null)
         {
             hotUpdateClass.Call("OnDestroy", hotUpdateObject);
             hotUpdateObject.Dispose();
             hotUpdateObject = null;
         }
         hotUpdateClass.Dispose();
         hotUpdateClass = null;
         GameObject.DestroyImmediate(LuaClient.Instance.gameObject);
         LuaFacade.Initialize();
     }
     LuaFacade.SendNotification("StartUp");
 }
Esempio n. 2
0
    static int SendNotification(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 1)
            {
                string arg0 = ToLua.CheckString(L, 1);
                LuaFacade.SendNotification(arg0);
                return(0);
            }
            else if (count == 2)
            {
                string   arg0 = ToLua.CheckString(L, 1);
                LuaTable arg1 = ToLua.CheckLuaTable(L, 2);
                LuaFacade.SendNotification(arg0, arg1);
                return(0);
            }
            else if (count == 3)
            {
                string   arg0 = ToLua.CheckString(L, 1);
                LuaTable arg1 = ToLua.CheckLuaTable(L, 2);
                string   arg2 = ToLua.CheckString(L, 3);
                LuaFacade.SendNotification(arg0, arg1, arg2);
                return(0);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to method: LuaFacade.SendNotification"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }