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

When you touch a part it gives you one point, but it’s only one time use?

Hey yall! I am trying to make it when you touch a part it adds a point, but when you touch it again it won’t. I have the leaderstats script already (the IntValue is called ‘Wins’). Thank you in advance

-JaisonDXYX

2 comments

0

I might try boolvalues! If that will work I will take this post down thank you advance!

0

You will want to change the answer to the same thing but the player.leaderstats.Wins to player.leaderstats.Wins += 1

1 answer

#try this

local part = put the part path here
_G.touched = false

part.Touched:Connect(function(hit)
	if not _G.touched and hit.Parent:FindFirstChild("Humanoid") then
		local player = game.Players:GetPlayerFromCharacter(hit.Parent)
		player.leaderstats.Wins = 1
	end
end)

if it still doesn't work then please dm me at

#Blue Duck#8344

2 comments

0

Mine is JDev#4583

0

No sadly =. :

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