Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (777)
Games in Android Showcase (231)
games submitted by our members
Games in WIP (856)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Xith3D physics  (Read 3755 times)
0 Members and 1 Guest are viewing this topic.
Offline DavidYazel

Junior Devvie

Java games rock!

« Posted 2003-08-18 16:02:34 »

I am considering adding physics capability to Xith3d.  Like shadowing, you would pick sub-roots of your scenegraph to inidcate the root of an "object", even if the object is really made up of lots of shapes.  You could supply collision geometry or it will calculate a convex hull for the geometry below it.  You would also assign a mass to the object so that momentum, friction and inertia can be properly calculated.

You would be able to attach Motions to the objects, which are similar to the movement behavior interpolators of Java3d, execpt that these motions will honor mass, volume, velocity and collisions.

I really don't want to write a super sophisticated physics engine, but I would like to expose the framework so that people can build on the engine to make it more sophisticated, or even hook in a third-party engine.

Any suggestion on how to begin?  Any java physics libraries out there?  Any thoughts on this idea?

David Yazel
Xith3D Project Founder

It may look complicated, but in the end it is just a bunch of triangles
Offline Markus_Persson

JGO Wizard

Medals: 19
Projects: 19

Mojang Specifications

« Reply #1 - Posted 2003-08-18 17:12:05 »

That is a VERY good idea.

I don't know enough about physics myself to contribute, but integrating physics straight into the scenegraph (and, in a way, making it all more of an "engine") would kick ass.

Play Minecraft!
Offline swpalmer

JGO Coder

Exp: 12 years

Where's the Kaboom?

« Reply #2 - Posted 2003-08-18 22:22:05 »

I would avoid tightly integrating the physics into the rendering engine.  
As you say people may want to hook in more advanced engines etc...  I would add generalized hooks to Xith3D and then build your physics engine using these hooks as a separate layer.

There are just so many things that someone might want to add to a physics/game engine it is of course impossible to think of everything ahead of time.  Even thinking of all the needed hooks could be hard.  Eg. what about friction, temperature, prevailing winds, ocean currents, gravity forces or radiation levels... all of which could effect movement of game objects or more abstract things related to the game engine like the effectiveness of tractor beams or energy shields..

These would be beyond the scope of a general engine, but they might be needed for specific games and then you would need to plug them in to Xith3D somehow, as long as they can all is cool, but if these attributes have to be accessed via a different mechanism than mass and velocity it could complicate the design.

Maybe much of this ability is already in Xith3D? I don't know.  For instance I remember someone (you?) talking about the political alignment of regions in the game world and other such attributes.. where/how would they be stored?  If they are stored with hooks into the world geometry could arbitrary physics quantities be stored in the same way?

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline AndersDahlberg

Junior Devvie

« Reply #3 - Posted 2003-08-19 08:37:42 »

Maybe some kind of visitor pattern would be a good design for something like this?

Then it just comes down to what should be exposed though Grin
Pages: [1]
  ignore  |  Print  

hadezbladez (335 views)
2018-11-16 13:46:03

hadezbladez (177 views)
2018-11-16 13:41:33

hadezbladez (336 views)
2018-11-16 13:35:35

hadezbladez (82 views)
2018-11-16 13:32:03

EgonOlsen (2175 views)
2018-06-10 19:43:48

EgonOlsen (2203 views)
2018-06-10 19:43:44

EgonOlsen (1376 views)
2018-06-10 19:43:20

DesertCoockie (2008 views)
2018-05-13 18:23:11

nelsongames (1646 views)
2018-04-24 18:15:36

nelsongames (2297 views)
2018-04-24 18:14:32
Deployment and Packaging
by mudlee
2018-08-22 18:09:50

Java Gaming Resources
by gouessej
2018-08-22 08:19:41

Deployment and Packaging
by gouessej
2018-08-22 08:04:08

Deployment and Packaging
by gouessej
2018-08-22 08:03:45

Deployment and Packaging
by philfrei
2018-08-20 02:33:38

Deployment and Packaging
by philfrei
2018-08-20 02:29:55

Deployment and Packaging
by philfrei
2018-08-19 23:56:20

Deployment and Packaging
by philfrei
2018-08-19 23:54:46 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!