Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Why is testing a script in Roblox Studio different from testing a script in a Roblox Server?

I have always experienced this many times. When you test in studio, it doesn't error. Then, when I test in a server/game, it errors. Why does Roblox work like this?

  • saSlol2436

1 answer

According to my experience to this day, yes this is a right thing to say. But I usually had this while testing codes that includes things both Local and Server.

Roblox never encourages you to handle a job that has to do work in both Local and Server with one single script. You have to communicate between two. Server work needs to be done in ServerScript(Normal Script) and Local work needs to be done in LocalScript. Also basic calculations can be done in both so you can do calculations that does not require exploit security in LocalScript to improve performance in Server.

What you need to do? Local Test which you do with F5 or that play button at top still can be used but for this kind of work you need to play normally, or do local server tests(In Test tab, there is Local Server test). Best of luck. Please accept as answer if this is enough for you. If not, ask away in comment.

2 comments

0

Still, when I communicate with Server to Client and vice versa, it still doesn't work. Why is that?

0

Filtering Enabled? Not using RemoteEvents and RemoteFunctions? You say that.

This discussion is preserved as it was. New answers, comments, and votes are closed.