Best way to make a spinning sweeper arm that affects non-anchored parts?


#1

I tried CFrame, which resulted in the sweeper arm clipping through the unanchored parts. I also tried BodyAngularVelocity and BodyPosition, but when a ball rolls into it, it knocks the arm back.


#2

You could try to use an AlignOrientation object with RigidityEnabled.


#3

Isn’t this for attachments only?


#4

You would put an attachment at the center of your part you wish to rotate, and the other one to wherever you want to align it to. You could then rotate it by simply rotating one of the attachments CFrame.

This would differ from directly rotating the beam’s CFrame because it would not ignore collision.


#5

I don’t think I understand what you mean. I tried to do as you said, but nothings happening.


#6

Take a look at this place.

Rotating Beam.rbxl (14.9 KB)

This isn’t necessarily the best method of achieving this, it was just an idea.


#7

HingeConstraints have a motor option. You can set torque very high so colliding objects don’t push the arm back.

The arm must be unachored as constraints require physics.

https://developer.roblox.com/api-reference/class/HingeConstraint