for (var i=0; i<100; i++) { makePlanet();} this, the Browser without code editor works, but when i open code editor which saves the code already my Browser starts to freeze and after like 5 seconds it crashes(closes).
If you haven’t already, be sure to work through chapter 2. It’s got loads of information on dealing with problems. In this case, you’ll probably want to read about “edit-only” mode towards the end of the chapter.
The short version is that something in the code is causing the browser to freeze up. To fix the problem, you’ll have to go into edit-only mode, find the problem (or share it here), and fix it, before switching back to regular mode where the code is run.
Edit only mode can be entered with a special URL:
Just remove the ?e
and hit Enter
to get back to regular mode.
This kind of problem happens a lot – which is why edit-only mode was created in the first place. If you can’t find the problem, paste the code here and I’ll have a look.
-Chris