Animation not colliding with parts

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve?
    A sweep using Animations (Humanoid) that pushes the pins fully off the deck. I have most of it done, just the fact it doesn’t push the pins is the current issue at hand.
    Here’s the current setup:

  2. What is the issue?
    The pins don’t get hit by the sweep. Video:

  3. What solutions have you tried so far?
    I’ve tried welding seperate bricks to the sweep to push the pins, (red block included in the video, didn’t work). I’ve thought about using BodyPosition to move the sweep but that wouldn’t look as good or be as easily modifiable. I’ve tried using TweenService but that pretty much does not push the pins at all.

Any help at all is much appreciated, feel free to contact me here or via discord: lukemango#5552

Instead of an animation, have you considered using the TweenService? I feel like that would be more appropriate than an animation in this case. I’m not too sure if animations respect collisions.

1 Like

I’ve tried that but it also doesn’t respect collisions sadly.

The only other thing I could think about doing is when moving the sweeper, detect if it hits any pins and force that pin to be pushed in the direction that the sweeper is going.

1 Like

I’ll probably end up doing that if there’s no other solution :smile:

Have you tried using a HingeConstraint to rotate the sweep arm, then a PrismaticConstraint to move it back?
I’ve found Constraints work really well in my Construction Site game with picking up ‘rocks’ using a front end loader, dump truck, bulldozer and crane.

1 Like

I haven’t actually, I’ve never really messed with constraints so I would have pretty much no idea of how to go about that :stuck_out_tongue:

Are the pins welded to the deck?

1 Like

No, they’re completely unanchored

Actually constraints are pretty easy to script. I have a free model door with a HingeConstraint set to Servo that works off a touch pad in the floor. It’s in my models if you want to have a look. You basically set the limits of the hinge and script the hinge’s TargetAngle for where you want it to move to. Same with PrismaticConstraints, just set it to Servo and have the TargetPosition change with the script.
You may have to adjust the Rotational speed of the hinge as well as the Torque of the hinge, but it’s pretty straightforward.

2 Likes

I’ll give that a shot and let you know :smile:

Managed to get that to work with just one issue, the Hinge/Prismatic Constraints only work when the player is next to them, else they don’t move at all

After using hinges for a while, it’s not really sustainable as it can glitch randomly (happens ~1/100 times) and flies into the void. If anyone has a solution to this video, that’d be much appreciated. Apologies for bumping an old post. The issue is still present.

Actually this topic is a problem not even in roblox but other engines like unity. Most people use Inverse kinematics for it. While its a great solution but hard and requirs high level maths. I saw someone people are recommending constraints. I personally don’t use them but onto my extent they should work as they respect physics.

Tl;Dr You have to make a physics based movement/animations.

Damn, that’ll be tough. Thank you for the insight.

No current solution as of yet, basically a bump :slight_smile:

You’re not alone. I’m having the exact same issue as you where the sweeper won’t collide with pins. Let me know if you have got a fix for this. Thanks! :slight_smile: