|
| 06 Jul 2017 09:07 PM |
I've created a few different bits of code that work perfectly in the Roblox Studio Play Mode, but don't work at all when I start up an actual server. In particular, the AncestryChanged event on a script inside a BodyVelocity fires off while I'm in Studio Play, but it doesn't work on a server.
I'm just curious what the differences are between Studio Play and an actual server, and why the code works in one and not the other. Thanks! |
|
|
| Report Abuse |
|
|
jmt99
|
  |
| Joined: 27 Jul 2008 |
| Total Posts: 4799 |
|
|
| 06 Jul 2017 10:07 PM |
To answer the question "what the differences are between Studio Play and an actual server":
When in Studio Play, the client itself is considered the server since there is only 1 game instance and not a game instance of the server and a game instance of the client. This means the client can access things that it normally couldn't like server-only objects.
When in an actual server, the client is separate from the server and cannot access server-only objects.
If you do a Studio Server Play you can see this. Go to the "Test" tab and go to the "Clients and Servers" section and select "Local Server" from the dropdown and select 1 player and click Start. It should open 2 additional instances of ROBLOX Studio, one is the server and one is the client.
|
|
|
| Report Abuse |
|
|
|
| 06 Jul 2017 10:14 PM |
| Accessing server sided things with local scripts will work in studio play mode, but not online |
|
|
| Report Abuse |
|
|