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

This is not working?

Asked by 8 years ago

Please make your question title relevant to your question content. It should be a one-sentence summary in question form.
local e = Instance.new("Explosion")
e.Parent = script.Parent.Parent.bullet.bulletPart
e.Position = Vector3.new(script.Parent.Parent.bullet.bulletPart.Position.X, script.Parent.Parent.bullet.bulletPart.Position.Y, script.Parent.Parent.bullet.bulletPart.Position.Z)
script.Parent.Parent.bullet.bulletPart:remove()

What is suppose to happen is a a different chunk of code(that was not included here) moves the bullet(with CFrame) a certain distance and then after that, this chunk of code then goes off. The bullet works fine and everything but the explosion is not going off. Why?

bullet is a model and bulletPart is the part inside the model.

0
Once again, are there any errors? Is the code supposed to fire when you hit something? If so, do you have a connection line? I just looked over your code again, the explosion might be deleting itself as it is getting to it's position since you remove bulletPart at the bottom of the script, which is the parent of the explosion. M39a9am3R 3210 — 8y

Answer this question