This is a server script in the character. It used to have an error at the beginning, then when the character respawns theres no error. After today’s roblox studio update it says rendering paused for debugging and shows “Exception Hit”. The same thing happened when I put a task.wait(1) in front of it.
The “plr” variable is nil. That’s the cause in simple term, if you wanna find out why its nil then it’s probably the way you are identifying the player is wrong, double check through printing etc
for you to fix this, i suggest you print the char and ensure its actually a player character, you couldve indexed the wrong path for the player character
Your script is likely running before the Player’s .Character property is being set to the character model, I suggest using the Player.CharacterAdded or Player.CharacterAppearanceLoaded events (depending on your needs) in one setup script in a container service like ServerScriptService, rather than have it be copied to every character.
I think roblox studio is bugged after the new update. I added print(char.Name) & print(plr.Name) but when testing roblox studio went to the same error, temporarily showed those two lines of code & quickly changed it to before those two lines were added.
I closed roblox studio & opened it again to screen record it & it did it with temporarily showing 1 empty line
dude…
People already told you the reason and you can’t dismiss them that simply when they are infact correct.
First of all the way you get player is even by itself not guaranteed by the function if you were to spend at least 1 second reading it.
Try adding like delay for 1 hearbeat of some hacky stuff like:
Personally harassing me wasn’t necessary.
You chose to interpret what I said as “toxic,” but all I did was state the truth.
If you’d rather I sugarcoat it, that would mean I’m technically lying - which I’m not going to do.