void OnTriggerEnter2D(Collider2D other) { if (gameObject.name == "ToSalon") { fader.LoadScene("CuisineSalonNuit"); } }
void OnTriggerEnter2D(Collider2D other) { if (gameObject.name == "ToBedroom") { fader.LoadScene("ChambreNuit"); } }
void OnTriggerEnter2D(Collider2D other) { switch (gameObject.name) { case "ToBedroom": fader.LoadScene("ChambreMatin"); break; case "ToWork": fader.LoadScene("CuisineSalonNuit"); SoundScript.FadeOut(); break; } }
void OnTriggerStay2D(Collider2D other) { if (Input.GetAxis("Vertical") > 0.5f) { fader.LoadScene("CuisineSalonNuit"); } }
void OnTriggerEnter2D(Collider2D other) { if (gameObject.name == "Chambre") { fader.LoadScene("CuisineSalonMatin"); } }
// Update is called once per frame void Update() { if (dialog.finished) { Debug.Log("Dialog finisehd"); fading.LoadScene("ChambreMatin"); } }
void OnTriggerStay2D(Collider2D other) { switch (gameObject.name) { case "ToSalon": if (Input.GetAxis("Vertical") > 0.5f) { fader.LoadScene("CuisineSalonMatin"); } break; case "AnimationCollider": if (Input.GetKeyDown(KeyCode.Return) && !animationLaunched) { StartCoroutine(LaunchAnimation()); } break; } }