Hello, I could not find any answers to this specific error, if I do, I will remove this topic.
I am trying to make a script that puts the “Gameplay Paused” screen when the player first joins the game to let the assets load. The script is in the ServerScriptService and this is the error that I am getting:
Unable to assign property GameplayPaused. Script write access is restricted
This is the code as it currently is:
local player = game:GetService("Players")
game.Players.PlayerAdded:Connect(function(player)
wait(.5)
player.GameplayPaused = true
wait(3)
player.GameplayPaused = false
end)
I don’t know if the thing that I am trying to do is not allowed or if I am doing it wrong. Please reply if you know the answer.