Press ESC to get back to main menu
This commit is contained in:
parent
f32ce4c982
commit
b13dbcb87b
@ -1,6 +1,7 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.SceneManagement;
|
||||
|
||||
public class PlayerController : Player
|
||||
{
|
||||
@ -53,7 +54,9 @@ public class PlayerController : Player
|
||||
isGrounded = Physics2D.OverlapArea(feetPos.position, checkRadius.position, whatIsGround); //return true for overlap
|
||||
moveInput = Input.GetAxis("Horizontal");
|
||||
|
||||
if (Input.GetKeyDown(KeyCode.Escape)) { Application.Quit(); } //temporary exit measure
|
||||
if (Input.GetKeyDown(KeyCode.Escape)) {
|
||||
SceneManager.LoadScene(0);
|
||||
}
|
||||
|
||||
|
||||
if(_isGrounded && Input.GetAxis("Horizontal") != -1 && Input.GetAxis("Horizontal") != 1) { Player.rbody.velocity = new Vector2(0, Player.rbody.velocity.y); }
|
||||
|
@ -98,7 +98,7 @@ PlayerSettings:
|
||||
visibleInBackground: 1
|
||||
allowFullscreenSwitch: 1
|
||||
graphicsJobMode: 0
|
||||
fullscreenMode: 3
|
||||
fullscreenMode: 1
|
||||
xboxSpeechDB: 0
|
||||
xboxEnableHeadOrientation: 0
|
||||
xboxEnableGuest: 0
|
||||
@ -121,7 +121,7 @@ PlayerSettings:
|
||||
m_SupportedAspectRatios:
|
||||
4:3: 0
|
||||
5:4: 0
|
||||
16:10: 1
|
||||
16:10: 0
|
||||
16:9: 1
|
||||
Others: 0
|
||||
bundleVersion: 0.1
|
||||
|
Loading…
Reference in New Issue
Block a user