diff --git a/Assets/Scripts/Core/GameManager.cs b/Assets/Scripts/Core/GameManager.cs index 67c64cf..8bf56a6 100644 --- a/Assets/Scripts/Core/GameManager.cs +++ b/Assets/Scripts/Core/GameManager.cs @@ -12,9 +12,8 @@ public class GameManager : MonoBehaviour public int Rows = 7, Cols = 7; public PlayerStatsService StatsService; - public bool dummyBots = false; + public int botsAmount = 5; - public DifficultyPreset MistressPreset; public int boardVersion = 1; diff --git a/Assets/Scripts/DifficultyManager.cs b/Assets/Scripts/DifficultyManager.cs index c8e6b8e..eea2486 100644 --- a/Assets/Scripts/DifficultyManager.cs +++ b/Assets/Scripts/DifficultyManager.cs @@ -31,7 +31,7 @@ public class DifficultyManager : MonoBehaviour public DifficultyPreset DifficultyPreset => CharacterController.CurrentCharacter.CurrentDifficultyPreset; public DifficultyPreset DummyPreset; - + public bool dummyBots = false; public void IncreaseDifficulty() { if (currentOpponent + 1 == CharacterController.CharactersAmount)//победили самую большую сложность diff --git a/Assets/Scripts/GameFSM/BotThinkingState.cs b/Assets/Scripts/GameFSM/BotThinkingState.cs index fa40ea2..11ecede 100644 --- a/Assets/Scripts/GameFSM/BotThinkingState.cs +++ b/Assets/Scripts/GameFSM/BotThinkingState.cs @@ -31,7 +31,7 @@ public class BotThinkingState : IState //Установка пресета сложности DifficultyPreset currentPreset = CharacterController.CurrentCharacter.CurrentDifficultyPreset; //Debug.Log(currentPreset.Description); - if (GameManager.instance.dummyBots) + if (DifficultyManager.Instance.dummyBots) currentPreset = DifficultyManager.Instance.DummyPreset; if (preset!= null) @@ -49,7 +49,7 @@ public class BotThinkingState : IState calcThread = new Thread(calc); calcThread.Start(); startTime = Time.time; - if (GameManager.instance.dummyBots) + if (DifficultyManager.Instance.dummyBots) timeToThink = 0; CharacterEventBus.Instance.OnBotTurn?.Invoke();