Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

I need help with this falling moon, because I'm not sure what to do. Can I get help?

I want to change the velocity so it falls from the sky but not that fast. I have already tried to change things, but I don't understand how to do it. I need help, because I'm not very great at scripting. I would also like to know how to make a nuke explosion when it hits the ground.

1 answer

✓ Accepted answer
script.Parent.Anchored = false
script.Parent.CanCollide = true

if not script.Parent:FindFirstChildOfClass("BodyVelocity") then
	BodyVelocity = Instance.new("BodyVelocity",script.Parent)
	BodyVelocity.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
	BodyVelocity.Velocity = Vector3.new(0,-1,0)
end

script.Parent.Touched:Connect(function(Part)
	local Explosion = Instance.new("Explosion",workspace)
	
	Explosion.BlastRadius = 2000
	Explosion.BlastPressure = 2000
	Explosion.Position = script.Parent.Position
	Explosion.ExplosionType = Enum.ExplosionType.CratersAndDebris
	script.Parent:Destroy()
end)

2 comments

0

Thank you so much!

0

could you accept my answer? :3

This discussion is preserved as it was. New answers, comments, and votes are closed.