コード例 #1
0
    public void LerpLevel()
    {
        LerpPointsSmaller(lerpPlayerNumber, lerpManager);

        if (_inGameManager.lerpedAmount >= 1) // Finished lerping
        {
            FinishLerping();
        }

        playerManager.PlayersLookAtPoint(_inGameManager.levelCenter);
        playerManager.UpdatePlayerPositions();
        arqdutManager.UpdateArqdutPositions(LevelManager.innerPoints, _inGameManager.levelCenter);
        _inGameManager.DrawMesh(ChooseControls.playerStates.Count(i => i.Value != PlayerState.Deactivated) + Convert.ToByte(InGameManager.shouldLerpSmaller));

        InGameManager.shouldSetIndices = false;
    }
コード例 #2
0
    /// <summary>
    /// Calls all methods necessary for spawning the initial level
    /// </summary>
    public void SpawnLevel(int corners)
    {
        LevelManager.innerPoints = pointManager.SpawnInnerPoints(corners, _inGameManager.levelCenter);
        LevelManager.outerPoints = pointManager.SpawnOuterPoints(LevelManager.innerPoints);

        playerManager.SpawnPlayers(pointManager.radius, ChooseControls.playerStates.Where(o => o.Value != PlayerState.Deactivated).Select(i => i.Key).ToArray());

        playerManager.PlayersLookAtPoint(_inGameManager.levelCenter);
        meshManager.SetMaterials();
        arqdutManager.SpawnArqduts(LevelManager.innerPoints, _inGameManager.levelCenter);

        meshManager.SetVertices(MeshManager.ConcatV2ListsToV3(LevelManager.innerPoints, LevelManager.outerPoints));
        _inGameManager.DrawMesh(corners);

        if (ChooseControls.gameStarted)
        {
            _gameManager.StartCountdown(_inGameManager.levelCenter);
        }
    }