Stun Handler V2.1

Looks fine, however, why don’t you save old JumpPower like WalkSpeed?

humanoid.WalkSpeed = placeInTable["speed"]
humanoid.JumpPower = 50

There are games that have different JumpPower set, not 50.
Other than that, it looks fine, maybe you could improve it by making sure the WalkSpeed/JumpPower don’t get changed while you are stunned with a Humanoid Changed connection (make sure to disconnect when stun duration is over)

4 Likes

Thanks for the feedback!
I was already contemplating on saving the JumpPower but thanks for the tip.

About the humanoid changed connection, I didn’t even notice that problem until you mentioned it. Thanks a lot for the advice!

I’ve added the changes; if you’re willing, please let me know if there’s any problems with what I’ve done, thanks.

Version 2 released!
Made a lot of improvements on performance

does this stun work for things like combo stuns. For example, when you hit someone with a sword combo, they can’t move or do anything until the combo is over or is interrupted.

Yes, you will need to specify how long you want the stun to last though.

2 Likes

How would i detect if a player is stunned in a local script?

An attribute is added to the humanoid’s parent (generally the character)
In your local script you can listen to its change

character:GetAttributeChangedSignal("Stunned"):Connect(function()
    print(character:GetAttribute("Stunned"))
end)
1 Like

Looks nice! This post is more than just a cool creation, you may put it in #resources:community-resources :eyes:

I like that you used attributes!

2 Likes

Thank you!

I was considering posting it in #resources:community-resources but I wasn’t sure if it’s worthy of being there. :sweat_smile:

1 Like

Can you make an option to turn the stun on or off without duration because some of us might need this feature and i’m one of them.

So basically, this feature will ignore any incoming stuns (including current stuns) when until it’s off, and that’s it.

How do you use it? i dont understand. is it any instructions ?

Well i just used it and edited it because the owner doesn’t seem to update it anymore, so if you know how then you should too

i understand how to stun the player and require but in the local scipt i want to stop doing m1s.

Really useful module! However since its a resource its better to put it in #resources:community-resources .

Hey could any one answer how to use it in local script if i wanna like disable the debounce in the local script when people gets stunned.

sometimes players get permanently stunned (i was testing with 3 of my friends and we kept fighting then after a while the moves started to permanently stun whoever was hit instead of stunning for the duration i put.)
edit: nvm it was because the server script was inside of the tool so it would be deleted before the stun would be removed from the other player

1 Like

When I disable the script while the humanoid is still stunned, it becomes permanently stunned. Any ways to fix this?

edit: nevermind i found a alternate way (i have no common sense)

Is there a way to pair the stun with animations?

You can adjust the animation speed to 0 by doing animation:AdjustSpeed(0)

Then you can resume the animation by doing animation:AdjustSpeed()

This is really useful, but is there a way to make it so you can toggle stun on and off with a function? Thanks!

1 Like