BeamNG.Earth
BeamNG.drive용 1:1 비율 실시간 지구, 실제 고도·위성 이미지·부동 원점·보조 서버에서 LOD 스트리밍
4K and widescreen (3840x2160 / 1920x1080) patch and Windows 11 fix for GOG Interstate '82 — adds the 16:9 resolutions the game never shipped with, plus crash and key-binding fixes. No launcher required.
저장소 README에서 가져옴
README 전체를 불러오는 중입니다. 아래는 저장된 발췌입니다.
Interstate '82 — 4K and Widescreen (3840x2160 / 1920x1080) and Windows 11 Fix
Small, source-available compatibility shim that makes the GOG release of Interstate '82 run on Windows 10 and 11 — and adds the 4K and widescreen resolutions the game never shipped with.README 전문 보기 ↗Small, source-available compatibility shim that makes the GOG release of Interstate '82 run on Windows 10 and 11 — and adds the 4K and widescreen resolutions the game never shipped with.
Interstate '82 was built for 4:3 and 5:4 monitors: it offers exactly four resolutions (640x480, 800x600, 1024x768, 1280x1024) and rejects everything else, so no config file or wrapper can give you 16:9. This shim widens that filter, and 1920x1080 and 3840x2160 appear in the game's own video options. The engine renders the wider frame natively instead of stretching it, the HUD moves to the screen edges — and it scales the HUD with the resolution, so 4K stays readable rather than shrinking into a corner.
4K measured around 100 fps on an RTX 4070 Ti where 1080p reached 240, so it costs roughly what the extra pixels are worth and nothing more.
It also fixes the crashes, the start-up hang and the input problems that stop the game on modern Windows, gets GOG's CD soundtrack playing next to the sound effects, and removes the need for DxWnd's visible launcher. It does not contain any game files, nor a copy of DDrawCompat.
Tested on Windows 11, mainly on a PC with an NVIDIA RTX 4070 Ti.
Built with heavy use of AI (Claude by Anthropic); see AI transparency for who did what.
Project page: https://sputnikkaputtnik.github.io/interstate82-widescreen-4k-fix/
Keywords: Interstate 82 4K patch, Interstate '82 widescreen patch, Interstate 82 1080p, 2160p, 16:9 fix, Windows 11 crash fix, GOG, DDrawCompat, resolution patch, draw distance, view distance, fog.
DirectDraw/Direct3D 1-7 presentation through DDrawCompat, configured for borderless fullscreen and with 16x anisotropic texture filtering, which keeps distant ground and road textures sharp; with the longer draw distance there is a lot more of both in view.
A mission/level-load crash in the tested GOG build by applying a narrowly targeted heap-compatibility workaround to i82sim.dll.
Keyboard controls that are dead in missions. DirectInput takes the names of the keyboard, the mouse and every key from Windows' language files, so on a German system it reports "Tastatur", "Maus" and "Leertaste". I82 finds each bound key by device name and key name, and its default bindings (bindings.def, inside i82.zfs) use "Keyboard" and English key names. With anything else the menus still work, but every in-mission action "does not exist". The proxy reports the system keyboard and mouse as "Keyboard" and "Mouse", and every key by its canonical English DirectInput name, whatever the Windows language.
A game that never opens a window on current Windows 11. GOG replaced the game's CD audio with its own winmm.dll ("ogg-winmm"), which plays the soundtrack from MUSIC\TrackNN.ogg. It passes every other function on to Windows' winmm.dll through the relative path system32\\winmm, and on recent builds (seen on 10.0.26200) resolving that path hangs before the game's first line of code runs. This patch includes its own winmm.dll that replaces GOG's: it loads Windows' winmm.dll by full path and passes everything on to it.
A soundtrack that is silent on many systems, and sound effects that cannot be heard while it plays. Where Windows applies compatibility fixes to i82stubz.exe, the game gets Windows' winmm.dll, and GOG's music DLL is never used. Where it does play, it streams through waveOut, and in testing the effects, which Miles plays through DirectSound, could not be heard next to it. The patch's winmm.dll answers the game's CD-audio commands the way GOG's did and plays the same OGG tracks through DirectSound, using the Vorbis DLLs of the GOG installation. Where the game has been given Windows' winmm.dll, dinput.dll loads the patch's winmm.dll next to it and points the game's CD-audio calls at it.
The same soundtrack in every campaign mission. Each mission names its own track, but right after starting it the game asks the CD for its current position, stops and plays on from there. GOG's DLL answered that question with 0, and "play from 0" fell back to the first track, so after two seconds every mission played Track02. The patch's keeps track of the play position and resumes the right track.
The shim no longer hardcodes any address inside i82sim.dll, but it has only been developed and validated against the tested GOG release. Do not assume it is correct for a different release, executable, mod, or language build without checking it first.
Back up the game directory.
Download DDrawCompat upstream and copy its ddraw.dll next to i82stubz.exe.
Download the ZIP from the latest release and extract it into the game directory, next to i82stubz.exe; confirm replacing winmm.dll. It contains a README.txt with these steps, dinput.dll, winmm.dll, the DDrawCompat profile DDrawCompat-i82stubz.ini and the optional draw-distance tool patch_viewdistance.exe. SHA256SUMS.txt in the release lets you verify the ZIP and every file in it. If you would rather not run prebuilt binaries, build the DLLs and the tool yourself (see Build); the profile is also in this repository.
Select the resolution in the game under Options → Graphics. The profile lists 1920x1080 and 3840x2160 under SupportedResolutions. DDrawCompat's default already includes every mode your display reports (native), so on most systems the line changes nothing. It keeps both modes available on a display that does not report them, and DDrawCompat then scales them to the desktop.
The .def files are only needed to build the DLLs; they do not need to be copied to the game directory.
Start i82stubz.exe normally. No DxWnd launcher is required.
Upgrading from an earlier version: extract the ZIP over the old files. An i82patch.ini from v1.7 and an ogg-winmm.dll left over from v1.4 are no longer needed and can be deleted. If you have edited your profile, keep your copy instead of the one in the ZIP and make sure it has the lines GdiInterops = none and TextureFilter = af16x. If you use the draw-distance patch, run the new patch_viewdistance.exe once; it now gives every level 3x. The dinput_orig.dll that versions before 1.3 needed can stay or be deleted. If it is there, the shim still uses it. Up to v1.3.2 the shim reported the keyboard without a name, so a bindings.usr saved from the Controls screen with those versions names its device "". On the first start v1.3.3 changes those entries to "Keyboard" and keeps the old file as bindings.usr.before-v1.3.3. Your key assignments stay as they were.
The included DDrawCompat profile deliberately uses FullscreenMode = borderless, not exclusive fullscreen. It was the stable, confirmed mode for this setup.
Build with a 32-bit MinGW-w64 GCC toolchain. In an MSYS2 MinGW32 shell:
gcc -shared -s -Wl,--enable-stdcall-fixup -o dinput.dll dinput.c dinput.def
gcc -O2 -shared -s -Wl,--enable-stdcall-fixup -o winmm.dll winmm.c winmm.def
winmm.def and winmm_thunks.h are generated from Windows' 32-bit winmm.dll by python tools/gen_winmm.py; the generated files are in the repository.
The shim loads the real DirectInput itself: a dinput_orig.dll next to the game if one is there, otherwise the system's dinput.dll. The game is a 32-bit process, so Windows serves the 32-bit DLL from SysWOW64. All DirectInput exports the shim does not change are passed straight through to it.
The optional draw-distance tool builds the same way, as a plain console program:
gcc -O2 -s -o patch_viewdistance.exe patch_viewdistance.c
i82sim.dll and I82ShellDll.dll: the accepted 1280x1024 pair becomes 1920x1080, and 1024x768 becomes 3840x2160 on a desktop that can show it. The site is located by matching the instruction shape, not a fixed address; the height compare of the second slot is reached by following the filter's own branch rather than by searching nearby, and nothing is written unless every part matches.LoadLibrary call is in progress, and it keeps retrying until a scan actually matches instead of assuming the first attempt saw real code. A module counts as patched only while the patched bytes are still there, so a module the game unloads and loads again, as it does on "Restart Mission", is patched again.HeapSize, HeapReAlloc and HeapFree in i82sim.dll; the LoadLibrary family in i82stubz.exe, so the heap hooks are in place the moment the module is mapped rather than a poll interval later; and MessageBoxA in i82sim.dll and I82ShellDll.dll.i82sim.dll: the distance limits of those two tests are read from a value inside dinput.dll instead of the game's own constants, which stay untouched. Each site is found by its instruction pattern, and nothing is written unless the whole pattern matches.i82sim.dll: the size of the per-frame vertex buffer and of the batch list (its allocation, the count kept in front of it and the count it is built with). Both sites are found by their instruction pattern, and nothing is written unless the whole pattern matches.i82sim.dll's camera code -- the ones that save tan(fov/2) when the camera is set up and when its field of view changes -- with calls to a few instructions of its own that scale the value for viewports wider than 4:3 before storing it. The field of view itself keeps its value.i82sim.dll from two threads, the one loading the game's modules and a backstop poll; a lock keeps the two from ever patching at the same time.The game's camera keeps a 90-degree horizontal field of view whatever the shape of the screen. On 16:9 that would mean less picture at the top and bottom than on 4:3: the chase view sits closer, and the back of the car touches the lower edge. The shim widens the horizontal view instead, so 16:9 shows the same height as 4:3 plus more to the sides. 4:3 and 5:4 are not affected.
In v1.7 and v1.7.1 this was optional and off by default, because the wider view puts about a third more of the world in sight and made the missing-car problem and the Restart Mission crash in busy levels more likely. With the render batch limits raised (see What it fixes) neither happened in testing, so from v1.8 it is always on and i82patch.ini is gone.
patch_viewdistance.exe is a separate, optional tool and not needed to play — it edits the game's own level data to draw the world further out. Use it together with this patch's dinput.dll, version 1.8 or later: the longer view relies on its larger render buffers. The same tool is also available as a Python script, patch_viewdistance.py; both produce byte-identical results.
Interstate '82 stores a World_Data block per level as plain text inside i82.zfs, and i82perf.ini's Far_Clipping_Plane = 2 is already the highest setting the game offers. The real values are there:
Fog_Max: 200.00
Clipping_Plane: 200
The two are equal on purpose: the fog is what hides the edge where the world stops being drawn. Raising the clipping plane alone would only move the pop-in into a fog bank, so the tool scales both, with separate factors. Because Fog_Alpha is 128 the fog never becomes fully opaque, so geometry past Fog_Max still reads as a silhouette — pushing the clipping plane further than the fog adds depth instead of drawing something invisible. Hence the defaults: clipping 3x, fog 2x.
Every level gets the same factors. Up to v1.7.1 seven levels were held at 2x, because at 3x the player's own car was sometimes not drawn at the start, on the golf course at about one start in eight (7 of 60). The cause was the game's per-frame render limits, which dinput.dll now raises (see What it fixes). With v1.8, at 3x and with Hor+, the car was there at every start checked on those levels: 40 on the golf course, 10 each on Area 49 Surface, Action Mall and the campaign missions into Area 49 and the sewers, 5 on the way to the hospital, and the first training level in play.
With the higher screen resolution, cars switching to their coarse models in the distance become obvious too. Each car model holds three detail levels, and the game picks one by distance. The tool points the two distant levels at the detailed model, so every car keeps its full detail at any range: two 2-byte fields per model in 43 models, nothing moved. Wheels and weapons switch in the game's code instead; dinput.dll takes care of those, with or without this tool.
On the machine this was developed against it cost nothing measurable — 107 fps at 3840x2160, against 100 before. The engine is not limited by geometry here; the short view distance was a decision for 1999 hardware.
The simple way: download patch_viewdistance.exe from the latest release, put it in the game folder next to i82.zfs, and double-click it. It applies clipping 3x and fog 2x and shows what it changed. Double-clicking it again offers to put the original draw distance back. You can also drop i82.zfs onto it wherever the program is. Windows may warn about an unrecognized program the first time, because the exe is not code-signed; the source is patch_viewdistance.c in this repository.
From a command prompt it takes options:
patch_viewdistance.exe --dry-run # show what would change
patch_viewdistance.exe --clip 4 --fog 2.5 # other factors
patch_viewdistance.exe --restore # undo
patch_viewdistance.exe "D:\Games\Interstate 82" # another game folder
With Python installed, the script does the same. Note that it only shows what would change unless you pass --apply:
python patch_viewdistance.py # show what would change
python patch_viewdistance.py --apply # clipping 3x, fog 2x
python patch_viewdistance.py --clip 4 --fog 2.5 --apply
python patch_viewdistance.py --restore # undo
Either way, it edits your installed i82.zfs. Before the first change it keeps an untouched copy as i82.zfs.original beside it and always computes from that copy, so different factors never compound and --restore always works. Values live in fixed-width fields, so each is rewritten to the same byte length: every offset in the archive stays valid and nothing is repacked. The exe finds the archive next to itself, in the current folder or in the default GOG location; the script looks in the default GOG location. Pass --game with your installation folder to either of them otherwise. Close the game before running it. Start a mission to see the difference — the menu shows nothing of it.
The tool ships no game data and redistributes nothing; it changes files you already own.
The game does not start: no window and no error, but i82stubz.exe is in Task Manager.
GOG's own winmm.dll is in the game directory instead of the one from this patch. End every i82stubz.exe in Task Manager, since each attempt adds another hung process, then copy the patch's winmm.dll into the game directory again. "Verify / Repair" in GOG Galaxy puts GOG's file back.
No music, or no sound effects while the music plays.
Fixed in v1.5. Check that the patch's winmm.dll and dinput.dll are in the game directory. The music also needs libvorbisfile-3.dll, libvorbis-0.dll, libogg-0.dll and the MUSIC folder there, all part of the GOG installation.
"Where is shell dll?" followed by "Shell Error!" on startup, and the game quits.
An overlay is hooking the process as it launches. RivaTuner Statistics Server (RTSS, shipped with MSI Afterburner) does this reliably: with RTSS already running, the game dies before its menu module is ever loaded — first with an access violation in RTSSHooks.dll in the Windows application log, later with no crash entry at all, because the game bails out through its own error path first. It happens with any dinput.dll, including none, so it is easy to mistake for a problem with this shim.
Either start the game first and RTSS afterwards, which works because injecting into a running process does not disturb it, or give i82stubz.exe a profile in RTSS with Application detection level set to None. Other overlays that inject at process start are worth ruling out the same way. When a startup failure makes no sense, check the Windows application log for a foreign module before suspecting anything else.
The graphics options offer neither 1920x1080 nor 3840x2160.
The game's own filter allows only its four original modes, and the shim widens it, so check first that dinput.dll is in the game folder next to i82stubz.exe. 3840x2160 is only offered on a desktop of at least 3840x2160. If your display does not report 1920x1080 or 3840x2160 itself, DDrawCompat offers them only as listed under SupportedResolutions in the profile, so also check that the profile is there and named after the executable (DDrawCompat-i82stubz.ini).
The keyboard works in the menus but does nothing in a mission, and dinput_msgbox.log lists "Control Accelerate does not exist" and the like for every action.
Fixed in v1.3.3; update dinput.dll. The message is misleading: the action exists, but the key it is bound to does not. I82 looks up each binding by device name and key name, and its default bindings name the device "Keyboard". Up to v1.3.2 the shim reported the keyboard without a name, so on an install without a bindings.usr of its own no key was bound. It only worked where every key had been bound again by hand in the Controls screen, which saves the empty name the game saw. v1.3.3 reports the keyboard as "Keyboard" and converts such a saved bindings.usr once, as described under Installation.
Crash to the desktop when leaving or restarting a mission.
Fixed in v1.3.2: the included DDrawCompat-i82stubz.ini now sets GdiInterops = none, so update that file. While the game rebuilds its display surfaces, which happens on mission exit and restart, DDrawCompat presents from a copy of the whole virtual desktop. On a large or multi-monitor desktop that copy is big enough that allocating it can fail inside the 32-bit game, and the game then crashes in the graphics driver. The game does not appear to need GDI interop, so it can do without that copy. DDrawCompat's author tracked this down in narzoul/DDrawCompat#625. In testing on a two-display setup there were no crashes in 36 mission starts and restarts with the setting. Without it, about one in five crashed. On a single display the copy is smaller and the crash is probably rarer, and the setting should not hurt there. Alt+Tab goes through the same path, but was not tested separately with this setting. If Alt+Tab still crashes, see the next entry.
Crash on Alt+Tab, or cars briefly vanish after you Alt+Tab back into the game.
Add this line to DDrawCompat-i82stubz.ini:
AltTabFix = keepvidmem(1)
It stops the game from losing its video memory when it goes to the background, so it has nothing to rebuild when it returns. Without GdiInterops = none, it removed the Alt+Tab crash in testing, which otherwise came within three to five Alt+Tabs in a mission. It is not in the included profile because it has only been tested on one machine.
"Display Error: Interstate 82 is unable to set your chosen screen resolution" after "Restart Mission", followed by "World Init failed" and a loop of error messages.
Fixed in v1.3.1; update dinput.dll. "Restart Mission" unloads the game's mission module and loads it again, usually at the same address, and earlier versions sometimes missed that and left the fresh copy at the game's original four resolutions. If you get stuck in the loop on an older version, the dialogs sit behind the fullscreen window: press Ctrl+Alt+Del and end i82stubz.exe in Task Manager, or sign out if Task Manager opens behind the game as well.
This project was made with an AI coding assistant, Claude by Anthropic, and the assistant did most of the hands-on work:
patch_viewdistance;The maintainer (SputnikKaputtnik) sets the goals and plays the game on real hardware. That covers the checks no script can do, such as listening for music and sound effects or spotting a missing car. The maintainer also decides the trade-offs, for example 3x draw distance on every level and Hor+ as the default, and approves every merge, release and post. Each release ships the exact binaries that were tested.
Commits written with the assistant carry a Co-Authored-By: Claude line. Posts under the maintainer's account, here and on other sites, are usually drafted with it as well.
For you this means: the source is complete and short enough to read, and the behaviour described here was tested on the maintainer's two Windows 11 PCs, a gaming machine with a dedicated GPU and a laptop. No second human developer has reviewed it. Bug reports and reviews are welcome.
winmm.c is based on ogg-winmm by Toni Spets (ISC license; the notice is in winmm.c), which GOG's release uses as well.The shim source and configuration in this repository are available under the MIT License.
winmm.dllA music volume slider that does nothing. Miles, the game's sound library, sets the CD volume on a mixer's compact-disc line whenever Windows reports one, and many audio drivers still do; the slider then moved a mixer control that has nothing to do with the soundtrack, which played at full volume. The patch's winmm.dll reports no such line, so Miles uses the CD device's own volume, and the slider works again. The setting takes effect when a mission starts; the menus play no music.
A crash on "Restart Mission" in busy levels, and a player's car missing at the start of a level. Every frame the game sorts what is in view into batches, with room for 1536 batch entries and vertices for 1706 batches. The entry count is never checked, so in a busy scene the game writes past the end of its list and damages the heap, which crashed it on the next restart — reliably in Vegas. When the vertex space runs out, the rest of the frame is simply not drawn, and the player's car comes late in that order: its body went missing while its lights and gun still showed. A longer draw distance and a wider field of view put more in view, so both happened more often. The shim gives the game four times the vertex space and room for 8192 entries, so the vertex check, which the game does have, always comes first; in testing neither limit was reached.
Wheels and weapons that pop in at a distance. They are separate models, and the game simplifies them by distance: the wheels turn into flat sprites beyond 20 m, and the weapons drop to their simple form beyond 50 m at the highest "Cars" detail setting. With the original short view that was hidden in the fog; with a longer draw distance it is plain to see. The shim lifts both limits.
Modal developer diagnostics from the input system (CInputBinding::bindControl and its siblings). One appears between the menu and the load screen on every mission start and has to be dismissed by hand, although it reports a condition a player cannot act on. They are answered automatically and written to dinput_msgbox.log instead.
The absence of any widescreen resolution. I82 accepts only four hardcoded modes (640x480, 800x600, 1024x768, 1280x1024), so no configuration file can produce a 16:9 frame. The shim widens that filter to offer 1920x1080 in place of 1280x1024, and 3840x2160 in place of 1024x768. The engine renders the wider frame natively, without stretching; the HUD moves to the screen edges and scales with the resolution. On its own the engine keeps its horizontal field of view, so a 16:9 frame would show less at the top and bottom than 4:3; the shim turns that into Hor+ (see Hor+ field of view).
The 4K slot is only taken on a desktop that is at least 3840x2160; below that, 1024x768 is left alone rather than traded for a mode the monitor cannot show. 640x480 and 800x600 are never touched — the game's width dispatch tests ">800" first, so only the two upper slots can hold a widescreen mode.
CInput are suppressed. Everything else is passed through untouched.winmm.dll implements mciSendCommandA, mciSendStringA and the four aux volume functions for the CD audio, following GOG's ogg-winmm, plus mixerGetLineInfoA, which reports no compact-disc line and answers every other query from Windows. It passes the other 186 functions on to Windows' winmm.dll, which it loads by full path. It reads only MUSIC\TrackNN.ogg and loads libvorbisfile-3.dll from the game directory, and it writes nothing.winmm.dll, dinput.dll loads the winmm.dll from the game directory and points the imports of those six functions and mixerGetLineInfoA in mss32.dll and I82ShellDll.dll at it. If that is still GOG's music DLL, it also serves its six waveOut imports from a DirectSound stream.dinput_msgbox.log is written only when such a popup is suppressed. bindings.usr is rewritten once, and only if it still has device names left empty by v1.3.2 or earlier; the old file is kept as bindings.usr.before-v1.3.3. There is no telemetry, no registry access and no background diagnostics.dinput.dll, ddraw.dll, DDrawCompat-i82stubz.ini and, if an older version left one, dinput_orig.dll, and put GOG's winmm.dll back from your backup or with "Verify / Repair" in GOG Galaxy. Restore any other files from your backup if they existed before installation.