protected override void InitialiseBrain() { brain = new StateMachine.FSM(this); var patrol = new Patrol(); var dying = new Dying(CorpseAppearance); var dead = new Dead(); patrol.AddTransition(dying, () => { return(!IsAlive); }); dying.AddTransition(dead, () => { return(dying.HitGround); }); brain.AddState(patrol); brain.AddState(dying); brain.AddState(dead); brain.Initialise("Patrol"); }