01 | local player = game.Players:GetPlayerFromCharacter(onClicked) |
02 | local hum = player.Humanoid |
03 |
04 | local anim = hum:LoadAnimation(player.Animate.laugh.LaughAnim) |
05 |
06 | function onClicked() |
07 |
08 |
09 | anim:Play() |
10 |
11 | wait( 2 ) |
12 |
13 |
14 | script.Parent.ClickDetector.MaxActivationDistance = 0 |
15 |
01 | script.Parent.ClickDetector.MouseClick:Connect( function (player) |
02 | local humanoid = player.Character.Humanoid |
03 | local anim = humanoid:LoadAnimation(player.Character.Animate.laugh.LaughAnim) |
04 | anim:Play() |
05 | cooldown() |
06 | end ) |
07 |
08 | function cooldown() |
09 | script.Parent.ClickDetector.MaxActivationDistance = 0 |
10 | wait( 60 ) |
11 | script.Parent.ClickDetector.MaxActivationDistance = 20 |
12 | end |
Make this in a normal script.
This may not work but here we go...
01 | wait( 10.5 ) |
02 | local player = game.Players:GetPlayerFromCharacter(onClicked) |
03 | local hum = player.Humanoid |
04 |
05 | local anim = hum:LoadAnimation(player.Animate.laugh.LaughAnim) |
06 |
07 | function onClicked() |
08 | anim:Play() |
09 | wait( 2 ) |
10 | end |
11 |
12 | script.Parent.ClickDetector.MouseClick:connect(onClicked) |
I removed your waits and other useless things because it made it not work, did not test this yet...