Beispiel #1
0
    void PlayShutterSequence(Action onCloseCompleteCallback, bool closeInstantly = false)
    {
        const float INTERMISSION_DURATION = 0.2f;

        LimitControls();

        OverlayShuttersViewController svc = OverlayShuttersViewController.Instance;

        svc._isReadyToOpen_Predicate = IsReadyToOpen;
        svc.PlayCloseAndOpenSequence(onCloseCompleteCallback, RestoreControls, INTERMISSION_DURATION, closeInstantly);
    }
Beispiel #2
0
    bool IsReadyToOpen(OverlayShuttersViewController sender)
    {
        if (!WorldInfo.Instance.IsOverworld)
        {
            return(true);
        }

        OverworldChunkManager cm = OverworldTerrainEngine.ChunkManagerInstance as OverworldChunkManager;

        if (cm == null)
        {
            return(true);
        }
        return(cm.AreAllVoxelsDone);     // TODO: use correct param here (should signify when all chunks have loaded)
    }