There’s a certain hypocrisy in next-gen games. On one hand, some people tell me that next-gen games are all about polishing the details - and then they go work on their parallax mapping. On the other hand, when I point out some of the details they blatantly ignore, I’m told that “nobody cares” about them. Jeez, get your story straight!
Fact: seven-years old PC games (and a number of PS2 games) handle a few things better than current “next-gen” games.
Proof: check out the shells coming out of the gun in Oni. And then in Gears of War.
In Oni, the shells collide with the environment, slide down the slopes, you can hear their sound when they touch the ground, and they fade out smoothly after a while.
In Gears of War, they don’t collide with anything, they don’t make any sound, and I can’t tell if they fade out since they just royally go through the ground.
I guess that’s one of those “next-gen” details that nobody cares about. Still, it’s slightly disappointing.
Now, is there any reason why Oni (or Ghost In The Shell - Standalone Complex on PS2, etc) would handle this better than top of the line Xbox360 games?
Technically the answer is easy: Oni (and, I suspect, quite a few PS2 games) solves this with particles. Each shell is a single particle with a rotating texture - or better, rotating UVs. Collisions with the environment only involve simple raycasts, a collision callback is used to play the sound of shells touching the ground, and fading the shells out is easy since alpha-blending is a built-in feature of any particle system. A single particle is enough to fool the eyes since those shells are usually quite small on the screen. To be honest I never realized that the shells in Oni were simple particles, until I tried to re-program them in Konoko Payne.
Now, the problem with Gears of War is that they probably tried to make it “next-gen”. That is, I suspect they tried to handle shells as “real” meshes, controlled by a full-featured physics engine. Unfortunately this is an extraordinarily bad idea.
On the rendering side it’s not too bad. A real mesh obviously consumes more resources than a single particle, and it would be very slow to render a hundred bullets one at a time (set-world-matrix, render mesh, do that again), but nowadays there are instancing facilities in your favorite rendering API to make this possible. It’s still a lot more expensive than rendering a few hundred particles, and fading the shells out is more difficult (opaque meshes and transparent meshes are usually not even rendered by the same pipeline), but overall it’s not too painful.
On the physics side however, things are not so great. By nature the shells are very small, so if your physics engine doesn’t support continuous collision detection (CCD), it’s likely they’ll go straight through the ground. And if it does support CCD, well, you just added a hundred CCD-enabled rigid bodies to your simulation: not a good move. Your bullets may kill your enemies, but they just killed your framerate as well.
So, how do “next gen” games solve this problem? Well. Apparently they just ignore it, and are happy to live with ghost shells going through the ground. Somehow, I preferred the old-gen solution.