D2S/Item parser in progress. Still need to debug cubemain.txt doc generator output colulmns. Saving code for now

This commit is contained in:
Hash Borgir
2022-06-20 19:27:08 -06:00
parent 521dfe12c6
commit 822e3dcbd8
19 changed files with 482 additions and 1242 deletions

View File

@@ -41,9 +41,9 @@ $filePath = str_replace("\\", "\\\\", $filePath);
$fp = fopen($filePath, "rb+");
// delete old checksum at offset 0x0C - byte 12
fseek($fp, 12);
//fseek($fp, 12);
// (I) unsigned integer (machine dependent size and byte order)
fwrite($fp, pack('I', 0)); // produces 4 bytes
//fwrite($fp, pack('I', 0)); // produces 4 bytes
// edit quests which are checked, to Just finished FE FF
foreach ($q as $k => $v) {
@@ -128,9 +128,9 @@ if ($p['wp_all'] == "1") {
$checksum = (shell_exec("bin\d2scs.exe \"$filePath\""));
// write NEW checksum at offset 0x0C - byte 12
fseek($fp, 12);
//fseek($fp, 12);
// (I) unsigned integer (machine dependent size and byte order)
fwrite($fp, pack('H*', $checksum)); // produces 4 bytes
//fwrite($fp, pack('H*', $checksum)); // produces 4 bytes
fclose($fp);