I have a script that detects when you left click only while holding a specific tool but i need it to change the int value of a leader board stat every time you click
Here is my script so far
local Tool = script.Parent --make sure this is a Tool object
Tool.Equipped:connect(function(Mouse)
Mouse.Button1Down:connect(function()
end)
end)
Any help would be appreciated :P

7 comments
Ok well that definitely helps but i also need to make the function up the value by 1 for every click
Please use the Roblox API. If you did some research the IntValue object has a Value property to read/write to. http://wiki.roblox.com/index.php?title=API:Class/IntValue/Value
i found "intvalue" in it but it doesnt say anything about how to make a script change one
and i did some research and found that page already but i still dont understand how to change the vaule around
You can use the assignment operator.. after you scope to the property. experience.Value = experience.Value + 1
I'm sorry if I seem uneducated in the subject but it's because I'm very new to lua scripting and this is my first crack at it so if it isn't too much to ask could you try to give me a easier to understand explanation
nevermind i have it now thx for your help :P