Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How would I make it so that if a part touches two humanoids/parts, then it gets destroyed?

Asked by 6 years ago

I'm trying to make a bullet destroy itself after it touches two things, thank you if you answered!

1 answer

Log in to vote
0
Answered by 6 years ago

Make a touched function in the bullet and make a variable that is equal to 0 before it. In the touches function, make the variable go up by one and then check if it is equal to two. If it is then destroy it. I also recommend using a debounce because it may add more than once without one.

Ad

Answer this question