What's really impressive is that an active member of this site, "The Taxman", completed a near-perfect implementation of these physics, and successfully collaborated with SEGA to create official updated rereleases of Sonic CD [1], Sonic 1, and Sonic 2.
These were actually a collaboration of two members of the community, "The Taxman" and "Stealth". The former did the original Sonic CD iPhone demo which opened the lines of communication with SEGA, while the later helped in perfecting the physics and other details of the original games. Stealth had a more extensive history [1] than The Taxman in disassembling and disecting the original games and even did an unofficial port of Sonic 1 to GBA (limited to one level) before.
Stealth is in fact urging SEGA now to consider giving them both green light to develop a rerelease (remaster really) of Sonic 3/K [2], which would be the next logical step having done all the prior games, but despite the super high attention to detail and love the remasters got, SEGA doesn't seem to be interested, presumably because the remasters didn't do that well commercially. A shame, because it probably wouldn't be that expensive for SEGA even if they did it just for the fan service.
I'm honestly impressed that SEGA allowed them to work on anything at all. As someone who used to really enjoy Sonic games, I can't help but resent SEGA for their seeming fixation on releasing absolutely terrible Sonic games.
For a brief period around 2011, it looked like they were back on track -- staring with Sonic Colors on the Wii, and followed by Sonic Generations and Sonic 4ep2, they were on a roll releasing excellent games. Then came the complete garbage that was Sonic Lost World, and it was back downhill from there...
In case you are interested in learning more about the original games there are fully documented and dissected disassemblies available here (Motorola 68k mostly): http://info.sonicretro.org/Disassemblies
I think the most interesting part of the guide was that the 'physics' engine is _very pseudo physics- I would not have imagined that to handle running on walls or ceilings would involve switching the logic to disjoint modes (four quadrants approach) and moving the base sensors to accommodate the mode. In fact, I wouldn't imagine that the physics logic would require all the sensors that it does to get the feel of the game right.
I can only imagine how much tweaking had to be done for all the values to play nicely and be enjoyable- perhaps a less heuristic-based implementation doesn't offer as much control or was too process intensive?
Also a surprise to see that angle values were stored directly at grid pixel locations.
It's certainly true that the CPU (a Motorola 68k clocked at ~7.60 MHz) didn't leave much space for process intensive operations; one misstep in your code and the entire game would lag and slowdown. Developers of Sega Genesis games were in fact discouraged of using DIV (division) instructions because they took so many cycles. Fortunately most games could do with bit shifts, IIRC the Sonic games almost never used DIV instructions and did fine.
Most programs even today don't do many integer divisions (which is why ARM doesn't even support them, for example). Compilers are really good at eliminating them.
Would you run an emulator in the background and interpret the 2d output to drive the 3d game or would you extract the physics of the game similar to this article and just re-implement so you're not relying on an emulator.
[1] http://info.sonicretro.org/Sonic_the_Hedgehog_CD_(2011)