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

Trying to make a Clap animation give +1 points each clap?

Hello, can anyone help me or like show me how to make a +1 points each time the character claps? I have already made an animation/well my friend did, but I don’t even know how to code it ,can anyone help I’m not a good scripter yet..

2 comments

0

What do you mean by giving +1 points. Are you using leaderstats? Are you using an IntValue? Please be specific.

0

I am using IntValue, Yes I am using leaderstats, I’m trying to do that there is a clap animation as a tool and when the tool is Activated and when they click the animation fires and then that makes them clap, when the player claps it adds 1 point which is called “Claps”, on the leaderboard could you help me with that?

1 answer

✓ Accepted answer

Put this script into a tool,

script.Parent.Activated:Connect(function()
CurrentPlayer = game.Players:GetPlayerFromCharacter(script.Parent.Parent)
CurrentPlayer.leaderstats.Claps.Value = CurrentPlayer.leaderstats.Claps.Value + 1
end)

5 comments

0

Does it have a Clap animation in that script?

0

Bro, we don't know your damn animation, do it yourself

1

Messed up my script a bit, I fixed it

1

So if you create a new script in your tool, when you click your leaderstat value of claps should go up. Tell me if any errors.

0

Thank you Gooncreeper, I really wish I could get a clap animation with plus one, but I love your hard work so I will upvote yours.

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