Effect keeps rapid firing when it touches multiple parts


how would i fix this? and get it to only explode once

1 Like

If you want to wait for the tween to finish, you can simply just do

growTween.Completed:Wait()

because in your code, youโ€™re immediately resetting the debounce after you spawn the explosion.

1 Like

yeah but that doesnโ€™t really have anything to do with the effect rapid firing

1 Like

It does, because multiple touch events happen. When the first touch event goes through, it sets the debounce, runs the code, but at the same exact time, it resets the debounce, so when the next touch event comes through, it does the same exact thing.

3 Likes

Multiple hits are firing because their are multiple parts in the person. If you wanted to make it only happen once per person you could just make a table called HitPeople then when you first detect any part inside them just add their character model to the table, then check if the parent of any of the parts are inside that HitPeople table and if they are you do nothing

2 Likes

thanks it works both you and king bob

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.