// Use this for initialization void Start() { CSM = GameObject.Find("BattleManager").GetComponent <CombatStateMachine>(); enemy = CSM.selectedEnemy; swordAttack = Instantiate(swordAttack, enemy.gameObject.transform.position, swordAttack.transform.rotation); CSM.graphicPanel.SetActive(true); }
public void PressEndTurnButton() { CombatStateMachine c = Main.instance.GetCombatStateMachine(); if (c.IsPlayerTurn() == true) { Main.instance.PlayerEndTurn(); } }
// Use this for initialization void Start() { CSM = GameObject.Find("BattleManager").GetComponent <CombatStateMachine>(); CSM.graphicPanel.GetComponent <Animator>().SetInteger("graphic", 4); totalRotation = 0; audioRef = GameObject.Find("AudioManager").GetComponent <AudioBehavior>(); target.Rotate(Vector3.forward * Random.Range(0, 7) * 22.5f); primed = false; waitTime = 0; currentState = State.ACTIVE; }
private void Init() { string configPath = Application.dataPath + "/Resources/Configs"; ConfigHandler.LoadConfigs(configPath); instance = this; mainUIController.Init(); player = LoadOrCreatePlayer(); combatStateMachine = new CombatStateMachine(); combatStateMachine.Init(); timelineScriptController = MainUIController.instance.GetTimelineController().GetComponent <TimelineScriptController>(); }
void Start() { combatStateMachine = GetComponent <CombatStateMachine>(); currentState = States.MAP; }
void Awake() { playerParty = new List<basePlayer>(); enemyParty = new List<baseEnemy>(); csm = GetComponent<CombatStateMachine>(); }
// Use this for initialization void Start() { audioRef = GameObject.Find("AudioManager").GetComponent <AudioBehavior>(); CSM = GameObject.Find("BattleManager").GetComponent <CombatStateMachine>(); currentState = states.BEGIN; }
// Use this for initialization void Start() { CSM = GameObject.Find("BattleManager").GetComponent <CombatStateMachine>(); }