Ejemplo n.º 1
0
    protected virtual void InitializeScene()
    {
        PlayerState.Instance.LoadPlayerState();

        _objectSpawner.LoadObjectSpawner();
        if (_objectSpawner.TotalObjectsLeft == 0)
        {
            _objectSpawner.CreateManyWorldObjects();
        }
    }
    /// <summary>
    /// Try to load scene state from save files
    /// </summary>
    private void InitializeLevel()
    {
        if (_objectSpawner != null)
        {
            bool hasSave = _objectSpawner.LoadObjectSpawner();

            if (!hasSave)
            {
                _objectSpawner.CreateManyWorldObjects();
            }
        }
    }