Hi,
I want to make a FPS game. So I looked on the web and found a tutorial. My game looked the same and the coding, but the coding doesn’t work! I use Editor 2021.3.1f1. Please let me know what to do.
their coding
My coding
Hi,
I want to make a FPS game. So I looked on the web and found a tutorial. My game looked the same and the coding, but the coding doesn’t work! I use Editor 2021.3.1f1. Please let me know what to do.
their coding
Make sure visual studio is linked in preferences - 3rd party tools
Your problem would be how you declare the first variable in your class: PlayerInput. You only typed in the class name, but not the variable name. Once you do that you should update al other playerInput references in your code (PlayerInput vs playerInput).
Also, whenever you have any problem in your code you should take a look at the Console pane in Unity, it will give you error messages that will help you locate your coding errors.