Browse Source

Add escape button

master
excitedneon 3 years ago
parent
commit
9358374c27
2 changed files with 17 additions and 1 deletions
  1. +1
    -1
      Assets/Scripts/World.cs
  2. +16
    -0
      ProjectSettings/InputManager.asset

+ 1
- 1
Assets/Scripts/World.cs View File

@@ -170,7 +170,7 @@ namespace AIBotProblem {
if (currentLevel == 0 && Input.GetKeyUp("p")) {
Play();
}
if ((currentLevel == 0 || currentLevel == levels.Length - 1) && Input.GetKeyUp("q")) {
if (Input.GetButtonUp("Exit") || ((currentLevel == 0 || currentLevel == levels.Length - 1) && Input.GetKeyUp("q"))) {
Quit();
}
if (currentLevel == levels.Length - 1 && Input.GetKeyUp("m")) {


+ 16
- 0
ProjectSettings/InputManager.asset View File

@@ -53,6 +53,22 @@ InputManager:
type: 0
axis: 0
joyNum: 0
- serializedVersion: 3
m_Name: Exit
descriptiveName:
descriptiveNegativeName:
negativeButton:
positiveButton: escape
altNegativeButton:
altPositiveButton: q
gravity: 1000
dead: 0.001
sensitivity: 1000
snap: 0
invert: 0
type: 0
axis: 0
joyNum: 0
- serializedVersion: 3
m_Name: Horizontal
descriptiveName:


Loading…
Cancel
Save