port_out(0x3c4,0xf02);
I SO WANT TO EQUATE 0x3C4 TO THE VGA SEQUENCER INDEX REGISTER BUT I CAN'T
okay I've fixed OSDEV:
https://wiki.osdev.org/Game_port
They had the introduction of the gameport listed as "the PCjr" (it's from 1981, the PCjr came out in 1984... and didn't even have this gameport connector!) but more importantly, they had the order of the joystick axises wrong.
god. Duke Nukem 1 has so much copy-pasted code.
Like, there's a ton of hint dialog boxes like "You need the key to open this door!" or "you get more points if you catch the balloon"
you'd think they'd just have ShowMessage() and pass it a different string, but nope. it's a different function.
interesting. there's 12 hint-variables which are used to make sure you don't get hinted for something you've used before.
One of them is still maintained, but not used. So there must have been another hintable thing that got dropped
like, it has a function that loops through all 16 color indices and sets them to black. it takes one parameters, which tells it how long to wait between each color is set, so it'll fade slowly to black, instead of being instant.
there's also an identical function that does the same, but sets it to white, instead.
the only difference between the "draw proton"/"draw duke" functions is what base address they draw from.
YOU CAN PASS ADDRESSES TO FUNCTIONS, TODD
Nope! it's known, it's just slightly mis-documented and tricky to pull off.
If you press the fire button (not alt!) and release F6 on the main menu, after launching the game with "dn1 asp", you can play the demo level
so why in the fuck does the game save your position in the level and the camera position?
You'll always be in the hallway! you can't be anywhere else!