SHADE_Y3/Assets/Scripts/UI/SC_EndScene.cs

42 lines
898 B
C#
Raw Normal View History

2022-11-23 00:44:27 +08:00
using System;
using SHADE;
public class EndScene : Script
{
public uint mainGameScene = 86098106;
public uint mainMainScene = 97158628;
protected override void awake()
{
}
protected override void update()
{
if (Input.GetKeyDown(Input.KeyCode.R))
2022-11-23 00:44:27 +08:00
{
Audio.PlaySFXOnce2D("event:/UI/mouse_down_element");
}
if (Input.GetKeyUp(Input.KeyCode.R))
{
Audio.PlaySFXOnce2D("event:/UI/success");
Audio.StopAllSounds();
2022-11-23 00:44:27 +08:00
SceneManager.ChangeScene(mainGameScene);
}
if (Input.GetKeyDown(Input.KeyCode.M))
2022-11-23 00:44:27 +08:00
{
Audio.PlaySFXOnce2D("event:/UI/mouse_down_element");
}
if (Input.GetKeyUp(Input.KeyCode.M))
{
Audio.PlaySFXOnce2D("event:/UI/success");
Audio.StopAllSounds();
2022-11-23 00:44:27 +08:00
SceneManager.ChangeScene(mainMainScene);
}
if (Input.GetKey(Input.KeyCode.Escape))
{
Application.Quit();
}
}
}