Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why does my game crash (in Roblox Studio) whenever I try to play/test it?

Asked by 4 years ago

Hello! I hope this counts as a question.

I press F7 to playtest the game, and as usual, it'll open the "Server" tab and then the tab where you can be the player. Whenever I try to do that, the "Player1" tab always crashes. I looked around to see if any loops didn't include a "wait" in it, and every script that had a loop I found was either disabled (the script) or it had a wait in said loop. I playtested it the same way, and it still crashed. I waited to see if the game would give me a crash report, like telling me there's a forever looping script, but it didn't. It just crashes and nothing else happens.

I tried this with other games I have that are empty, and they work fine. No lag, no crashing. I also tried uninstalling Roblox Studio and reinstalling it several times and it never worked. Here are some of the articles I used: Article 1 Article 2 Article 3

None of those articles above worked for me. I did all the steps a few times, and still nothing. I looked through all of my plugins and disabled them. I am very clueless, idk what to do. Plz help!

0
Do you get an error? If yes, please post it. DogeIXX 172 — 4y
0
No errors. Chez_Guy 67 — 4y
0
Do you have a bad computer or a loop without wait running anywhere in your code(s)..? greatneil80 2647 — 4y
0
Did you import a bad model from toolbox? RealTinCan 217 — 4y

2 answers

Log in to vote
0
Answered by
Xapelize 2658 Moderation Voter Community Moderator
4 years ago

Restart your computer and open Roblox studio again. It might work for you :D

0
yes.. and it didnt Chez_Guy 67 — 4y
Ad
Log in to vote
0
Answered by 4 years ago

Hey @Chez_Guy!

I'll try to help you out.

When I started to script, I've always used loops as I've found them useful, BUT, I used them incorrectly causing the game to crash as one point (using too many loops to constantly update things).

So here's a list of steps you should do:

  1. Take a look at all of your loops

Make sure you are using the loops only when necessary, are you using loops to check for updates on IntValues or StringValue? Well if so I suggest adding a listener / event to listen for change in the value using either :GetPropertySignalChange or .Changed (Idk if the first one is in the right order)

  1. Go over your models, scripts

Sometimes there may be a infection / virus in your game. This is most common from plugins or free models that have scripts that just duplicate and spam the workspace causing the game to crash since it can't handle it. Recall if you have any free models and make sure to remove them if you have so

  1. Improve code quality

Most likely if you look at your code, there are always ways to improve either in the process or using algorithms to simplify code. Organise your code so you can edit it with ease.

  1. Contact Roblox

If this is a bug of Studio, chances are none of us will be able to answer this question. Your best option would be to Contact Roblox themselves since we aren't the developers of Roblox.

Hopefully this helped! Best of luck!

Answer this question