- Home /
Can't add script behaviour while compiling ,Can't add script behavour while compling
Hi. I am creating my first game and this error appeared, I tried to debug the code but nothing happened , I am creating a game (my first) and I get this error .i tried to debug the code but nothing happened and the VS studio code is closed (Sorry for my english)
Answer by DawdleDev · Mar 10, 2019 at 04:37 PM
Your scripts are still compiling. That little loading symbol in the bottom right corner means that your script editor is still trying to compile your script. If you tried to attach this script to a game object, this error shows up. For whatever reason, it got stuck like that. Try recompiling. Open Visual Studio, add like a single space after one line, save, and switch back to Unity (preferably without closing Visual Studio this time). If this problem persists, restart Unity and Visual studio, then if that doesn't work, try copy-pasting the code into a new script and deleting the old one. Hope this helps!
Your answer
Follow this Question
Related Questions
OnTriggerEnter2D(Collider2D other) 2 Answers
Add audio. 1 Answer
Bombs as locomotion in 2D platformer 0 Answers
"Create New Palette" doesn't actually create a palette at all 1 Answer
Cinemachine camera shake on button press 0 Answers