Sign in to follow this  

advanced 2D physics engine?

This topic is 3451 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Well I gave up on ODE+Plane2D, to much hassle to get it working. I got the tip to use Novodex, but it's for 3D. That always mean you have to use "tricks" to make it 2D like bounding everything to a z=0 plane. There should be some 2D physics engine that's capable of some rigid bodies, ropes, collision detection, friction, etc. Right? If you know of one, please tell me :) Edit: still interested even though I got ODE to compile ;) [Edited by - Seriema on December 28, 2004 6:57:18 PM]

Share this post


Link to post
Share on other sites
Its not exactly an engine, but whenever I need physics code I just take it from http://www.magic-software.com/SourceCode.html. Also, if you own the book Game Physics by David Eberly, you can download the entire Wild Magic Engine with Physics support for free.

It may not be exactly what you want, but as far as code for 2D Physics, this is the best I have found. There is source code for 2D and 3D geometry. If anyone else knows of an actual engine I would be interested in this too.

Share this post


Link to post
Share on other sites
thank you wyrzy for the tip. I just got two concerns about that lib, 1) it's still focused on 3d even though it supports 2d in some places. 2) this:
// Magic Software, Inc.
// http://www.magic-software.com
// http://www.wild-magic.com
// Copyright (c) 2004. All Rights Reserved
//
// The Game Physics source code is supplied under the terms of the license
// agreement http://www.magic-software.com/License/GamePhysics.pdf and may not
// be copied or disclosed except in accordance with the terms of that
// agreement.

And when reading that license, the first thing is:
"(a) You must own a copy of The Book (“Own The Book”) to use The Software. Ownership of one
book by two or more people does not satisfy the intent of this constraint."

Since I don't have the book it would be wrong to use the code, even thought it's right there and I can almost smell it! :P

Share this post


Link to post
Share on other sites
I'm writing a 2D only physics engine. My belief is that while the 3d physics engines are just starting to get into good user/environment interaction, there is already plenty of horsepower in the newer computers to do realtime liquid, mass objects physics if it is limited to 2D.

What are your reasons for wanting 2D only?

Share this post


Link to post
Share on other sites
Quote:
Original post by pTymN
What are your reasons for wanting 2D only?


My game is in 2D :) I don't need the z-axis for anything. I'm making a platform kind of game.

Share this post


Link to post
Share on other sites
After little Googling I've found this one:

http://www.aidspan.org/alec/projects/

there are some 2d physics demos + source code, it could be worth to look at it.

Quote:

If anyone else knows of an actual engine I would be interested in this too.


I second that - if anyone could share some good links to 2d physics engines (though I think such ones don't exist) or even completed 2d game's engines, that use 2d physics, I would also be greatly interested in it - from experience I know that writing 2d algorithms based on 3d versions isn't just dropping out z axis :-)


EDIT:

wow, look what I've found (following one of the links in above URL): http://physical.alecrivers.com/
Looks very interesting...

Share this post


Link to post
Share on other sites
Yes I found those links on my google run too. But they aren't that well documented. And the PHYSICAL thingie is some kind of game maker, with physics.

Someone should really make a 2D ODE *cough* *cough* ;)

Share this post


Link to post
Share on other sites
you can try my 2d engine, kyc-bats.sf.net (~30meg .rar chronodoll download, and click on the screenshots link for an idea of how it looks).

I plan on rewriting it sometime after finishing my current game, but that may be a few months from now.

If you decide to take a look, make sure you check out all of the different builds. Also some of the binaries are not representative of the sources, so rebuild if you can. You can also change the map files and change the springiness and masses, etc... A noteworthy build is chronobeast (it's just cool heh).

Btw the *.msp files are project files for the MinGW Developer Studio IDE, google.

Share this post


Link to post
Share on other sites
The last post was one and a half years old... :)
But now it's resurrected, I might point out that it seems the license for wild magic has changed. Look here

Share this post


Link to post
Share on other sites
Quote:
Original post by BioSlayer_
you can try out my 2D physics engine.
http://physics2d.sourceforge.net/
I've been meaning to try it out, but have been postponing the effort until Tao moves to .NET 2.0 and we get a Mono binary of Physics2D working....

Share this post


Link to post
Share on other sites
I've been using OPAL for my 2D game. Its pretty nice, though if you already are using ODE, there'd be little point switching.

Share this post


Link to post
Share on other sites
Quote:
There should be some 2D physics engine that's capable of some rigid bodies, ropes, collision detection, friction, etc. Right?


This is a really important discussion. For us not capable for different reasons an easy-to-use 2D physics library with these features is just what we need. I got several amazing ideas I could make with a library like this is my hands.

The closest thing I found was this but it is discontinued due to the developer running out of time, but it looks really promising. The complex demo is just awesome and shows some of what you can do with the power of 2d physics:

http://flatland.sourceforge.net/

If there's anything better or easier, please let me know!

Share this post


Link to post
Share on other sites
There a few pretty good 2d physics engines written in flash, so you could port the open source ones over to whatever programming language you use and even use them as a starting point for your own engine.

Flade (Flash Dynamics Engine) - http://cove.org/flade/
This engine is not in development anymore (see next section), but it's still very good, especially since it's open source.

APE (Actionscript Physics Engine) - http://www.cove.org/ape/
The continuation to Flade, APE is still in the early alpha stage, so it doesn't have as many features as Flade, but it shows very much promise for the future. It's also open source, so you can tinker around with it :P

Others
The Fisix Engine(http://www.fisixengine.com/) isn't open source, but there will be tutorials posted on the site.
The Motor Flash Physics(http://lab.polygonal.de/) is another engine, I'm not sure if it's open source or not.

Share this post


Link to post
Share on other sites
I think I've ranted about just using plain ODE for 2D physics before, but I'll happily do it again :)

To my experience, plain ODE works perfectly for 2D. Just keep all your Z-values zero, and everything just stays perfectly in the XY plane. Furthermore, only do rotations and torques around <0,0,1>. Voila. A very good 2D physics engine, no need for any modifications/extensions to ODE.

This is the approach used by xmoto. The primary downside to this is the heavier computational requirements: a strict 2D physics approach would lower these quite a lot.

Share this post


Link to post
Share on other sites
Again: Rise from your grave!

Ok, you are wondering: Why you ressurected a THAT old topic?
It is because after some time with the same problem (since 2005 btw), this topic helped me much, and now finally I can contribute back!

The thing is still new, but it works well (and it suits well my game in particular, since I do not need soft-bodies, ropes, liquids and that sort of thing that still is not done), Chipmunk: http://wiki.slembcke.net/main/published/Chipmunk

Share this post


Link to post
Share on other sites
Sign in to follow this