public override void Execute(MysteryManager o, FSM <MysteryManager> fsm) { mixer = GameObject.FindObjectOfType <PlanetsMixer> (); if (Vector3.Distance(players[0].transform.position, players[1].transform.position) <= 5) { //Fin du Game Application.LoadLevel("Cinematic"); } }
public override void MysterySolved(MysteryManager o, FSM <MysteryManager> fsm, Mysteries id) { mixer = GameObject.FindObjectOfType <PlanetsMixer> (); if (id == Mysteries.Hello) { helloDone++; if (helloDone >= 2) { mixer.NewState(1); fsm.ChangeState(MysterySlabsState.Instance); MysterySlabsState.Instance.canBeDone = true; } } }
public override void MysterySolved(MysteryManager o, FSM <MysteryManager> fsm, Mysteries id) { if (!canBeDone) { return; } mixer = GameObject.FindObjectOfType <PlanetsMixer> (); if (id == Mysteries.Hello) { MasterMindDone++; if (MasterMindDone >= 2) { fsm.ChangeState(FinalState.Instance); } } }
public override void MysterySolved(MysteryManager o, FSM <MysteryManager> fsm, Mysteries id) { if (!canBeDone) { return; } mixer = GameObject.FindObjectOfType <PlanetsMixer> (); if (id == Mysteries.SlabSign) { slabsDone++; if (slabsDone >= 2) { mixer.NewState(1); fsm.ChangeState(MasterMindState.Instance); MasterMindState.Instance.canBeDone = true; } } }
void Start() { mixer = GameObject.FindObjectOfType <PlanetsMixer> (); }
void Start() { mixer = GameObject.FindObjectOfType <PlanetsMixer> (); players = GameObject.FindObjectsOfType <MovePlayer> (); }