Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How i fix a numbervalue going to negative?

Hello There How i can fix a value going to negative just a script prevents the number going to negative value just to prevent to appear as minus in the leaderboard

2 answers

✓ Accepted answer

math.clamp()

1 comment

0

hey thanks for help but i fixed it :3

Finnaly Fixed it myself all i have to do is this

players = game.Workspace

while true do
		if players.Value.Value < 0 then
		players.Value.Value = 0
		end
		wait()
	end

This discussion is preserved as it was. New answers, comments, and votes are closed.