![]() ![]() The order would be the one the game places them though, so disregarding the fact that some section might be missing for some items the order should NEVER be another than the one I list below.ģ2 flags, ptItemstats is I will thus not give offsetts but rather the number of bits (in decimal notation) something is saved in. In addition, what actually is saved varies with the item type and so on. Since items are saved in a very compressed way on bit levels (and not bytes). I will not at all handle that here but only the case for actually saving an item. It has the ability to mask many properties in such cases for non identified items for example when you gamble I would guess. Note that the same function that compress an item for saving seems to be used to compress items for sending between server and client. It is a quite variable content depending on the item and also quite large. Next to be added is detailed info on the data for each item saved in a list. +03 if an Iron Golem eixts the item used to create it will follow here +02 0 or 1 (b), a 1 indictaing an Iron Golem exists +06 List of items (only exists if you actually have a mercenary) +04 number of items in list (only exists if you actuall have a mercenary) +02 "JM" (only exists if you actually have a mercenary) +00 "jf" (only exists if expansion game regardless of if you have a mercenary or not) Next follows a normal list of items if a corpse existed. In any case, thsoe 12 bytes can be ignored. I guess the first value was once which map the coprse was on or something. None of the three values are read by the code by the way. The next two values are x and y coordinates (not sure if they actually make any sense though). The first value is actually set from an uninitialized local variable and can thus be anything that happens to sit on the stack. ![]() If the corpse exists there follow 4 dwords of random data. The "number of corpses" can only be set to 0 or 1 and can thus be thought of as a flag for the existance of a corpse. Currently, only one corpse is supported though. The game obviously have had the ability to save several corpses for a character. This includes all items your character have, including those in the stash. The various lists (of which not all need to be present) are: Socketed items follow right after the item they are socketed into and are not counted in the list header for number of items in the list. Next follow each item itself and I think most (all?) of them will start of with the "JM" string (yes confusing since it is used in two different cases so to speak) followed by item specific data. A list will usually contain a header that has a two byte "string", for example "JM" (I would say many of those strings you find are actually short for various programmer names) followed by a word indicating the number of items in the list to follow. The item info is mostly made up of various lists of items. +0301 stats (dw) indicated by bitfield, from hUnit +02ff bitfield indicating which of the 16 main stats follow Next follow various sections of information. That concludes the main header of the save file. just make sure you load it properly too :) These bytes can be used for your own custom saved information. +00b7 ebx+04, then subtract, should be from mercenary txt +00af flags, only 00100000 seems to be in use set if 6fcad880 returns non 0 +00af start of mercenary info, much comes from 6fc71c10 (as ebx+xx), needs checking anyway: +00ab from, should be initial seed of game Of the three values above, 2 will be 0 the other will be the actual value with bit 7 set to indicate which difficulty is saved +00a9 act playing in nightmare difficulty +0088 16 2-byte values (could be 8 4-byte values) set by d2common.283a, seems to relate to appearance of items/character +0078 8 2-byte values, supposedly skills assigned to mouse buttons +0038 32 2-byte values, supposedly skills assigned to function keys ![]() +0028 character class from b, hopefully matches that of hUnit :) +0027 empty filler to the 2 previous bytes, 0 +0026 empty filler to the 2 previous bytes, 0 (+0024 and +0025 is actually returned as a word from w +0025 acts done (see link in post below for more info) +0024 flags from b, bit 5 (of 0-7) is set by SAVE code if expansion game Note that individual items ALSO has the JM ID as do the Mercenary section if you have one. "kf", Iron Golem list (expansion char only) "jf", Mercenary section (expansion char only) Note the header's ID is actually a file ID, but you get the idea :) Code: Select all Summary of the various sections.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |