Daeros_Trollkiller Posted July 20, 2020 Share Posted July 20, 2020 (edited) I am working on one of my mods which is cross-compatible with BGEE and BG2EE and running into an annoing issue: I get an illegal 2-byte read error when I run the below on a clean install of BGEE w SoD (modmerge already done) COPY_EXISTING_REGEXP GLOB ~^.+\.spl$~ ~override~ READ_LONG 0x08 name READ_SHORT 0x98 ~proj~ The problem occurs when it tries to read 0x98 from: cddetect.spl. I checked the file in NI, and it appears that this was intended to be an ITM file as it has that signature so, I am fairly positive the file itself is the culprit, but I haven't been able to find a way to work around it. Would appreciate any advice here. Edited July 20, 2020 by Daeros_Trollkiller resolved Quote Link to comment
Magus Posted July 20, 2020 Share Posted July 20, 2020 Check SOURCE_SIZE or signature. Quote Link to comment
Daeros_Trollkiller Posted July 20, 2020 Author Share Posted July 20, 2020 (edited) 1 hour ago, qwerty1234567 said: Check SOURCE_SIZE or signature. Thank you for the quick response! Would the check look something like this? Answered my own question, the below does indeed work. Thank you! COPY_EXISTING_REGEXP GLOB ~^.+\.spl$~ ~override~ READ_ASCII 0x0 sg (4) //Signature PATCH_IF (~%sg%~ STRING_EQUAL_CASE ~SPL ~ = 1) BEGIN Edited July 20, 2020 by Daeros_Trollkiller Quote Link to comment
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.