News:

Herr Otto Partz says you're all nothing but pipsqueaks!

Main Menu

Stunts PolyMod (projected)

Started by Cas, December 24, 2024, 12:01:57 AM

Previous topic - Next topic

Cas

So here I am, introducing a project I have worked zero on... Yet, I've thought a lot about it for quite some time and now I have simplified it in my mind to the point that I think it will be pretty simple to implement. I've PM'd Daniel3D to give me a hand with it. Daniël, hope you have some time 8)

Anyway, it goes like this. I want to impact the ReStunts code again, but in a modular way. Instead of inserting code that does something, I want, at different points in the code, well chosen ones, insert code that only calls an interrupt, say int 93h (the year I had my first PC). It'd pass the data segment and a function ID to it. The function ID would just be a number that would change depending on the position in the code. Say, 1 for the beginning of the main loop during the game, 2 for the moment when you've just crashed, 3 for the point when the track has loaded and you see the road for the first time in a race, etc.

Then, this variation of the binary would of course crash unless this interrupt gets bridged. Initially, I would just apply a null "jumper" with a tiny TSR and control-test the mod to see the game runs normally. After that, I'd begin creating functions that act according to the points where the call was made. The one I'm most interesting in making first is a mod that will output the current car and paint-job at the start of a race or where you select a car, and then output your position and orientation during the race in real time. This would be saved in a file that can be picked up by my engine, so you can use it to play Stunts. I'll later add network capabilities there so the engine can actually show the other live pipsqueaks (as "ghost" cars).

That's not the quick-to-implement part, of course... The quick part is creating the PolyMod. The mods that will plug to it are another thing, but... once the PolyMod works, we no longer will need to tweak the main code and we'll be able to make a TSR where you can plug and unplug mods without disrupting other mods. So that's my idea. Any thoughts are appreciated :)
Earth is my country. Science is my religion.