Help with ROBLOX part physics, hinge motors and character collisions

I am working on a workshop building game where you can place blocks down and power builds using pipes etc. Anyway…

I have been able to build a basic car using my system, that uses suspensions, motor hinge constraints to make the wheels turn, and servo hinge constraints to allow steering.

The problems that are occurring are:

  1. Players can move the builds around when running into them.
  2. Is there a way to lock the hinges from external forces, so they only move with the angular velocity?

Here are some screenshots of what the build looks like:

image


To prevent players from moving the vehicle, add weight to the vehicle by increasing the density of your main part.

You can control the hinges so that they only move when the player is in the driver seat (through script). I guess my next question is what are you trying to accomplish by this?

I am trying to make it so that all players cannot move other peoples builds by walking into them, otherwise it would become very annoying.
I have done all the scripting for this, I have full control over setting angular velocities and target angles for the motors and servos, however the issue is that I don’t want other parts to be able to move the hinges, as it causes buggy car movement when going at high speed, as the servos are being moved by the ground.

I guess collision filtering would solve both of those issues, unless i’m completely misunderstanding your goal, sorry.

Sorry I might be quite vague with my problem, CollisionFiltering would limit collisions between certain parts completely. I don’t want this, I just don’t characters to be able to move the whole vehicle by walking into it.
Like you said earlier, the most probable solution is to increase the mass of the parts, but the other problem with the servos and motors still confuses me.

When you say other parts move the hinges, which parts?

And yes the mass will solve characters not being able to move the vehicles, and also you would be able to set up the other characters as a collision group to the vehicles if you dont want them to collide with the vehicles at all… but the mass is the easier solution.

I’m on about mainly the floor (ground), but basically any part. I just wanted to know if there was a way to essentially “lock” a hinge so it would only use the given velocities or target angles to move.

1 Like