From d7ecb9257c10e4459e86af35d3b1d0d94f720208 Mon Sep 17 00:00:00 2001 From: Gregory Campbell Date: Mon, 30 Sep 2019 21:17:47 -0400 Subject: [PATCH 1/2] Initial push. Implemented githubs recommnded unity gitignore file --- .gitignore | 96 +++++++++++++++++++++++++++++++----------------------- 1 file changed, 55 insertions(+), 41 deletions(-) diff --git a/.gitignore b/.gitignore index b08fea0..0a046de 100644 --- a/.gitignore +++ b/.gitignore @@ -1,45 +1,59 @@ -# =============== # -# Unity generated # -# =============== # -[Tt]emp/ -[Oo]bj/ -[Bb]uild -/[Bb]uilds/ +# This .gitignore file should be placed at the root of your Unity project directory +# +# Get latest from https://github.com/github/gitignore/blob/master/Unity.gitignore +# /[Ll]ibrary/ +/[Tt]emp/ +/[Oo]bj/ +/[Bb]uild/ +/[Bb]uilds/ +/[Ll]ogs/ +/[Mm]emoryCaptures/ + +# Never ignore Asset meta data +!/[Aa]ssets/**/*.meta + +# Uncomment this line if you wish to ignore the asset store tools plugin +# /[Aa]ssets/AssetStoreTools* + +# Autogenerated Jetbrains Rider plugin +[Aa]ssets/Plugins/Editor/JetBrains* + +# Visual Studio cache directory +.vs/ + +# Gradle cache directory +.gradle/ + +# Autogenerated VS/MD/Consulo solution and project files +ExportedObj/ +.consulo/ +*.csproj +*.unityproj +*.sln +*.suo +*.tmp +*.user +*.userprefs +*.pidb +*.booproj +*.svd +*.pdb +*.mdb +*.opendb +*.VC.db + +# Unity3D generated meta files +*.pidb.meta +*.pdb.meta +*.mdb.meta + +# Unity3D generated file on crash reports sysinfo.txt -*.stackdump -/Assets/AssetStoreTools* + +# Builds *.apk *.unitypackage - -# ===================================== # -# Visual Studio / MonoDevelop generated # -# ===================================== # -[Ee]xported[Oo]bj/ -.vs/ -/*.userprefs -/*.csproj -/*.pidb -*.pidb.meta -/*.suo -/*.sln* -/*.user -/*.unityproj -/*.booproj -.consulo/ -/*.tmp -/*.svd - -# ============ # -# OS generated # -# ============ # -.DS_Store* -._* -.Spotlight-V100 -.Trashes -Icon? -ehthumbs.db -[Tt]humbs.db -[Dd]esktop.ini -Corridor/Library/ShaderCache/ -Corridor/Library/metadata/ + +# Crashlytics generated file +crashlytics-build.properties From 5ceef5963f2bf498e288a079d352be2a1c8322f5 Mon Sep 17 00:00:00 2001 From: Gregory Campbell Date: Mon, 30 Sep 2019 21:25:33 -0400 Subject: [PATCH 2/2] Revert "Initial push. Implemented basic walk button" --- Assets/Scripts/PlayerController.cs | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/Assets/Scripts/PlayerController.cs b/Assets/Scripts/PlayerController.cs index 7b48c1c..d183f21 100644 --- a/Assets/Scripts/PlayerController.cs +++ b/Assets/Scripts/PlayerController.cs @@ -16,13 +16,11 @@ public class PlayerController : MonoBehaviour public float gravity = 5.0f; private bool extraJump = true; - private float tempSpeed; private Vector3 moveDirection; void Start() { characterController = GetComponent(); - tempSpeed = speed; } void Update() @@ -34,7 +32,8 @@ public class PlayerController : MonoBehaviour if (extraJump == true) { moveDirection = moveDirection.normalized * speed; //Remove this line to make running diagonal the fastest standard run - } else { + } else + { moveDirection = (moveDirection.normalized * speed)/4; //Remove this line to make running diagonal the fastest standard run } @@ -45,15 +44,6 @@ public class PlayerController : MonoBehaviour extraJump = true; moveDirection.y = 0.0f; - if(Input.GetKey(KeyCode.LeftShift)) - { - moveDirection = (moveDirection.normalized * speed/2); - tempSpeed = speed/2; - } else { - moveDirection = moveDirection.normalized * speed; - tempSpeed = speed; - } - if (Input.GetButtonDown("Jump")) { moveDirection.y = jumpSpeed;