✓ Accepted answer
Well if the value is an IntValue type, you should do the following:
I don't know what is your goal with this,so you may clarify it so i can help you better.
game.Players.PlayerAdded:Connect(function(Player)
game.Workspace.Value.Value += 1
wait(3)
game.Workspace.Value.Value = tonumber(Player:WaitForChild("PlayerGui").ScreenGui.TextLabel.Text)
end)
game.Players.PlayerRemoving:Connect(function()
game.Workspace.Value.Value -= 1
end)
game.Workspace.Value.Value = tonumber(game..ScreenGui.TextLabel.Text)
If you want to change it , remember, you cant edit the startergui properties on the player,as it replicates to the player in a folder called PlayerGui.
Also the tonumber() function converts strings in numbers (Text property is a string type.) And WaitForChild waits for the child of a parent to load.
Hope it helps!
1 comment
Dont paste the last two line