I need a code that would detect if the player is in studio mode or game mode. Is this possible, if so how would I do it?
✓ ANSWER ACCEPTED
How to let a script detect game mode?
2 answers
✓ Accepted answer
I have not tested this, but I believe that you would try to see if something called Player1 is in Players. Since Player1 is who you test with, if Player1 would not be in Players, then this game is not being tested in studio and this game is therefore being run online.
It should sort of look like this:
if game.Players:FindFirstChild("Player1") then
--Game is being tested in studio
else
--Game is being run online
end
I believe it is only possibal by plugin
This discussion is preserved as it was. New answers, comments, and votes are closed.
