Quantcast
Channel: Questions in topic: "get"
Viewing all articles
Browse latest Browse all 215

Input.GetButton vs Input.GetKey

$
0
0
I'm working on a tps with the traditional wasd movement and correcting the character rotation according to its direction relative to the camera (by pressing w you see the character's back while pressing s shows the character facing the camera and so on). The problem is that, if I use Input.GetKey(KeyCode.A) for instance, it works but the key cannot be later changed in the input manager. On the other hand, Input.GetButton can be setup during the game but it doesn't work (it messes up the character rotation god knows why).

Viewing all articles
Browse latest Browse all 215

Trending Articles



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