When you press Play, studio will not use latest code

I’m editing a script and immidiately press play.
I don’t wait 4 seconds and close all modules before pressing play. I just press Play.

Then an error refering to the very code I just rewrote appears.
I have to press Stop then Play again. And NOW it loads using my most recent code.

  • This happens frequently for me as I have poor internet connection.
  • I’m not using any plugins or remote access stuff. Just pure roblox studio.

Let me know if I should include more information!

4 Likes

perhaps its due to both your poor connection and team create? Team create is defaulted on in published games, and when i forget to turn it off i have to “wait for script changes to apply”

1 Like

I do have teamcreate on.

It’s still a bug that it’s not waiting for my code to be updated before starting the play session though.

the problem could be that because of your poor connection, roblox tries to autosave or save it but fails, and also just how team create works.

I have had this issue too. I se i misspelled something in code while playtesting. Stop, fix it, and quickly press play. once I joined, I noticed the same error pops up. What? I thought I just fixed it?? I then hit Stop, look back at code, and see that it is indeed fixed. I then, once again play, and everything works fine, despite me changing nothing since the previous playtest. I do notice that If you wait 1-2 seconds after editing the code, it will work as expected, but I shouldn’t have to.

1 Like

Thanks for the report! We’ll follow up when we have an update for you.

Hello! We have a hypothesis of how this is happening and are working on a fix. How large is the script in question here in terms of character count?

different modules but around 700 lines usually. 17k chars.

Hello, we’ve released a mitigation which should reduce the impact of this issue. In Live Scripting mode, we will now patch the contents of any open script editors into the play DataModels so your local code changes should always make it in, even in very poor network conditions.

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.