- Home /
All compiler errors have to be fixed before you can enter playmode?
I am designing an FPS on Unity using a tutorial that I downloaded on the Unity website, and the tutorial tells me to hit "play" after placing the First person Controller and deleting the main camera. It says that I should be able to move around the map with the WASD keys. I did everything the tutorial told me to do, but for some reason when I hit "play", it says "All compiler errors have to be fixed before you can enter play mode!". I have no idea what to do about this and I NEED HELP.
Answer by DaveA · Sep 01, 2012 at 01:35 AM
It's too bad that Unity does not update their tutorials. They worked ok in the version they were released for.
So what happened is Unity put stricter coding standards into the compiler so it complains about things more. Basically to prevent sloppy coding. What you are finding is evidence of that.
That said, unless you can get a copy of a fixed project, you'll need to fix these problems. Look at it as a learning opportunity. You will get your feet wet with coding quicker.
So yes, you have to look at the console to see what the errors are. Double-click one, it should open the text editor right to the offending line. They use the error message as a clue. Does it say 'protected or private member inaccessible due to permissions' or something like that? That means you need to find the component (script) that declares that variable or function, and add 'public' or remove 'private' from it.
Google is your best friend here. We've all done this: copy from the console, paste into google, hit search. I don't think I've ever come up empty that way.
i believe these so called unity tutorials aren't actually tutorials, but rather a walkthrough demo to show of unity's features of the current release. a bit like the demo's i saw from the unite presentation online which will probably come with unity 4. (only missed unite cos my kid was born today yaay)
Answer by ramonfr · Sep 01, 2012 at 01:33 AM
It simply means that there's an error in the script, so you need to fix it before running the game.
Isn't there any other error message above this one? If yes, click over it and Unity will take you exactly to the line where the error occurs in the script.
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Need help with a shop script.. :/ 1 Answer
Keep getting BCE0017 error 1 Answer
Help with Ragdoll 2 Answers
Object doen't move even though i did according lesson 1 Answer