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

How would I fix this problem with parts rising when hitting something?

2 answers

✓ Accepted answer

EDIT VERSION


local cframe=CFrame.new(0,0,0)

function expand(Part)
    for i = 1, 20 do
       cframe=Part.CFrame
        Part.Size = Part.Size + Vector3.new(0,0,4)
        Part.CFrame = cframe * CFrame.new(0,0,-2) --this line was edited
        wait()
    end
    for i = 20, 1, -1 do
	cframe=Part.CFrame
        Part.Size = Part.Size - Vector3.new(0,0, 4)
        Part.CFrame = cframe * CFrame.new(0,0,2)
        wait()
    end
    print("Part Done")
    Part:remove()
end

plasma that isn't how I made this. I will show you here (A snippet code)

function expand(Part)
	for i = 1, 20 do
		Part.Size = Part.Size + Vector3.new(0,0,4)
		Part.CFrame = Part.CFrame * CFrame.new(0,0,-2)
		wait()
	end
	for i = 20, 1, -1 do
		Part.Size = Part.Size - Vector3.new(0,0, 4)
		Part.CFrame = Part.CFrame * CFrame.new(0,0,2)
		wait()
	end
	print("Part Done")
	Part:remove()
end

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