so im brand new to coding and unity but im trying to make a first person game so im follow brackeys tutorial on it but it doesnt work can i get some help
If you look in the bottom left of your unity window, the inspector tells you what the source of the problem is.
”expected ;” means that you’ve forgotten to add a semicolon at the end of a line. You can see which line is missing the semicolon as errors appear in the lines after it. (The red underlined words)
Add a semi colon to xRotation -= mouseY.
You also have a comma at the end of the next line instead of a semicolon. ; indicates the end of a line of code, which C# requires.
You also need to add another semicolon at the end of your transform.localRotation line.
Make those changes and it should be working just fine.
Be sure to reply if you need any more help, just @MrSlug
Answers
Hey @PandaMan,
If you look in the bottom left of your unity window, the inspector tells you what the source of the problem is.
”expected ;” means that you’ve forgotten to add a semicolon at the end of a line. You can see which line is missing the semicolon as errors appear in the lines after it. (The red underlined words)
Add a semi colon to xRotation -= mouseY.
You also have a comma at the end of the next line instead of a semicolon. ; indicates the end of a line of code, which C# requires.
You also need to add another semicolon at the end of your transform.localRotation line.
Make those changes and it should be working just fine.
Be sure to reply if you need any more help, just @MrSlug
Good luck!
Slug