- Home /
The question is answered, right answer was accepted
The namespace already contains a definition for ''
Hy! I am having a problem with definitions. I can rename a 100 times my script, it says that the namespace already contains a definition for 'Player_Standard' (this is my last try with renaming). When I get bored trying to give a name that is not occupied, I created a random namespace for my script, but it does not changed anything. Same problem appeared.
This picture shows the problem visually.
Firstly I did a research before posting here, but I have not got a result.
Answer by ErikAndroid · Nov 22, 2018 at 09:14 AM
The problem is solved by deleting the script and creating again. All the occupied names before become available.
This information helped me solve my problem. Thanks for saving me a lot of time! I had created a backup of my script file. The extra backup copy in the scripts folder was causing the definitions to be made twice. I deleted the extra copy and the error was resolved.
Assets\Scripts\Scripts2\$$anonymous$$ovementController.cs(4,14): error CS0101: The namespace '' already contains a definition for '$$anonymous$$ovementController'
In my case, I had 2 copies of the same script so, I deleted 1 of them.