Quantcast
Channel: Questions in topic: "exception"
Viewing all articles
Browse latest Browse all 470

KeyCode parse problem

$
0
0
Hi I am trying to make a small/basic input manager using c# but I am having a bit of a problem, here is where the problem is> if (Input.GetKey ((KeyCode)System.Enum.Parse(typeof(KeyCode), _controls[2]) ))> { ... } The _controls is a list of type string and currently in the [2] position I have "W". and this is the error that pops up > UnityException: Input Key named: W is unknown Can you please help me, thanks

Viewing all articles
Browse latest Browse all 470

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>