Jump to content

Recommended Posts

Posted

Do you mean the tightness of a free spinning joint, or a motorized joint? Motorized joints have a speed you can set.

My job is to make tools you love, with the features you want, and performance you can't live without.

Posted

I mean the tightness of a free spinning joint.

 

For example: Parent and child of hinge joint are both children of a jumping character. The child of the hinge joint is way too slow to follow the character while they are jumping or even walking slowly.

 

So if I used a weapon or even hair as the child it would appear to be floating behind the player as it catches up.

 

Is there any sort of constraint or tightness value I can tweak to make the child react quicker?

 

edit: Come to think of it I had the same issue in my Castle Defender demo game I made. The enemies were made of csg boxes connected by hinge joints so when you picked them up they could ragdoll. The issue appeared when the enemies were moved quickly or thrown as the connected body parts of the enemies would fly in every direction instead of holding together (it was pretty funny in that game though so I never thought to look into it).

Check out my game Rogue Snowboarding- 

https://haydenmango.itch.io/roguesnowboarding

Posted

That could be difficult since the player physics aren't using the "real" rigid body system.

My job is to make tools you love, with the features you want, and performance you can't live without.

Posted

This example shows the issue Haydenmango is describing where the child is slow to follow the parent's movement:

window = Window:Create()
context = Context:Create(window)
world = World:Create()
camera = Camera:Create()
camera:Move(0,0,-4)
light = DirectionalLight:Create()
light:SetRotation(35,35,0)

parent = Model:Box()
parent:SetColor(0.0,0.0,1.0)

child = Model:Box()
child:SetColor(1.0,0.0,0.0)
child:SetMass(1)
child:SetPosition(2,0,0)

joint = Joint:Hinge(0,0,0, 0,0,1, child, parent)

while true do
    if window:Closed() or window:KeyDown(Key.Escape) then return false end

	p = window:GetMousePosition()
	p.z = 4
	p = camera:UnProject(p)
	parent:SetPosition(p)

	Time:Update()
	world:Update()
	world:Render()
	context:Sync()
end

 

  • Upvote 1

Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590

LE / 3DWS / BMX / Hexagon

macklebee's channel

Posted

So based on the lack of direct responses to my question "Is there no way to add more constraint/tightness to hinge joints?" I will assume the answer is that there is currently no way to do this.

 

If there is a way to do this someone please tell me, I really really really want to get this to work properly. I've had so many ideas for using joint physics lately but 90% of these ideas (pretty much any idea involving moving joints) won't work accurately without the ability to constrain/tighten the joints.

 

If there really is no way to do this currently could this topic be moved to the suggestion box please?

Check out my game Rogue Snowboarding- 

https://haydenmango.itch.io/roguesnowboarding

  • 2 weeks later...
Posted

Not sure how this will affect your game, but the kinematic joint could be used to force the attached end to go where you want.

My job is to make tools you love, with the features you want, and performance you can't live without.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...