• entries
    743
  • comments
    1924
  • views
    580414

Distance Joints

Sign in to follow this  

77 views



Tonight I've added the facility to add distance joints to the editor to link together any actors to either other actors or to map shapes.

Bit of a hack - you can click and drag the circles around but you have to type in the IDs of the two objects you wish to connect in the property window.

When the game loads the level, it finds the relevant owners of bodies, uses Box2D's conversion to convert the world positions of the ends of the joint into local positions relative to the two bodies and then creates the joint.

At the moment, I haven't got around to actually rendering the joints - I plan to have several different styles - Goo, like Squishy's arms, Rope, Chain etc, all of which will require different rendering strategies.

The game also manages DistanceJoints via a Joint interface so it should be easy to add RevoluteJoints and so on later on. This should mean quite a lot of flexibility in level design.

---------------------------------

Still haven't heard whether I got that job, should hopefully know tomorrow but I don't think it is looking too good now. Damn shame since my current job gets worse with each passing day but as I've been threatened with disciplinary action if I make any more negative comments, enough said I think, even in my GD journal.
Sign in to follow this  


0 Comments


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now