Make a part fall slowly until it touches another part

I tried this before I made the post, it doesn’t work for some reason

Please try the snippet I just edited in my previous reply.
also wait(0.006) is not possible the limit is 0.03 seconds.

I’m trying it now, I’ll tell you how it goes

It doesn’t work. It still just passes straight through the part

Then something is wrong with your part. Screenshot properties?

Does a touchinterest appear in the part?

@FloofyNezzled if your current script still doesn’t work, then you can refer to this user’s suggestions.

Yep, I just checked. There’s a touchinterest

But shouldn’t anchored parts still detect collisions? I tried using physics already and I don’t know how to raycast.

Debug.

local __ONGROUND = false
coroutine.wrap(function()
repeat
		task.wait()
		newDrop.Position -= Vector3.new(0, 0.1, 0)
until __ONGROUND == true
end)()
newDrop.Touched:Connect(function(hit)
    print(hit.Name)
    print(hit.Parent.Name)
    print("HIT NO IF STATEMNT")
     if hit.Parent.Parent == workspace.Plates.Active then
              print("HIT IF STATEMNT")
          __ONGROUND = true
     end
end)

Try using this snippet and tell me if both prints.

My current code looks something like this:
image

image

script.Parent.Touched:Connect(function(hit)
	if hit.Parent.Parent == workspace.Plates.Active then
		print("touched")
	end
end)

My part is unanchored and all the necessary properties to detect collisions are enabled.

1 Like

They don’t. You can use GetTouchingParts though:

  • Every time you move the part, call GetTouchingParts to get the parts touching the falling part. If any of the touching parts are the ground part, call break to stop the loop.
1 Like

Expect GetTouchingParts() Does not work with parts with CanCollide off! This is obvious!
The properties of the part DOES NOT matter, what matters is CanTouch only!

Ah yeah, I forgot.

You need to create a touched connection (it won’t do anything besides allow GetTouchingParts to work) in addition to the loop.

My solution is probably the easiest among all (not sounding too conceited), so you should consider using this. @FloofyNezzled

1 Like

I tried, it doesn’t work. The VectorForce doesn’t move anything. Does the part have to be unanchored for the force to work?

That is the reason why it is classified as a physics constraint…

So yes, you must unanchor the part, and use the formula I have given so that it applies just enough force onto the part to make it slow fall.

yeah, it didn’t print anything, which is weird. It printed parts it touched when I tested my code earlier, but only touched some parts and not others.

Probably could only touch unanchored parts.

If parts aren’t physically simulated, they can’t “touch”. If your part is anchored, it’s not physically simulated. This means it can only touch parts that are physically simulated.

tl;dr:
Anchored parts can only touch unanchored parts. Unanchored parts can touch all parts.