//----------Squad--------- private void ConfigureSquadLeader() { currentStatemachine = new SquadApproach(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "lead "; }
//--------------attacks-------------- private void ConfigureAttack() { if (AIType == EnemyType.Defender) { currentStatemachine = new DeffensiveAssault(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "passive "; } else if (AIType == EnemyType.Pusher) { currentStatemachine = new OffensiveAssault(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "pusher "; } else if (AIType == EnemyType.Simple) { currentStatemachine = new SimpleAttack(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "simple "; } else { currentStatemachine = new FlankAssault(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "flank "; } }
//--------Flank--------- void ConfigureBlitzFlank() { currentStatemachine = new BlitzFlank(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "Flank "; }
private void ConfigureCautiousAttack() { currentStatemachine = new DefensiveAttack(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "catious attack "; }
private void ConfigureBackCover() { Blackboard.targetBuffer[0] = Blackboard.squadLeader; hasLeader = true; currentStatemachine = new CoverTrail(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "cover back"; }
private void ConfigureFrontCover() { Blackboard.targetBuffer[0] = Blackboard.squadLeader; hasLeader = true; currentStatemachine = new CoverFollow(); currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "cover front"; }
//---------PATROL------ void ConfigurePatrol() { if (Random.Range(0, 10) > 5) { currentStatemachine = new Patrol(); } else { currentStatemachine = new LookAroundAttack(); } currentStatemachine.Init(this); currentStatemachine.StartStatemachine(); statemachine = "patrol"; }