Page 2 of 3 < 1 2 3 >
Topic Options
#53848 - 09/07/07 07:23 AM Re: Physics? [Re: vortex2]
LIJI


Registered: 06/30/06
Posts: 1167
Loc: Looking for Jeff's Cookie
At least we know you're alive now. \:\)
_________________________
Lior Halphon
Developer - AquadaSoft

Neatwares Network

Top
#53859 - 09/07/07 08:24 AM Re: Physics? [Re: vortex2]
Nifflas


Registered: 06/30/06
Posts: 1677
This is what I'd like to accomplish! (and I'm ready to pay quite a lot for it)

I want to create a game that takes place in a 2D landscape. The background scenery will contain slopes, but it does not have to be curved like in the demonstration images.

Except for the static terrain, I am only interested in two shapes. Rectangles and Spheres. The player character will be a ball that can be rolled with the left and right arrow keys. Boxes and rectangles collide realistically with the ball, and can be pushed and tipped.

There must be a way to attach several rectangles and spheres to each other, to create more complex objects (four rectangles can become a windmill). There must also be a way to attach a physical object to the background, so it's X and Y position becomes fixed, but it still begins to rotate realistically if you push it somewhere.




Edited by Nifflas (09/07/07 08:28 AM)

Top
#53866 - 09/07/07 08:52 AM Re: Physics? [Re: Nifflas]
Sphax


Registered: 06/30/06
Posts: 2969
Loc: Paris, France
I have a similar project Nifflas but with a real character instead of the ball like the litle big planet game which will be released soon. \:\)
_________________________
FusionUpdater: Keep your extensions up to date and install new ones! Last update: 2009-05-21

Top
#53873 - 09/07/07 09:38 AM Re: Physics? [Re: Sphax]
Nifflas


Registered: 06/30/06
Posts: 1677
Well, I'm stuck without the physics. It's too complex to do without events. I wonder if Erin Catto's Box2D could be made into an MMF2 extension. It's supposed to be used for boxes only, yet the freeware game Crayon Physics that uses it works nicely with a rolling ball...

2D physics libraries:

Box2D
Physics 2D
Flatland 2D
PyWeek
APE (there's a c++ port at that page)

I wonder how hard it can be to make one of those physics engines run in MMF2. After all, they don't need to render anything, as long as you can attach the position and angle of an active object to one of the physics objects.

Remember that all I need is some pretty basic 'n simple physics as described in my last post.


Edited by Nifflas (09/07/07 10:44 AM)

Top
#53991 - 09/07/07 09:59 PM Re: Physics? [Re: Nifflas]
vortex2


Registered: 06/30/06
Posts: 1009
Loc: Texas
I already have a working implementation of Flatland. It is not a matter of it not existing is that I don't have the time to get the last bit of it finished, document it, make examples, and support it.
_________________________
Waiting in the shadows...

Top
#54006 - 09/08/07 03:44 AM Re: Physics? [Re: vortex2]
AndyH


Registered: 06/29/06
Posts: 556
Good to know Vortex. I would only worry about getting it finished in the first instance. I'm sure there will be people who can help document it, and the only support would be around bug hunting but something you can worry about later \:\)

So still looking forward to it, I hope you do finish it soon.
_________________________
--
Andy H
ovine by design | Twitter | Vic20Gamer

Top
#54010 - 09/08/07 03:58 AM Re: Physics? [Re: AndyH]
Brovic


Registered: 07/01/06
Posts: 89
Loc: France
Clickteam should support a kind of "mfxforge" so that more people could work on a single extension. It is hard to work alone and sometimes extensions are just abandoned (irrlicht,...) or no more supported.

Top
#54011 - 09/08/07 04:12 AM Re: Physics? [Re: Nifflas]
AndyH


Registered: 06/29/06
Posts: 556
 Originally Posted By: Nifflas
This is what I'd like to accomplish! (and I'm ready to pay quite a lot for it)

I want to create a game that takes place in a 2D landscape. The background scenery will contain slopes, but it does not have to be curved like in the demonstration images.

Except for the static terrain, I am only interested in two shapes. Rectangles and Spheres. The player character will be a ball that can be rolled with the left and right arrow keys. Boxes and rectangles collide realistically with the ball, and can be pushed and tipped.

There must be a way to attach several rectangles and spheres to each other, to create more complex objects (four rectangles can become a windmill). There must also be a way to attach a physical object to the background, so it's X and Y position becomes fixed, but it still begins to rotate realistically if you push it somewhere.




Some nice ideas there nifflas.

I'd also want to be able to apply invisible force to surrounding objects (ie: from an x/y point in the frame), and if possible be able to define groups that physics objects belong to so I could limit the force I apply to certtain groups.

To be universally useful, it would be important to be able to define a terrain, like a polygon shape.

Other ideas we've had in the past is to be able to load and save configuration data. As the extension can possibly only go so far to hook up with MMF objects (like actives and backgrounds) automatically, you would probably need to 'describe' your physics world. So being able to load/save a configuration would aid in making tools directly in MMF to allow making an editor for your physics world.
_________________________
--
Andy H
ovine by design | Twitter | Vic20Gamer

Top
#54018 - 09/08/07 06:06 AM Re: Physics? [Re: vortex2]
Nifflas


Registered: 06/30/06
Posts: 1677
 Originally Posted By: vortex2
I already have a working implementation of Flatland. It is not a matter of it not existing is that I don't have the time to get the last bit of it finished, document it, make examples, and support it.

Well, that post was in case someone else would like to give it a try \:\)

Top
#54045 - 09/08/07 10:05 AM Re: Physics? [Re: Nifflas]
vortex2


Registered: 06/30/06
Posts: 1009
Loc: Texas
I will go ahead and list what my extension supports/ will support so that you guys have a better idea of what to expect :P.

My extension is a rigid body dynamics extension that has support for complex shapes via primitive composites. So a table for instance can be created from three rectangle primitives in the same collision space. We have four collision primitives circle, line, trangle, rectangle.


The extension has a joint system that allows for an object to rotate around a point or constrain within a certain range of another point/object

To explain this imagine a swinging pendulmn. The first joint type allows me to attach a ball to the "anchor" and the object will swing around this point within a certain distance. If you are familar with my platform swing extension then it will behave a bit like this.

The second joint type is basically a spring with an adjustable constant. You can imagine this like the shocks on a car or like a bar connecting two objects. Depending on the spring constant and such the objects move back and forth within the range.

The key to this is that the first part constrains rotation while the second part controls how much spring force to apply to keep the objects seperated. If a collision happens then the spring is compressed and the objects become closer together.

Now the next part is something called AMotors (Angular Motors). An AMotor allows us to control the rotation of an object directly :P . What this does is it allows us to create bikes and such where one tire is driven by an engine and the friction of the tire against the road propells the bike forward.

After Joints and AMotors we forces and torques. A force makes an object move in a direction. One example of a force is gravity but in my extension I have provided a shortcut for gravity that does the force automatically for you. Torques make an object rotate, however unlike AMotors Torques are not constant and they are impulse based (which means they are applied once and other forces act on them, ect).

We could apply a force to propell a ball out of a cannon into a stack of blocks :P .

We could apply a torque to a gear for instance to get the gear to start moving and move other gears.

Some other things that the object has are static objects (Objects which are constrained to a certain position and orientation for things like platforms) and features to make an object stay at a point but still rotate.

A material system that I am designing and have mostly implemented allows for the storage of varios material properties for easy application to an object. If I had a tire then I could name the tire material and use it throughout the simulation whenever I needed those properties.

One thing that would be neat is joint brekage but that might be a bit complex.

Another feature that I had planned from the start but simply have not had the time to do is the World XML system that would allow for external configurations. I had planned to make a fancy editor and such for it and so you could make a complete simulation with very little actual events, however such a thing is extremely complicated to do and would be like designing another complete application. As a result I am not sure how much of this functionality will end up in the final version and it might have to wait for version 2.0.

Something the object will NOT support is soft body dynamics because it is slow, hard to implement, insane to render, and just not practical at all. Soft body dynamics are things like modeling a water balloon :P .

When everything is done you will be able to construct a bike out of joints for the wheels, an AMotor on one of the wheels and a ramp made out of a triangle primitive.

Hopefully this gives you a better idea of what my extension does and what I have been working on. It is quite complex and that is why it is taking a good bit of time to complete.


Edited by vortex2 (09/08/07 10:08 AM)
_________________________
Waiting in the shadows...

Top
Page 2 of 3 < 1 2 3 >


Site Links
Forum Index

Home Page
Online Store
Tutorials
Download Center
French Forum
Quick File Links
Multimedia Fusion 2
Updates - build 248
Standard Version
Developer Version

Extension Packs
Bonus Pack 1
Bonus Pack 2
z33z Extension Pack
LIJI Extension Pack

The Games Factory 2
Latest Update - build 248
Community Links
MFA Repository
GameBuilder
Klikdisc
The Daily Click
Madword Arcade

Extensions
Neatwares Extension List
Extension Updater

Lacewing & Moo Server
Klikfarm
Click Chat
11 People are chatting
Game Builder
Latest Game

Wheel of Words

Latest News
Blue Friends 1.4!
GameBuilder Chat BETA!
PRC BETA IS OUT!