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

Why i can't change the "explosion" value?

Asked by 6 years ago

Hi, my script don't work, it said

DestroyJointPercent is not a valid member of Part

My script is

script.Parent.ChildRemoved:connect(function(hit)
    a = Instance.new("Explosion")
    a.DestroyJointRadiusPercent = script.Parent.DestroyJointPercent.Value
    a.BlastPressure = script.Parent.BlastPressure.Value
    a.BlastRadius = script.Parent.BlastRadius.Value
    a.Position = script.Parent.Position
    a.Parent = workspace
    script.Parent.Parent:Destroy()
end)

Can someone help?

1 answer

Log in to vote
0
Answered by
Elixcore 1337 Moderation Voter
6 years ago
script.Parent.ChildRemoved:connect(function(hit)
    a = Instance.new("Explosion")
    a.DestroyJointRadiusPercent = script.Parent.DestroyJointRadiusPercent
    a.BlastPressure = script.Parent.BlastPressure
    a.BlastRadius = script.Parent.BlastRadius
    a.Position = script.Parent.Position
    a.Parent = workspace
    script.Parent.Parent:Destroy()
end)
Ad

Answer this question