2
<p>hopefully I can just patch it to load DAT2 instead. That might break if it needs to use DAT1 resources first... I don&#39;t THINK it does? but I&#39;m not sure.</p>
<p>ahh, I forgot the implicit state.<br />I&#39;m injecting into the game when it first tries to load the title screen, which it does before it loads DAT2,DAT3,DAT5</p>
<p><span class="h-card" translate="no"><a href="https://mastodon.social/@gamingonlinux" class="u-url mention">@<span>gamingonlinux</span></a></span> A good alternative, at least for my usage is the Pegasus Frontend. I installed it on my Debian &quot;Gamestation&quot; that I use for small Couch-Coop or Party games.<br />It may not do the exact same thing but I manage all my games with it...😁</p><p><a href="https://pegasus-frontend.org/" target="_blank" rel="nofollow noopener" translate="no"><span class="invisible">https://</span><span class="">pegasus-frontend.org/</span><span class="invisible"></span></a></p>
<p>TO THE DEBUGGER, BATMAN!</p>
<p>it worked successfully so of course as soon as I try it on DAT2, it starts hanging.</p>
<p>(that&#39;s why the filenames are a full 8.3 characters, so I can overwrite them with any valid DOS name)</p>
<p>but since I didn&#39;t want to deal with writing code to parse the size and filenames and shit from the command line, I just have my script write a new EXE per chunk.<br />It just takes the old EXE, applies patches over where size, &quot;internal.ext&quot;, and &quot;12345678.ext&quot; are in the EXE, then it runs that new EXE</p>
<p>then I compile that and I wrote a tiny python script to inject it into the EXE (by just copying the old EXE and pasting my shit in at an offset), and then I call that EXE once per chunk.</p><p>well, I call a dosbox-x exe with a conf set to just run it and then exit.</p>
<p>so I hacked the game like this:</p><p>I wrote a little assembly program that basically just goes:<br />unsigned short size=64020;<br />ptr=loadChunk(&quot;internal.ext&quot;);<br />f=fopen(&quot;12345678.ext&quot;,&quot;wb&quot;);<br />fwrite(ptr,size,1,f);<br />fclose(f);<br />exit(0);</p>