Blackberry said:
We'll never get there, but still let's strive into uncharted territory, and do our best in creating hopefully "The Most Complex Physic System Ever Seen In A Video Game!” (not an easy task at
Personally i think physics is the sleeping princess of gaming. Nothing seems more promising than that, and i agree.
But why is the princess sill sleeping? Physics simulation was touted to be the next big thing in the early 2000's, but it was used very rarely and never became a dominating trend. Why not?
So let's analyze history…
- Super Mario. You can pick up objects and carry them with you. Objects can be thrown and placed. They can be used as weapons, to build a staircase to reach a higher platform, or interact with static objects like a key opening a door.
- Half Life 2. Same thing, but now in 3D.
- Penumbra (Trilogy starting at 2007, first person adventure game). Same thing, but physics became the primary mechanic to interact with anything. Remarkable controls - you can drag a drawer open or pull levers by moving the mouse. Everything feels like a real physical object, raising immersion to a totally new level. It's almost 20 years old now, but still the game with the most advanced and integrated physics simulation.
I would not put Portal on this list, because it does only the ‘usual’ Super Mario things and did not surpass HL2 regarding Physics simulation.
TIM and similar physics puzzlers might be worth to mention, but in any case: Physics did not became a widespread gamplay mechanics in games. They use it for ragdolls to give realistic death animations. They put some passive crates around which fly off on explosions, and eventually you can carry and stack them, but that's it.
This is disappointing. Why is it that way? What's the problem with physics simulation?
Well, i can only guess for the reasons:
Physics simulation is hard. Objects jitter, or tunnel through each other. They might fall through the floor and get lost. Players might get stuck below a pile of crates.
It's not reliable, and so most devs tone it down to minimize potential issues which are otherwise hard to detect and even harder to solve. Related ‘solutions’ are mostly just hacks, which work in some cases but can make others even worse.
Using physics simulation is hard. For example, the first thing you might do is picking objects up and carry them with you, like the crates in Portal. But the player can rotate very quickly using mouse look, so you get the problem of the carried object lagging back in time. The related control problem is not trivial to solve.
Even then, the carried object might interact badly with others. For example, if you pusk it against a wall, it might start to jitter wildly. Games like HL2 tried to hide the issues by using a force field of a gravity gun to hold an object. So the player thinks the jitter is a result of the magic force field. Dead Space did the same.
Only Penumbra managed to make carried objects feel like holding them robustly with your own hands.
Physics engines have limited accuracy. Joints connecting a heavy and a light weight objects might break or behave weired. Stress can cause solver explosions. Objects might keep sinking slowly into the floor. Controlling physics objects precisly is difficult, since we should do so only by external forces or joint motors, but we should not set velocity directly or teleporting them around for best results.
So yeah, i think the princess is still sleeping becasue she is hard to wake.
For me personally the most progress came unexpected and coincidentally. I've worked on my own physics engine initially, but then Havok offered a free version of their engine and i've used that for a while. I also had used Math Engine and ODE before to compare results with my own stuff.
When Havok was no longer free, i was looking for some open source alterantives. I've tried Bullet, but it's accuracy and robustness was much worse than Havok. So i've also tried a closed source library, Newton Dynamics. I did not expect much from an engine made by a single guy in his spare time, but i found out his engine somehow does not have all those typical problems. It's super accurate and robust, maening it can do a lot of things other engines simply can't. Jitter happens only very rarely, large mass ratios work, and performance is comparable to other engines and often better.
So i kept support for both Newton and Bullet, but then Newton become open source i have removed Bullet since it could not compete the quality of Newton.
After learning more about the engine, i found out i can program my own joints with motors, and it's very flexible, pretty easy and intuitive.
Using this, i could do the impossible, giving my old dream another try: Self-balancing and walking ragdolls.
And it works. This would have been totally impossible with any other engine i have tried, but Newton can do it.
Sorry for the long story, but i tell you: Choice of physics engine matters.
But using off the shelf game engines like Unity or Unreal, you don't have a choice. Which is the primary reason i do not consider those game engines. Their physics solutions are not accurate and robust enough for my needs, but they can't be replaced easily.
Blackberry said:
or maybe you decide to fill a water tank and slowly drag it up all the stairs to push it off the roof into their enclosure!?
This one is probably not yet possible. I saw some PhysX demos combining fluid and rigid body simulation, but while impressive this is just too expensive to be practical.
Try to reduce your ideas to rigid bodies. Some engines also support soft bodies and cloth, but millions of fluid particles in a box which you can carry around is somethign i might not see happenign within my lifetime. Companies like NVidia just show off such stuff to convince peopel on spending way too much money for huge GPUs.
Blackberry said:
or maybe you forgot to turn it fully on, and if you do, with the increased pressure you could reach them!?
Similar issue. If you want water puzzles, you likely need abstract approximations to fake the water. But it's worth the effort only if the water is a primary mechanic in your game.
(I just assume you have 3D in mind. In 2D, full scene fluid simulation is totally possible.)
Blackberry said:
(this is obviously alot easier said than programmed)
Yeah, it's hard both on the programming and the design side.
But it needs to be done. Good luck! \:D/