void Awake() { _battleSystem = GetComponent <BattleSystem>(); _battleQueue = GetComponent <BattleQueue>(); _battleCoordinator = GetComponent <BattleCoordinator>(); if (_battleSystem == null) { Debug.LogError("BattleSystem is missing!", gameObject); } if (_battleQueue == null) { Debug.LogError("BattleQueue is missing!", gameObject); } if (_battleCoordinator == null) { Debug.LogError("BattleCoordinator is missing!", gameObject); } if (_battleSystem != null) { _battleSystem.LogPosted += OnLogPosted; } _logs = new Queue <string>(); // Setup style _fontStyle = new GUIStyle(); _fontStyle.fontSize = 10; var normal = new GUIStyleState(); normal.textColor = Color.white; _fontStyle.normal = normal; }
public void Start(BattleCoordinator coordinator) { Coordinator = coordinator; OnStart(); }