-
Filepack Fun, Itemdata
I'm having more absolutely lovely fun with the filepack format not doing what I tell it to do.
This time, it;s with the itemdata struct, and aye, I did feed it specific version information, and I did bump V_ITEMS.
Does anyone want to have a look at this?
https://github.com/ZoriaRPG/ZeldaCla...ee/ItemdataExp
The key files are:
qst.cpp, zfdefs.h, zq_class.cpp
The affected functions are readitems() and writeitems().
I commented out the sections that I was adding, and you can search for the string:
//! I need help with this.
to quickly find them.
The ZScript side of this is fine, and the jwin side seems to also be fine. I tried to create a debug build, but MSVC crashes outright when I do that.
Here is what happens when I try to build for debug.
Code:
2>LINK : fatal error LNK1000: Internal error during IncrBuildImage
2> Version 9.00.21022.08
2> ExceptionCode = C0000005
2> ExceptionFlags = 00000000
2> ExceptionAddress = 4C003FC0
2> NumberParameters = 00000002
2> ExceptionInformation[ 0] = 00000008
2> ExceptionInformation[ 1] = 4C003FC0
2>CONTEXT:
2> Eax = 4C003FC0 Esp = 003AEE10
2> Ebx = 40008184 Ebp = 003AEE3C
2> Ecx = 00DED670 Esi = 4064510C
2> Edx = 003AEE2C Edi = 00EFD6C0
2> Eip = 4C003FC0 EFlags = 00010246
2> SegCs = 00000023 SegDs = 0000002B
2> SegSs = 0000002B SegEs = 0000002B
2> SegFs = 00000053 SegGs = 0000002B
2> Dr0 = 00000000 Dr3 = 00000000
2> Dr1 = 00000000 Dr6 = 00000000
Full MVSC log
-
I gave you some tips on Skype, but I'll post here as well to help others:
1. You have to read and write data in exactly the same order in qst.cpp and zq_class.cpp.
2. You must use a consistent pair of read and write commands. You cannot write a 8-bit char and try to read it in as a 32-bit integer.
Please be extremely careful when making changes anywhere near the quest loading and saving code. Errors here cause quest corruption, which in the worse case goes undetected for several betas, and can cause quest authors to lose weeks or months of work.
-
Solved. Thank you <!-- BEGIN TEMPLATE: dbtech_usertag_mention -->
@<a href="http://www.armageddongames.net/member.php?u=1" target="_blank">DarkDragon</a>
<!-- END TEMPLATE: dbtech_usertag_mention --> for proving that I'm a blind idiot.
For future reference, don't try storing char and loading long.
https://youtu.be/TvsFDoriKV4
We will merge this soon. For the present, it is in this branch:
https://github.com/ZoriaRPG/ZeldaCla...taWeaponEditor