Experimental Mode is a place setting used to indicate that a game is in an experimental phase. In this mode, the game server is not authoritative of changes, meaning that LocalScripts on clients can take any arbitrary actions they like. This can be useful when experimenting or prototyping a game, but is ultimately unstable and insecure. If a game is in Experimental Mode, it is vulnerable to exploiters who can cheat, insert inappropriate content, and generally disrupt the experience for other players. It is highly recommended to disable Experimental Mode before opening a game to the public. This article will cover how to disable Experimental Mode and what implications that has for development.
This feature was once managed by a Workspace property called FilteringEnabled. The same underlying mechanics are used between FilteringEnabled and games with Experimental Mode off.
Turning Experimental Mode off
Experimental Mode can only be toggled on or off in Studio.
- Select the HOME tab.
- Toward the right end of the toolbar, click the Game Settings button.
- In the window, select the Security tab. Under Experimental Mode, click the Off button.
- Close the Game Settings window.
Once you've updated the setting; publish the game, make it public, and start a new game from the Roblox platform. After you've started a new server, you'll see the game has changed from Experimental Mode to not in Experimental Mode.
Experimental Mode and Client-Server Model
In order to understand Experimental Mode it is important to first understand the Roblox network model. Roblox uses what is called client-server architecture. This is a structure where player devices (called clients) are all connected to a Roblox computer (called the server). The server makes sure that every client gets a copy of the game world when the client connects to the server. It also sends regular messages to the clients to let them know when anything changes in the world. This makes it so all players stay in sync and see the same game state as everyone else.
For example, suppose there is a Script in the game that changes the time of day to midnight. Scripts run on the server, so the first place that would see a change would be the server itself. It would update the time of day in its copy of the world, and then will automatically send a message to all of the connected clients that they need to change their time too. Once each client receives that message, they will update their time of day accordingly. Again, the server informing clients that the game has changed happens automatically; this is not something a developer explicitly has to do.
Clients can also communicate messages to the server in this architecture. This is most commonly used to relay player input as the server has no way of knowing when a player pressed a key or pushed a button. But this is where things get dangerous with Experimental Mode on.
With Experimental Mode on, changes made by a client will replicate to other clients automatically. Going back to the example above, suppose a LocalScript on one client changed the time of day. First, it would change the time of day on the client that ran the Local Script, and then it would send a message to the Server about this change automatically. The server would update its time of day, and then tell all the other clients that they need to change as well.
For most users of Roblox, the above case is not a problem. But there are ways that malicious users can inject code into their client to make changes. This can be used to cheat, corrupt data, or show inappropriate content which may result in moderation action being taken against the game itself. Filtering Enabled addresses this cleanly and simply. When Experimental Mode is off, the server will ignore updates from the clients (with a few exceptions). If a client changes properties, inserts parts, or destroys instances, the server will disregard these changes. The player who made these changes will still see them, but no other players will.
Testing Experimental Mode
Testing games is critical to development, especially when testing to make sure a game works with Experimental Mode turned off. Play and Play Here work well for general testing purpose, but these modes only simulate Experimental Mode on. This is because these modes treat that session of Studio as both a client and the server and will be allowed to do everything that clients and servers can do.
To test with Experimental Mode specifically in mind, it is recommended to test with Start Server/Player from the Test tab. This will launch multiple sessions of Studio, one for the server and one for each client.
In this situation the place's Experimental Mode setting will be respected. If it is on, then the launched client sessions will not be able to change the game for the server or other clients.
If a place has Team Create enabled, then Team Test can also be used to test Filtering Enabled. In this mode other developer should also be in the Team Test session to check on the state of the game.