First post, by UCyborg
Had this game on the TODO list for a while. When I recently tried to play it again, it was practically unplayable. Turned out it was much buggier than I was aware of. So I put together a patch which solves most of the problems people have been experiencing over the years. It even runs on the ancient Windows NT 4.0 (in software mode at least), which was totally unsupported until now. Of course, it runs great on Windows 10 as well and should theoretically run on computers with varying graphics hardware with nice graphics with the help of Glide wrapper. I recommend nGlide.
So now we assume you've already got it installed and got around the issue of 64-bit OSes not being able to run 16-bit installer. For base game, Gold Patch is prerequisite for applying my patch. For Nitro Pack, the only thing that's needed is A3D-Live! wrapper (included, can be installed any time) to fix the all-sounds-playing-at-100%-volume-at-player-position problem because game's DirectSound code is broken for some reason.
As usual for my patches, the goal is to get the game working with minimal amount of compatibility options. So you can turn off any compatibility options you've previously set on I76.EXE/nitro.exe executable and apply Disable_Interstate76_Compat_Shims.reg registry file. Game should have Modify permissions for its own folder. If it's located under Program Files and settings related to UAC/file system virtualization haven't been changed, there shouldn't be any problems, plus each user will have its own save files. Applies to Windows Vista and beyond. For older systems/other install locations, Users group may have to be granted Modify permissions explicitly on game folder (assuming we're running as user with limited rights).
Here comes the changelog:
- Fixed some, worked-around other memory management bugs, which improves stability; mission 12 -> 13 transition works in I76, also no more need for EmulateHeap shim (the only semi-useful thing from Windows 95 compatibility mode), which doesn't actually fix anything.
- Fixed game freezing when clicking menu option if hardware sound acceleration is available.
- Fixed certain startup crashes/errors when initing graphics with 3D accelerated renderers enabled (Glide/D3D).
- Skipped some unnecessary CPU checking code containing privileged instructions (crashes at startup if privileged instruction exceptions aren't ignored by the OS).
- Corrected memory checking code to avoid error about insufficient memory when system has more than 2 GB of RAM.
- Fixed an issue with laggy physics simulation that occurs when the system has been running for several days.
- Fixed an issue with music playback not restarting during gameplay after the track has finished playing (another issue that occurs when the system has been running for extended periods of time).
- After the music track has finished playing during gameplay, the mission specific track will play again now instead of always the 1st music track.
- Rearview mirror refreshes every frame now.
- Includes Shane's netcode patch for compatibility with NAT, Nitro Pack version also forwards port on router when hosting the game (if UPnP is supported).
- Fixed registry handle leaks.
- Added frame rate limiter which defaults to limiting the game to run at 20 FPS to workaround bugs that occur at higher frame-rates.
- GDI windowed mode now works on Windows NT systems.
- Embedded manifest in executables:
- Marked as high-DPI aware.
- Requests version 6.00 of Common Controls Library to enable visual styles in those occassional message boxes.
- Executables have been flagged as compatible with DEP (Data Execution Prevention).
Nitro Pack specific:
- Clicking Scenarios in main menu will no longer stop music playback.
- DxWnd's virtual CD audio feature now works when the computer doesn't have any optical drives.
- Removed OS check from Nitro Pack's SPLASH.EXE (3D options are now always available).
- Fixed inconsistent handling of playing CD music between Interstate '76 and Nitro Pack (took care of regression from the first patch release plus I76 specific bug - same track is not supposed to loop).
- Fixed music volume controls so setting max volume in menus doesn't set it only to half.
- Game can now select the correct CD drive for music playback when computer has more than one.
- Fixed certain GDI object leaks.
- Call DestroyWindow on exit (no more game window on the screen if the process is still held by the debugger).
- Added frame limiter to the mission failed screen.
Some general thoughts:
At some point, I've read about the magic 24 FPS as the ideal frame-rate to get properly working physics. Obviously, when the game was made, nobody was talking about frame rates as game physics isn't intentionally tied to frame-rate. Devs just write code, overlook some details when implementing it and leave it at that if it appears to work correctly.
Anyway, my issue with the supposedly magic 24 FPS is that 7.62 MM MG firing sound is being interrupted at regular intervals while it sounds fine at 20 FPS, hence why I set the limit to 20 FPS.
Another important thing, the game really only works as long as it does without crashing on Windows 95 by accident. Saw some really bizarre code in there: accessing buffers beyond their boundaries, overwriting variable holding a pointer (handle) to one heap with pointer to another heap, setting some variable based on the content of uninitialized memory.
Some of the memory management bugs are still lurking in there and could cause the crash out-of-the-blue (could be more obvious with player-made maps, with which I'm not familiar with), but the most obvious ones have been identified and fixed. I was going to fix them from A - Z, but the first thing that is found with Page Heap enabled is some access beyond buffer boundary mid-play in some giant function, would need thorough look to identify the start and the end of actually allocated memory.
Thoughts about issues with graphics APIs - menus/cutscenes
There is something about how it uses DirectDraw for menus when you launch the game in 3D accelerated mode. Some palette related operation makes it either crash right away or just fail so it complains about inability to initialize 3D acceleration. This is the most easily worked around by invoking DIrectDraw without support for hardware acceleration. It still happens (Windows 10, probably 8.x as well) that one ends up with the black screen until something causes the picture refresh. This is the most easily observed if you have two screens and you invoke Aero Peek feature.
Besides DxWnd, which is mentioned in the ReadMe and can be used to get around that, there's also dgVoodoo2. dgVoodoo2 is also the easiest option to get around garbled color issues. I'm not sure if DxWnd can also be used to solve the color issues. Years ago, when I missed with Window 7's DirectDraw options to try to fix that, it didn't work permanently.
Playing music from disk
DxWnd's virtual CD audio option works, though at least at the time of this writing, volume can only be set in DxWnd application itself.
A man can be himself only so long as he is alone; and if he does not love solitude, he will not love freedom; for it is only when he is alone that he is really free.