local cashmoney = game.ServerStorage.PlayerMoney:FindFirstChild(game.Players.LocalPlayer.Name)
script.Parent.MouseButton1Click:connect(function()
	if script.Parent.Parent.Input.Text == 'PROMOCODE' then
		cashmoney.Value = cashmoney.Value + 10000
		script.Parent.Parent.Input.Text = 'Code Redeemed!'
		wait(2)
		script.Parent.Parent.Input.Text = 'Enter Code Here'
	else
		script.Parent.Parent.Input.Text = 'Code Invalid'
		wait(2)
		script.Parent.Parent.Input.Text = 'Enter Code Here'
	end
	
end)

6 comments

0

I would suggest using a datastore, to make sure it's already entered

0

how would i do that?

0

I would look on how to do that on youtube or the wiki

0

I triedall they use is leaderstats

0

Try inserting a value into each player that joins such as Code1 and just set it's value to 1 if it's been used and save that to the datastore.

0

tysm