Пример #1
0
    void Update()
    {
        if (CurrentState != GameState.game)
        {
            return;
        }

        _distance = _player.transform.position.z - _startPos.z;

        _levelSpawner.OnDistanceChanged(_distance);
    }