Commit 709d1963d726beafd70f51a51c8f9798622c03e5

Authored by Imanol-Mikel Barba Sabariego
1 parent 24639c04

Fixed stat calculation. Started adding some item identifiers

d2stat.c
... ... @@ -3,26 +3,23 @@
3 3 #include <stdio.h>
4 4 #include <string.h>
5 5  
  6 +#define readBits(data, start, size) ((*((uint64_t*) &data[(start) / 8]) >> ((start) & 7)) & ((1 << (size)) - 1))
  7 +
6 8 // Internal function, gives the offset ***IN BITS, NOT BYTES*** of the specified stat
7 9 unsigned long long int _searchStat(D2S_STAT stat, void* charData, size_t dataLen) {
8 10 if(!strncmp(charData, D2S_STAT_HEADER, D2S_STAT_HEADER_LENGTH)) {
9 11 fprintf(stderr,"libd2char error: Stat header not present in charData\n");
10 12 return 0;
11 13 }
12   - unsigned long long int byteOffset = D2S_STAT_HEADER_LENGTH;
13   - unsigned long long int bitOffset = 0;
14   - while(byteOffset < dataLen) {
15   - uint16_t statID = 0;
16   - memcpy(&statID, charData + byteOffset, sizeof(statID));
17   - statID >>= bitOffset;
18   - statID &= 0x1FF;
  14 + unsigned long long int offset = D2S_STAT_HEADER_LENGTH * 8;
  15 + while(offset < (dataLen * 8)) {
  16 + uint64_t statID = readBits(charData, offset, D2S_STAT_IDENTIFIER_BIT_LENGTH);
19 17 if(statID == D2S_STAT_FOOTER) {
20 18 break;
21 19 } else if(statID == stat) {
22   - return (byteOffset * 8) + bitOffset;
  20 + return offset + D2S_STAT_IDENTIFIER_BIT_LENGTH;
23 21 }
24   - byteOffset += statCost[statID] / 8;
25   - bitOffset += statCost[statID] % 8;
  22 + offset += D2S_STAT_IDENTIFIER_BIT_LENGTH + statCost[statID];
26 23 }
27 24 return 0;
28 25 }
... ... @@ -33,10 +30,7 @@ int getStat(D2S_STAT stat, unsigned int* value, void* charData, size_t dataLen)
33 30 fprintf(stderr,"libd2char error: Unable to find attribute: %d\n", stat);
34 31 return -1;
35 32 }
36   - uint64_t statValue = 0;
37   - memcpy(&statValue, charData + (statOffset / 8), sizeof(statValue));
38   - statValue >>= (statOffset % 8);
39   - statValue &= statCostMask[stat];
  33 + uint64_t statValue = readBits(charData, statOffset, statCost[stat]);
40 34 *value = (unsigned int)statValue;
41 35 return 0;
42 36 }
... ...
d2stat.h
... ... @@ -7,6 +7,7 @@
7 7 #define D2S_STAT_HEADER "gf"
8 8 #define D2S_STAT_HEADER_LENGTH 2
9 9 #define D2S_STAT_FOOTER 0x1FF
  10 +#define D2S_STAT_IDENTIFIER_BIT_LENGTH 9
10 11  
11 12 typedef enum D2S_STAT {
12 13 D2S_STAT_STRENGTH = 0x00,
... ...
d2strings.h
... ... @@ -1045,4 +1045,646 @@ const char* D2S_CHARPROGRESS_EXPANSION_TIER3_NAME_HARDCORE = &quot;Guardian&quot;;
1045 1045 #define D2S_WAYPOINT_37 "The Ancient's Way"
1046 1046 #define D2S_WAYPOINT_38 "Worldstone Keep Level 2"
1047 1047  
  1048 +// Item identifiers
  1049 +#define D2S_ITEMDATA_IDENTIFIER_CAP "cap "
  1050 +#define D2S_ITEMDATA_IDENTIFIER_WAR_HAT "xap "
  1051 +#define D2S_ITEMDATA_IDENTIFIER_SHAKO "uap "
  1052 +#define D2S_ITEMDATA_IDENTIFIER_SKULL_CAP "skp "
  1053 +#define D2S_ITEMDATA_IDENTIFIER_SALLET "xkp "
  1054 +#define D2S_ITEMDATA_IDENTIFIER_HYDRASKULL "ukp "
  1055 +#define D2S_ITEMDATA_IDENTIFIER_HELM "hlm "
  1056 +#define D2S_ITEMDATA_IDENTIFIER_CASQUE "xlm "
  1057 +#define D2S_ITEMDATA_IDENTIFIER_ARMET "ulm "
  1058 +#define D2S_ITEMDATA_IDENTIFIER_FULL_HELM "fhl "
  1059 +#define D2S_ITEMDATA_IDENTIFIER_BASINET "xhl "
  1060 +#define D2S_ITEMDATA_IDENTIFIER_GIANT_CONCH "uhl "
  1061 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_HELM "ghm "
  1062 +#define D2S_ITEMDATA_IDENTIFIER_WINGED_HELM "xhm "
  1063 +#define D2S_ITEMDATA_IDENTIFIER_SPIRED_HELM "uhm "
  1064 +#define D2S_ITEMDATA_IDENTIFIER_CROWN "crn "
  1065 +#define D2S_ITEMDATA_IDENTIFIER_GRAND_CROWN "xrn "
  1066 +#define D2S_ITEMDATA_IDENTIFIER_CORONA "urn "
  1067 +#define D2S_ITEMDATA_IDENTIFIER_MASK "msk "
  1068 +#define D2S_ITEMDATA_IDENTIFIER_DEATH_MASK "xsk "
  1069 +#define D2S_ITEMDATA_IDENTIFIER_DEMONHEAD "usk "
  1070 +#define D2S_ITEMDATA_IDENTIFIER_BONE_HELM "bhm "
  1071 +#define D2S_ITEMDATA_IDENTIFIER_GRIM_HELM "xh9 "
  1072 +#define D2S_ITEMDATA_IDENTIFIER_BONE_VISAGE "uh9 "
  1073 +#define D2S_ITEMDATA_IDENTIFIER_QUILTED_ARMOR "qui "
  1074 +#define D2S_ITEMDATA_IDENTIFIER_GHOST_ARMOR "xui "
  1075 +#define D2S_ITEMDATA_IDENTIFIER_DUSK_SHROUD "uui "
  1076 +#define D2S_ITEMDATA_IDENTIFIER_LEATHER_ARMOR "lea "
  1077 +#define D2S_ITEMDATA_IDENTIFIER_SERPENTSKIN "xea "
  1078 +#define D2S_ITEMDATA_IDENTIFIER_WYRMHIDE "uea "
  1079 +#define D2S_ITEMDATA_IDENTIFIER_HARD_LEATHER "hla "
  1080 +#define D2S_ITEMDATA_IDENTIFIER_DEMONHIDE_ARMOR "xla "
  1081 +#define D2S_ITEMDATA_IDENTIFIER_SCARAB_HUSK "ula "
  1082 +#define D2S_ITEMDATA_IDENTIFIER_STUDDED_LEATHER "stu "
  1083 +#define D2S_ITEMDATA_IDENTIFIER_TRELLISED_ARMOR "xtu "
  1084 +#define D2S_ITEMDATA_IDENTIFIER_WIRE_FLEECE "utu "
  1085 +#define D2S_ITEMDATA_IDENTIFIER_RING_MAIL "rng "
  1086 +#define D2S_ITEMDATA_IDENTIFIER_LINKED_MAIL "xng "
  1087 +#define D2S_ITEMDATA_IDENTIFIER_DIAMOND_MAIL "ung "
  1088 +#define D2S_ITEMDATA_IDENTIFIER_SCALE_MAIL "scl "
  1089 +#define D2S_ITEMDATA_IDENTIFIER_TIGULATED_MAIL "xcl "
  1090 +#define D2S_ITEMDATA_IDENTIFIER_LORICATED_MAIL "ucl "
  1091 +#define D2S_ITEMDATA_IDENTIFIER_CHAIN_MAIL "chn "
  1092 +#define D2S_ITEMDATA_IDENTIFIER_MESH_ARMOR "xhn "
  1093 +#define D2S_ITEMDATA_IDENTIFIER_BONEWEAVE "uhn "
  1094 +#define D2S_ITEMDATA_IDENTIFIER_BREAST_PLATE "brs "
  1095 +#define D2S_ITEMDATA_IDENTIFIER_CUIRASS "xrs "
  1096 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_HAUBERK "urs "
  1097 +#define D2S_ITEMDATA_IDENTIFIER_SPLINT_MAIL "spl "
  1098 +#define D2S_ITEMDATA_IDENTIFIER_RUSSET_ARMOR "xpl "
  1099 +#define D2S_ITEMDATA_IDENTIFIER_BALROG_SKIN "upl "
  1100 +#define D2S_ITEMDATA_IDENTIFIER_PLATE_MAIL "plt "
  1101 +#define D2S_ITEMDATA_IDENTIFIER_TEMPLAR_COAT "xlt "
  1102 +#define D2S_ITEMDATA_IDENTIFIER_HELLFORGE_PLATE "ult "
  1103 +#define D2S_ITEMDATA_IDENTIFIER_FIELD_PLATE "fld "
  1104 +#define D2S_ITEMDATA_IDENTIFIER_SHARKTOOTH "xld "
  1105 +#define D2S_ITEMDATA_IDENTIFIER_KRAKEN_SHELL "uld "
  1106 +#define D2S_ITEMDATA_IDENTIFIER_GOTHIC_PLATE "gth "
  1107 +#define D2S_ITEMDATA_IDENTIFIER_EMBOSSED_PLATE "xth "
  1108 +#define D2S_ITEMDATA_IDENTIFIER_LACQUERED_PLATE "uth "
  1109 +#define D2S_ITEMDATA_IDENTIFIER_FULL_PLATE_MAIL "ful "
  1110 +#define D2S_ITEMDATA_IDENTIFIER_CHAOS_ARMOR "xul "
  1111 +#define D2S_ITEMDATA_IDENTIFIER_SHADOW_PLATE "uul "
  1112 +#define D2S_ITEMDATA_IDENTIFIER_ANCIENT_ARMOR "aar "
  1113 +#define D2S_ITEMDATA_IDENTIFIER_ORNATE_ARMOR "xar "
  1114 +#define D2S_ITEMDATA_IDENTIFIER_SACRED_ARMOR "uar "
  1115 +#define D2S_ITEMDATA_IDENTIFIER_LIGHT_PLATE "ltp "
  1116 +#define D2S_ITEMDATA_IDENTIFIER_MAGE_PLATE "xtp "
  1117 +#define D2S_ITEMDATA_IDENTIFIER_ARCHON_PLATE "utp "
  1118 +#define D2S_ITEMDATA_IDENTIFIER_BUCKLER "buc "
  1119 +#define D2S_ITEMDATA_IDENTIFIER_DEFENDER "xuc "
  1120 +#define D2S_ITEMDATA_IDENTIFIER_HEATER "uuc "
  1121 +#define D2S_ITEMDATA_IDENTIFIER_SMALL_SHIELD "sml "
  1122 +#define D2S_ITEMDATA_IDENTIFIER_ROUND_SHIELD "xml "
  1123 +#define D2S_ITEMDATA_IDENTIFIER_LUNA "uml "
  1124 +#define D2S_ITEMDATA_IDENTIFIER_LARGE_SHIELD "lrg "
  1125 +#define D2S_ITEMDATA_IDENTIFIER_SCUTUM "xrg "
  1126 +#define D2S_ITEMDATA_IDENTIFIER_HYPERION "urg "
  1127 +#define D2S_ITEMDATA_IDENTIFIER_KITE_SHIELD "kit "
  1128 +#define D2S_ITEMDATA_IDENTIFIER_DRAGON_SHIELD "xit "
  1129 +#define D2S_ITEMDATA_IDENTIFIER_MONARCH "uit "
  1130 +#define D2S_ITEMDATA_IDENTIFIER_TOWER_SHIELD "tow "
  1131 +#define D2S_ITEMDATA_IDENTIFIER_PAVISE "xow "
  1132 +#define D2S_ITEMDATA_IDENTIFIER_AEGIS "uow "
  1133 +#define D2S_ITEMDATA_IDENTIFIER_GOTHIC_SHIELD "gts "
  1134 +#define D2S_ITEMDATA_IDENTIFIER_ANCIENT_SHIELD "xts "
  1135 +#define D2S_ITEMDATA_IDENTIFIER_WARD "uts "
  1136 +#define D2S_ITEMDATA_IDENTIFIER_BONE_SHIELD "bsh "
  1137 +#define D2S_ITEMDATA_IDENTIFIER_GRIM_SHIELD "xsh "
  1138 +#define D2S_ITEMDATA_IDENTIFIER_TROLL_NEST "ush "
  1139 +#define D2S_ITEMDATA_IDENTIFIER_SPIKED_SHIELD "spk "
  1140 +#define D2S_ITEMDATA_IDENTIFIER_BARBED_SHIELD "xpk "
  1141 +#define D2S_ITEMDATA_IDENTIFIER_BLADE_BARRIER "upk "
  1142 +#define D2S_ITEMDATA_IDENTIFIER_LEATHER_GLOVES "lgl "
  1143 +#define D2S_ITEMDATA_IDENTIFIER_DEMONHIDE_GLOVE "xlg "
  1144 +#define D2S_ITEMDATA_IDENTIFIER_BRAMBLE_MITTS "ulg "
  1145 +#define D2S_ITEMDATA_IDENTIFIER_HEAVY_GLOVES "vgl "
  1146 +#define D2S_ITEMDATA_IDENTIFIER_SHARKSKIN_GLOVE "xvg "
  1147 +#define D2S_ITEMDATA_IDENTIFIER_VAMPIREBONE_GLOVES "uvg "
  1148 +#define D2S_ITEMDATA_IDENTIFIER_CHAIN_GLOVES "mgl "
  1149 +#define D2S_ITEMDATA_IDENTIFIER_HEAVY_BRACERS "xmg "
  1150 +#define D2S_ITEMDATA_IDENTIFIER_VAMBRACES "umg "
  1151 +#define D2S_ITEMDATA_IDENTIFIER_LIGHT_GAUNTLETS "tgl "
  1152 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_GAUNTLET "xtg "
  1153 +#define D2S_ITEMDATA_IDENTIFIER_CRUSADER_GAUNTLETS "utg "
  1154 +#define D2S_ITEMDATA_IDENTIFIER_GAUNTLETS "hgl "
  1155 +#define D2S_ITEMDATA_IDENTIFIER_WAR_GAUNTLETS "xhg "
  1156 +#define D2S_ITEMDATA_IDENTIFIER_OGRE_GAUNTLETS "uhg "
  1157 +#define D2S_ITEMDATA_IDENTIFIER_BOOTS "lbt "
  1158 +#define D2S_ITEMDATA_IDENTIFIER_DEMONHIDE_BOOTS "xlb "
  1159 +#define D2S_ITEMDATA_IDENTIFIER_WYRMHIDE_BOOTS "ulb "
  1160 +#define D2S_ITEMDATA_IDENTIFIER_HEAVY_BOOTS "vbt "
  1161 +#define D2S_ITEMDATA_IDENTIFIER_SHARKSKIN_BOOTS "xvb "
  1162 +#define D2S_ITEMDATA_IDENTIFIER_SCARABSHELL_BOOTS "uvb "
  1163 +#define D2S_ITEMDATA_IDENTIFIER_CHAIN_BOOTS "mbt "
  1164 +#define D2S_ITEMDATA_IDENTIFIER_MESH_BOOTS "xmb "
  1165 +#define D2S_ITEMDATA_IDENTIFIER_BONEWEAVE_BOOTS "umb "
  1166 +#define D2S_ITEMDATA_IDENTIFIER_LIGHT_PLATE "tbt "
  1167 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_BOOTS "xtb "
  1168 +#define D2S_ITEMDATA_IDENTIFIER_MIRRORED_BOOTS "utb "
  1169 +#define D2S_ITEMDATA_IDENTIFIER_GREAVES "hbt "
  1170 +#define D2S_ITEMDATA_IDENTIFIER_WAR_BOOTS "xhb "
  1171 +#define D2S_ITEMDATA_IDENTIFIER_MYRMIDON_GREAVE "uhb "
  1172 +#define D2S_ITEMDATA_IDENTIFIER_SASH "lbl "
  1173 +#define D2S_ITEMDATA_IDENTIFIER_DEMONHIDE_SASH "zlb "
  1174 +#define D2S_ITEMDATA_IDENTIFIER_SPIDERWEB_SASH "ulc "
  1175 +#define D2S_ITEMDATA_IDENTIFIER_LIGHT_BELT "vbl "
  1176 +#define D2S_ITEMDATA_IDENTIFIER_SHARKSKIN_BELT "zvb "
  1177 +#define D2S_ITEMDATA_IDENTIFIER_VAMPIREFANG_BELT "uvc "
  1178 +#define D2S_ITEMDATA_IDENTIFIER_BELT "mbl "
  1179 +#define D2S_ITEMDATA_IDENTIFIER_MESH_BELT "zmb "
  1180 +#define D2S_ITEMDATA_IDENTIFIER_MITHRIL_COIL "umc "
  1181 +#define D2S_ITEMDATA_IDENTIFIER_HEAVY_BELT "tbl "
  1182 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_BELT "ztb "
  1183 +#define D2S_ITEMDATA_IDENTIFIER_TROLL_BELT "utc "
  1184 +#define D2S_ITEMDATA_IDENTIFIER_PLATED_BELT "hbl "
  1185 +#define D2S_ITEMDATA_IDENTIFIER_WAR_BELT "zhb "
  1186 +#define D2S_ITEMDATA_IDENTIFIER_COLOSSUS_GIRDLE "uhc "
  1187 +#define D2S_ITEMDATA_IDENTIFIER_WOLF_HEAD "dr1 "
  1188 +#define D2S_ITEMDATA_IDENTIFIER_ALPHA_HELM "dr6 "
  1189 +#define D2S_ITEMDATA_IDENTIFIER_BLOOD_SPIRIT "drb "
  1190 +#define D2S_ITEMDATA_IDENTIFIER_HAWK_HELM "dr2 "
  1191 +#define D2S_ITEMDATA_IDENTIFIER_GRIFFON_HEADDRESS "dr7 "
  1192 +#define D2S_ITEMDATA_IDENTIFIER_SUN_SPIRIT "drc "
  1193 +#define D2S_ITEMDATA_IDENTIFIER_ANTLERS "dr3 "
  1194 +#define D2S_ITEMDATA_IDENTIFIER_HUNTERS_GUISE "dr8 "
  1195 +#define D2S_ITEMDATA_IDENTIFIER_EARTH_SPIRIT "drd "
  1196 +#define D2S_ITEMDATA_IDENTIFIER_FALCON_MASK "dr4 "
  1197 +#define D2S_ITEMDATA_IDENTIFIER_SACRED_FEATHERS "dr9 "
  1198 +#define D2S_ITEMDATA_IDENTIFIER_SKY_SPIRIT "dre "
  1199 +#define D2S_ITEMDATA_IDENTIFIER_SPIRIT_MASK "dr5 "
  1200 +#define D2S_ITEMDATA_IDENTIFIER_TOTEMIC_MASK "dra "
  1201 +#define D2S_ITEMDATA_IDENTIFIER_DREAM_SPIRIT "drf "
  1202 +#define D2S_ITEMDATA_IDENTIFIER_JAWBONE_CAP "ba1 "
  1203 +#define D2S_ITEMDATA_IDENTIFIER_JAWBONE_VISOR "ba6 "
  1204 +#define D2S_ITEMDATA_IDENTIFIER_CARNAGE_HELM "bab "
  1205 +#define D2S_ITEMDATA_IDENTIFIER_FANGED_HELM "ba2 "
  1206 +#define D2S_ITEMDATA_IDENTIFIER_LION_HELM "ba7 "
  1207 +#define D2S_ITEMDATA_IDENTIFIER_FURY_VISOR "bac "
  1208 +#define D2S_ITEMDATA_IDENTIFIER_HORNED_HELM "ba3 "
  1209 +#define D2S_ITEMDATA_IDENTIFIER_RAGE_MASK "ba8 "
  1210 +#define D2S_ITEMDATA_IDENTIFIER_DESTROYER_HELM "bad "
  1211 +#define D2S_ITEMDATA_IDENTIFIER_ASSUALT_HELMET "ba4 "
  1212 +#define D2S_ITEMDATA_IDENTIFIER_SAVAGE_HELMET "ba9 "
  1213 +#define D2S_ITEMDATA_IDENTIFIER_CONQUEROR_CROWN "bae "
  1214 +#define D2S_ITEMDATA_IDENTIFIER_AVENGER_GUARD "ba5 "
  1215 +#define D2S_ITEMDATA_IDENTIFIER_SLAYER_GUARD "baa "
  1216 +#define D2S_ITEMDATA_IDENTIFIER_GUARDIAN_CROWN "baf "
  1217 +#define D2S_ITEMDATA_IDENTIFIER_TARGE "pa1 "
  1218 +#define D2S_ITEMDATA_IDENTIFIER_AKARAN_TARGE "pa6 "
  1219 +#define D2S_ITEMDATA_IDENTIFIER_SACRED_TARGE "pab "
  1220 +#define D2S_ITEMDATA_IDENTIFIER_RONDACHE "pa2 "
  1221 +#define D2S_ITEMDATA_IDENTIFIER_AKARAN_RONDACHE "pa7 "
  1222 +#define D2S_ITEMDATA_IDENTIFIER_SACRED_RONDACHE "pac "
  1223 +#define D2S_ITEMDATA_IDENTIFIER_HERALDIC_SHIELD "pa3 "
  1224 +#define D2S_ITEMDATA_IDENTIFIER_PROTECTOR_SHLD "pa8 "
  1225 +#define D2S_ITEMDATA_IDENTIFIER_KURAST_SHIELD "pad "
  1226 +#define D2S_ITEMDATA_IDENTIFIER_AERIN_SHIELD "pa4 "
  1227 +#define D2S_ITEMDATA_IDENTIFIER_GUILDED_SHIELD "pa9 "
  1228 +#define D2S_ITEMDATA_IDENTIFIER_ZAKARUM_SHIELD "pae "
  1229 +#define D2S_ITEMDATA_IDENTIFIER_CROWN_SHIELD "pa5 "
  1230 +#define D2S_ITEMDATA_IDENTIFIER_ROYAL_SHIELD "paa "
  1231 +#define D2S_ITEMDATA_IDENTIFIER_VORTEX_SHIELD "paf "
  1232 +#define D2S_ITEMDATA_IDENTIFIER_PRESERVED_HEAD "ne1 "
  1233 +#define D2S_ITEMDATA_IDENTIFIER_MUMMIFIED_TRPHY "ne6 "
  1234 +#define D2S_ITEMDATA_IDENTIFIER_MINION_SKULL "neb "
  1235 +#define D2S_ITEMDATA_IDENTIFIER_ZOMBIE_HEAD "ne2 "
  1236 +#define D2S_ITEMDATA_IDENTIFIER_FETISH_TROPHY "ne7 "
  1237 +#define D2S_ITEMDATA_IDENTIFIER_HELLSPAWN_SKULL "nec "
  1238 +#define D2S_ITEMDATA_IDENTIFIER_UNRAVELLER_HEAD "ne3 "
  1239 +#define D2S_ITEMDATA_IDENTIFIER_SEXTON_TROPHY "ne8 "
  1240 +#define D2S_ITEMDATA_IDENTIFIER_OVERSEER_SKULL "ned "
  1241 +#define D2S_ITEMDATA_IDENTIFIER_GARGOYLE_HEAD "ne4 "
  1242 +#define D2S_ITEMDATA_IDENTIFIER_CANTOR_TROPHY "ne9 "
  1243 +#define D2S_ITEMDATA_IDENTIFIER_SUCCUBUS_SKULL "nee "
  1244 +#define D2S_ITEMDATA_IDENTIFIER_DEMON_HEAD "ne5 "
  1245 +#define D2S_ITEMDATA_IDENTIFIER_HEIROPHANT_TRPHY "nea "
  1246 +#define D2S_ITEMDATA_IDENTIFIER_BLOODLORD_SKULL "nef "
  1247 +#define D2S_ITEMDATA_IDENTIFIER_HAND_AXE "hax "
  1248 +#define D2S_ITEMDATA_IDENTIFIER_HATCHET "9ha "
  1249 +#define D2S_ITEMDATA_IDENTIFIER_TOMAHAWK "7ha "
  1250 +#define D2S_ITEMDATA_IDENTIFIER_AXE "axe "
  1251 +#define D2S_ITEMDATA_IDENTIFIER_CLEAVER "9ax "
  1252 +#define D2S_ITEMDATA_IDENTIFIER_SMALL_CRESCENT "7ax "
  1253 +#define D2S_ITEMDATA_IDENTIFIER_DOUBLE_AXE "2ax "
  1254 +#define D2S_ITEMDATA_IDENTIFIER_TWIN_AXE "92a "
  1255 +#define D2S_ITEMDATA_IDENTIFIER_ETTIN_AXE "72a "
  1256 +#define D2S_ITEMDATA_IDENTIFIER_MILITARY_PICK "mpi "
  1257 +#define D2S_ITEMDATA_IDENTIFIER_CROWBILL "9mp "
  1258 +#define D2S_ITEMDATA_IDENTIFIER_WAR_SPIKE "7mp "
  1259 +#define D2S_ITEMDATA_IDENTIFIER_WAR_AXE "wax "
  1260 +#define D2S_ITEMDATA_IDENTIFIER_NAGA "9wa "
  1261 +#define D2S_ITEMDATA_IDENTIFIER_BERSERKER_AXE "7wa "
  1262 +#define D2S_ITEMDATA_IDENTIFIER_LARGE_AXE "lax "
  1263 +#define D2S_ITEMDATA_IDENTIFIER_MILITARY_AXE "9la "
  1264 +#define D2S_ITEMDATA_IDENTIFIER_FERAL_AXE "7la "
  1265 +#define D2S_ITEMDATA_IDENTIFIER_BROAD_AXE "bax "
  1266 +#define D2S_ITEMDATA_IDENTIFIER_BEARDED_AXE "9ba "
  1267 +#define D2S_ITEMDATA_IDENTIFIER_SILVER_EDGED_AX "7ba "
  1268 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_AXE "btx "
  1269 +#define D2S_ITEMDATA_IDENTIFIER_TABAR "9bt "
  1270 +#define D2S_ITEMDATA_IDENTIFIER_DECAPITATOR "7bt "
  1271 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_AXE "gax "
  1272 +#define D2S_ITEMDATA_IDENTIFIER_GOTHIC_AXE "9ga "
  1273 +#define D2S_ITEMDATA_IDENTIFIER_CHAMPION_AXE "7ga "
  1274 +#define D2S_ITEMDATA_IDENTIFIER_GIANT_AXE "gix "
  1275 +#define D2S_ITEMDATA_IDENTIFIER_ANCIENT_AXE "9gi "
  1276 +#define D2S_ITEMDATA_IDENTIFIER_GLORIOUS_AXE "7gi "
  1277 +#define D2S_ITEMDATA_IDENTIFIER_CLUB "clb "
  1278 +#define D2S_ITEMDATA_IDENTIFIER_CUDGEL "9cl "
  1279 +#define D2S_ITEMDATA_IDENTIFIER_TRUNCHEON "7cl "
  1280 +#define D2S_ITEMDATA_IDENTIFIER_SPIKED_CLUB "spc "
  1281 +#define D2S_ITEMDATA_IDENTIFIER_BARBED_CLUB "9sp "
  1282 +#define D2S_ITEMDATA_IDENTIFIER_TYRANT_CLUB "7sp "
  1283 +#define D2S_ITEMDATA_IDENTIFIER_MACE "mac "
  1284 +#define D2S_ITEMDATA_IDENTIFIER_FLANGED_MACE "9ma "
  1285 +#define D2S_ITEMDATA_IDENTIFIER_REINFORCED_MACE "7ma "
  1286 +#define D2S_ITEMDATA_IDENTIFIER_MORNING_STAR "mst "
  1287 +#define D2S_ITEMDATA_IDENTIFIER_JAGGED_STAR "9mt "
  1288 +#define D2S_ITEMDATA_IDENTIFIER_DEVIL_STAR "7mf "
  1289 +#define D2S_ITEMDATA_IDENTIFIER_FLAIL "fla "
  1290 +#define D2S_ITEMDATA_IDENTIFIER_KNOUT "9fl "
  1291 +#define D2S_ITEMDATA_IDENTIFIER_SCOURGE "7fl "
  1292 +#define D2S_ITEMDATA_IDENTIFIER_WAR_HAMMER "whm "
  1293 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_HAMMER "9wh "
  1294 +#define D2S_ITEMDATA_IDENTIFIER_LEGENDARY_MALLET "7wh "
  1295 +#define D2S_ITEMDATA_IDENTIFIER_MAUL "mau "
  1296 +#define D2S_ITEMDATA_IDENTIFIER_WAR_CLUB "9m9 "
  1297 +#define D2S_ITEMDATA_IDENTIFIER_OGRE_MAUL "7m7 "
  1298 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_MAUL "gma "
  1299 +#define D2S_ITEMDATA_IDENTIFIER_MARTEL_DE_FER "9gm "
  1300 +#define D2S_ITEMDATA_IDENTIFIER_THUNDER_MAUL "7gm "
  1301 +#define D2S_ITEMDATA_IDENTIFIER_SHORT_SWORD "ssd "
  1302 +#define D2S_ITEMDATA_IDENTIFIER_GLADIUS "9ss "
  1303 +#define D2S_ITEMDATA_IDENTIFIER_FALCATA "7ss "
  1304 +#define D2S_ITEMDATA_IDENTIFIER_SCIMITAR "scm "
  1305 +#define D2S_ITEMDATA_IDENTIFIER_CUTLASS "9sm "
  1306 +#define D2S_ITEMDATA_IDENTIFIER_ATAGHAN "7sm "
  1307 +#define D2S_ITEMDATA_IDENTIFIER_SABER "sbr "
  1308 +#define D2S_ITEMDATA_IDENTIFIER_SHAMSHIR "9sb "
  1309 +#define D2S_ITEMDATA_IDENTIFIER_ELEGANT_BLADE "7sb "
  1310 +#define D2S_ITEMDATA_IDENTIFIER_FALCHION "flc "
  1311 +#define D2S_ITEMDATA_IDENTIFIER_TULWAR "9fc "
  1312 +#define D2S_ITEMDATA_IDENTIFIER_HYDRA_EDGE "7fc "
  1313 +#define D2S_ITEMDATA_IDENTIFIER_CRYSTAL_SWORD "crs "
  1314 +#define D2S_ITEMDATA_IDENTIFIER_DIMENSIONAL_BLADE "9cr "
  1315 +#define D2S_ITEMDATA_IDENTIFIER_PHASE_BLADE "7cr "
  1316 +#define D2S_ITEMDATA_IDENTIFIER_BROAD_SWORD "bsd "
  1317 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_SWORD "9bs "
  1318 +#define D2S_ITEMDATA_IDENTIFIER_CONQUEST_SWORD "7bs "
  1319 +#define D2S_ITEMDATA_IDENTIFIER_LONG_SWORD "lsd "
  1320 +#define D2S_ITEMDATA_IDENTIFIER_RUNE_SWORD "9ls "
  1321 +#define D2S_ITEMDATA_IDENTIFIER_CRYPTIC_SWORD "7ls "
  1322 +#define D2S_ITEMDATA_IDENTIFIER_WAR_SWORD "wsd "
  1323 +#define D2S_ITEMDATA_IDENTIFIER_ANCIENT_SWORD "9wd "
  1324 +#define D2S_ITEMDATA_IDENTIFIER_MYTHICAL_SWORD "7wd "
  1325 +#define D2S_ITEMDATA_IDENTIFIER_TWOHANDED_SWORD "2hs "
  1326 +#define D2S_ITEMDATA_IDENTIFIER_ESPADON "92h "
  1327 +#define D2S_ITEMDATA_IDENTIFIER_LEGEND_SWORD "72h "
  1328 +#define D2S_ITEMDATA_IDENTIFIER_CLAYMORE "clm "
  1329 +#define D2S_ITEMDATA_IDENTIFIER_DACIAN_FALX "9cm "
  1330 +#define D2S_ITEMDATA_IDENTIFIER_HIGHLAND_BLADE "7cm "
  1331 +#define D2S_ITEMDATA_IDENTIFIER_GIANT_SWORD "gis "
  1332 +#define D2S_ITEMDATA_IDENTIFIER_TUSK_SWORD "9gs "
  1333 +#define D2S_ITEMDATA_IDENTIFIER_BALROG_BLADE "7gs "
  1334 +#define D2S_ITEMDATA_IDENTIFIER_BASTARD_SWORD "bsw "
  1335 +#define D2S_ITEMDATA_IDENTIFIER_GOTHIC_SWORD "9b9 "
  1336 +#define D2S_ITEMDATA_IDENTIFIER_CHAMPION_SWORD "7b7 "
  1337 +#define D2S_ITEMDATA_IDENTIFIER_FLAMBERGE "flb "
  1338 +#define D2S_ITEMDATA_IDENTIFIER_ZWEIHANDER "9fb "
  1339 +#define D2S_ITEMDATA_IDENTIFIER_COLOSSAL_SWORD "7fb "
  1340 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_SWORD "gsd "
  1341 +#define D2S_ITEMDATA_IDENTIFIER_EXECUTIONER_SWORD "9gd "
  1342 +#define D2S_ITEMDATA_IDENTIFIER_COLOSSUS_BLADE "7gd "
  1343 +#define D2S_ITEMDATA_IDENTIFIER_DAGGER "dgr "
  1344 +#define D2S_ITEMDATA_IDENTIFIER_POIGNARD "9dg "
  1345 +#define D2S_ITEMDATA_IDENTIFIER_BONE_KNIFE "7dg "
  1346 +#define D2S_ITEMDATA_IDENTIFIER_DIRK "dir "
  1347 +#define D2S_ITEMDATA_IDENTIFIER_RONDEL "9di "
  1348 +#define D2S_ITEMDATA_IDENTIFIER_MITHRAL_POINT "7di "
  1349 +#define D2S_ITEMDATA_IDENTIFIER_KRISS "kri "
  1350 +#define D2S_ITEMDATA_IDENTIFIER_CINQUEDEAS "9kr "
  1351 +#define D2S_ITEMDATA_IDENTIFIER_FANGED_KNIFE "7kr "
  1352 +#define D2S_ITEMDATA_IDENTIFIER_BLADE "bld "
  1353 +#define D2S_ITEMDATA_IDENTIFIER_STILLETO "9bl "
  1354 +#define D2S_ITEMDATA_IDENTIFIER_LEGEND_SPIKE "7bl "
  1355 +#define D2S_ITEMDATA_IDENTIFIER_THROWING_KNIFE "tkf "
  1356 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_DART "9tk "
  1357 +#define D2S_ITEMDATA_IDENTIFIER_FLYING_KNIFE "7tk "
  1358 +#define D2S_ITEMDATA_IDENTIFIER_THROWING_AXE "tax "
  1359 +#define D2S_ITEMDATA_IDENTIFIER_FRANCISCA "9ta "
  1360 +#define D2S_ITEMDATA_IDENTIFIER_FLYING_AXE "7ta "
  1361 +#define D2S_ITEMDATA_IDENTIFIER_BALANCED_KNIFE "bkf "
  1362 +#define D2S_ITEMDATA_IDENTIFIER_WAR_DART "9bk "
  1363 +#define D2S_ITEMDATA_IDENTIFIER_WINGED_KNIFE "7bk "
  1364 +#define D2S_ITEMDATA_IDENTIFIER_BALANCED_AXE "bal "
  1365 +#define D2S_ITEMDATA_IDENTIFIER_HURLBAT "9b8 "
  1366 +#define D2S_ITEMDATA_IDENTIFIER_WINGED_AXE "7b8 "
  1367 +#define D2S_ITEMDATA_IDENTIFIER_JAVELIN "jav "
  1368 +#define D2S_ITEMDATA_IDENTIFIER_WAR_JAVELIN "9ja "
  1369 +#define D2S_ITEMDATA_IDENTIFIER_HYPERION_JAVELIN "7ja "
  1370 +#define D2S_ITEMDATA_IDENTIFIER_PILUM "pil "
  1371 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_PILUM "9pi "
  1372 +#define D2S_ITEMDATA_IDENTIFIER_STYGIAN_PILUM "7pi "
  1373 +#define D2S_ITEMDATA_IDENTIFIER_SHORT_SPEAR "ssp "
  1374 +#define D2S_ITEMDATA_IDENTIFIER_SIMBILAN "9s9 "
  1375 +#define D2S_ITEMDATA_IDENTIFIER_BALROG_SPEAR "7s7 "
  1376 +#define D2S_ITEMDATA_IDENTIFIER_GLAIVE "glv "
  1377 +#define D2S_ITEMDATA_IDENTIFIER_SPICULUM "9gl "
  1378 +#define D2S_ITEMDATA_IDENTIFIER_GHOST_GLAIVE "7gl "
  1379 +#define D2S_ITEMDATA_IDENTIFIER_THROWING_SPEAR "tsp "
  1380 +#define D2S_ITEMDATA_IDENTIFIER_HARPOON "9ts "
  1381 +#define D2S_ITEMDATA_IDENTIFIER_WINGED_HARPOON "7ts "
  1382 +#define D2S_ITEMDATA_IDENTIFIER_SPEAR "spr "
  1383 +#define D2S_ITEMDATA_IDENTIFIER_WAR_SPEAR "9sr "
  1384 +#define D2S_ITEMDATA_IDENTIFIER_HYPERION_SPEAR "7sr "
  1385 +#define D2S_ITEMDATA_IDENTIFIER_TRIDENT "tri "
  1386 +#define D2S_ITEMDATA_IDENTIFIER_FUSCINA "9tr "
  1387 +#define D2S_ITEMDATA_IDENTIFIER_STYGIAN_PIKE "7tr "
  1388 +#define D2S_ITEMDATA_IDENTIFIER_BRANDISTOCK "brn "
  1389 +#define D2S_ITEMDATA_IDENTIFIER_WAR_FORK "9br "
  1390 +#define D2S_ITEMDATA_IDENTIFIER_MANCATCHER "7br "
  1391 +#define D2S_ITEMDATA_IDENTIFIER_SPETUM "spt "
  1392 +#define D2S_ITEMDATA_IDENTIFIER_YARI "9st "
  1393 +#define D2S_ITEMDATA_IDENTIFIER_GHOST_SPEAR "7st "
  1394 +#define D2S_ITEMDATA_IDENTIFIER_PIKE "pik "
  1395 +#define D2S_ITEMDATA_IDENTIFIER_LANCE "9p9 "
  1396 +#define D2S_ITEMDATA_IDENTIFIER_WAR_PIKE "7p7 "
  1397 +#define D2S_ITEMDATA_IDENTIFIER_BARDICHE "bar "
  1398 +#define D2S_ITEMDATA_IDENTIFIER_LOCHABER_AXE "9b7 "
  1399 +#define D2S_ITEMDATA_IDENTIFIER_OGRE_AXE "7o7 "
  1400 +#define D2S_ITEMDATA_IDENTIFIER_VOULGE "vou "
  1401 +#define D2S_ITEMDATA_IDENTIFIER_BILL "9vo "
  1402 +#define D2S_ITEMDATA_IDENTIFIER_COLOSSUS_VOULGE "7vo "
  1403 +#define D2S_ITEMDATA_IDENTIFIER_SCYTHE "scy "
  1404 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_SCYTHE "9s8 "
  1405 +#define D2S_ITEMDATA_IDENTIFIER_THRESHER "7s8 "
  1406 +#define D2S_ITEMDATA_IDENTIFIER_POLEAXE "pax "
  1407 +#define D2S_ITEMDATA_IDENTIFIER_PARTIZAN "9pa "
  1408 +#define D2S_ITEMDATA_IDENTIFIER_CRYPTIC_AXE "7pa "
  1409 +#define D2S_ITEMDATA_IDENTIFIER_HALBERD "hal "
  1410 +#define D2S_ITEMDATA_IDENTIFIER_BEC_DE_CORBIN "9h9 "
  1411 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_POLEAXE "7h7 "
  1412 +#define D2S_ITEMDATA_IDENTIFIER_WAR_SCYTHE "wsc "
  1413 +#define D2S_ITEMDATA_IDENTIFIER_GRIM_SCYTHE "9wc "
  1414 +#define D2S_ITEMDATA_IDENTIFIER_GIANT_THRESHER "7wc "
  1415 +#define D2S_ITEMDATA_IDENTIFIER_SHORT_BOW "sbw "
  1416 +#define D2S_ITEMDATA_IDENTIFIER_EDGE_BOW "8sb "
  1417 +#define D2S_ITEMDATA_IDENTIFIER_SPIDER_BOW "6sb "
  1418 +#define D2S_ITEMDATA_IDENTIFIER_HUNTERS_BOW "hbw "
  1419 +#define D2S_ITEMDATA_IDENTIFIER_RAZOR_BOW "8hb "
  1420 +#define D2S_ITEMDATA_IDENTIFIER_BLADE_BOW "6hb "
  1421 +#define D2S_ITEMDATA_IDENTIFIER_LONG_BOW "lbw "
  1422 +#define D2S_ITEMDATA_IDENTIFIER_CEDAR_BOW "8lb "
  1423 +#define D2S_ITEMDATA_IDENTIFIER_SHADOW_BOW "6lb "
  1424 +#define D2S_ITEMDATA_IDENTIFIER_COMPOSITE_BOW "cbw "
  1425 +#define D2S_ITEMDATA_IDENTIFIER_DOUBLE_BOW "8cb "
  1426 +#define D2S_ITEMDATA_IDENTIFIER_GREAT_BOW "6cb "
  1427 +#define D2S_ITEMDATA_IDENTIFIER_SHORT_BATTLE_BOW "sbb "
  1428 +#define D2S_ITEMDATA_IDENTIFIER_SHORT_SIEGE_BOW "8s8 "
  1429 +#define D2S_ITEMDATA_IDENTIFIER_DIAMOND_BOW "6s7 "
  1430 +#define D2S_ITEMDATA_IDENTIFIER_LONG_BATTLE_BOW "lbb "
  1431 +#define D2S_ITEMDATA_IDENTIFIER_LONG_SIEGE_BOW "8l8 "
  1432 +#define D2S_ITEMDATA_IDENTIFIER_CRUSADER_BOW "6l7 "
  1433 +#define D2S_ITEMDATA_IDENTIFIER_SHORT_WAR_BOW "swb "
  1434 +#define D2S_ITEMDATA_IDENTIFIER_RUNE_BOW "8sw "
  1435 +#define D2S_ITEMDATA_IDENTIFIER_WARD_BOW "6sw "
  1436 +#define D2S_ITEMDATA_IDENTIFIER_LONG_WAR_BOW "lwb "
  1437 +#define D2S_ITEMDATA_IDENTIFIER_GOTHIC_BOW "8lw "
  1438 +#define D2S_ITEMDATA_IDENTIFIER_HYDRA_BOW "6lw "
  1439 +#define D2S_ITEMDATA_IDENTIFIER_LIGHT_CROSSBOW "lxb "
  1440 +#define D2S_ITEMDATA_IDENTIFIER_ARBALEST "8lx "
  1441 +#define D2S_ITEMDATA_IDENTIFIER_PELLET_BOW "6lx "
  1442 +#define D2S_ITEMDATA_IDENTIFIER_CROSSBOW "mxb "
  1443 +#define D2S_ITEMDATA_IDENTIFIER_SIEGE_CROSSBOW "8mx "
  1444 +#define D2S_ITEMDATA_IDENTIFIER_GORGON_CROSSBOW "6mx "
  1445 +#define D2S_ITEMDATA_IDENTIFIER_HEAVY_CROSSBOW "hxb "
  1446 +#define D2S_ITEMDATA_IDENTIFIER_BALLISTA "8hx "
  1447 +#define D2S_ITEMDATA_IDENTIFIER_COLOSSUS_CROSSBOW "6hx "
  1448 +#define D2S_ITEMDATA_IDENTIFIER_REPEATING_CROSSBOW "rxb "
  1449 +#define D2S_ITEMDATA_IDENTIFIER_CHU_KO_NU "8rx "
  1450 +#define D2S_ITEMDATA_IDENTIFIER_DEMON_CROSSBOW "6rx "
  1451 +#define D2S_ITEMDATA_IDENTIFIER_SHORT_STAFF "sst "
  1452 +#define D2S_ITEMDATA_IDENTIFIER_JO_STAFF "8ss "
  1453 +#define D2S_ITEMDATA_IDENTIFIER_WALKING_STICK "6ss "
  1454 +#define D2S_ITEMDATA_IDENTIFIER_LONG_STAFF "lst "
  1455 +#define D2S_ITEMDATA_IDENTIFIER_QUARTERSTAFF "8ls "
  1456 +#define D2S_ITEMDATA_IDENTIFIER_STALAGMITE "6ls "
  1457 +#define D2S_ITEMDATA_IDENTIFIER_GNARLED_STAFF "gst "
  1458 +#define D2S_ITEMDATA_IDENTIFIER_CEDAR_STAFF "8cs "
  1459 +#define D2S_ITEMDATA_IDENTIFIER_ELDER_STAFF "6cs "
  1460 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_STAFF "bst "
  1461 +#define D2S_ITEMDATA_IDENTIFIER_GOTHIC_STAFF "8bs "
  1462 +#define D2S_ITEMDATA_IDENTIFIER_SHILLELAGH "6bs "
  1463 +#define D2S_ITEMDATA_IDENTIFIER_WAR_STAFF "wst "
  1464 +#define D2S_ITEMDATA_IDENTIFIER_RUNE_STAFF "8ws "
  1465 +#define D2S_ITEMDATA_IDENTIFIER_ARCHON_STAFF "6ws "
  1466 +#define D2S_ITEMDATA_IDENTIFIER_WAND "wnd "
  1467 +#define D2S_ITEMDATA_IDENTIFIER_BURNT_WAND "9wn "
  1468 +#define D2S_ITEMDATA_IDENTIFIER_POLISHED_WAND "7wn "
  1469 +#define D2S_ITEMDATA_IDENTIFIER_YEW_WAND "ywn "
  1470 +#define D2S_ITEMDATA_IDENTIFIER_PETRIFIED_WAND "9yw "
  1471 +#define D2S_ITEMDATA_IDENTIFIER_GHOST_WAND "7yw "
  1472 +#define D2S_ITEMDATA_IDENTIFIER_BONE_WAND "bwn "
  1473 +#define D2S_ITEMDATA_IDENTIFIER_TOMB_WAND "9bw "
  1474 +#define D2S_ITEMDATA_IDENTIFIER_LICH_WAND "7bw "
  1475 +#define D2S_ITEMDATA_IDENTIFIER_GRIM_WAND "gwn "
  1476 +#define D2S_ITEMDATA_IDENTIFIER_GRAVE_WAND "9gw "
  1477 +#define D2S_ITEMDATA_IDENTIFIER_UNEARTHED_WAND "7gw "
  1478 +#define D2S_ITEMDATA_IDENTIFIER_SCEPTRE "scp "
  1479 +#define D2S_ITEMDATA_IDENTIFIER_RUNE_SCEPTRE "9sc "
  1480 +#define D2S_ITEMDATA_IDENTIFIER_MIGHTY_SCEPTRE "7sc "
  1481 +#define D2S_ITEMDATA_IDENTIFIER_GRAND_SCEPTRE "gsc "
  1482 +#define D2S_ITEMDATA_IDENTIFIER_HOLY_WATER_SPRINKLER "9qs "
  1483 +#define D2S_ITEMDATA_IDENTIFIER_SERAPH_ROD "7qs "
  1484 +#define D2S_ITEMDATA_IDENTIFIER_WAR_SCEPTRE "wsp "
  1485 +#define D2S_ITEMDATA_IDENTIFIER_DIVINE_SCEPTRE "9ws "
  1486 +#define D2S_ITEMDATA_IDENTIFIER_CADUCEUS "7ws "
  1487 +#define D2S_ITEMDATA_IDENTIFIER_KATAR "ktr "
  1488 +#define D2S_ITEMDATA_IDENTIFIER_QUHAB "9ar "
  1489 +#define D2S_ITEMDATA_IDENTIFIER_SUWAYYAH "7ar "
  1490 +#define D2S_ITEMDATA_IDENTIFIER_WRIST_BLADE "wrb "
  1491 +#define D2S_ITEMDATA_IDENTIFIER_WRIST_SPIKE "9wb "
  1492 +#define D2S_ITEMDATA_IDENTIFIER_WRIST_SWORD "7wb "
  1493 +#define D2S_ITEMDATA_IDENTIFIER_HATCHET_HANDS "axf "
  1494 +#define D2S_ITEMDATA_IDENTIFIER_FASCIA "9xf "
  1495 +#define D2S_ITEMDATA_IDENTIFIER_WAR_FIST "7xf "
  1496 +#define D2S_ITEMDATA_IDENTIFIER_CESTUS "ces "
  1497 +#define D2S_ITEMDATA_IDENTIFIER_HAND_SCYTHE "9cs "
  1498 +#define D2S_ITEMDATA_IDENTIFIER_BATTLE_CESTUS "7cs "
  1499 +#define D2S_ITEMDATA_IDENTIFIER_CLAWS "clw "
  1500 +#define D2S_ITEMDATA_IDENTIFIER_GREATER_CLAWS "9lw "
  1501 +#define D2S_ITEMDATA_IDENTIFIER_FERAL_CLAWS "7lw "
  1502 +#define D2S_ITEMDATA_IDENTIFIER_BLADE_TALONS "btl "
  1503 +#define D2S_ITEMDATA_IDENTIFIER_GREATER_TALONS "9hw "
  1504 +#define D2S_ITEMDATA_IDENTIFIER_RUNIC_TALONS "7hw "
  1505 +#define D2S_ITEMDATA_IDENTIFIER_SCISSORS_KATAR "skr "
  1506 +#define D2S_ITEMDATA_IDENTIFIER_SCISSORS_QUHAB "9qr "
  1507 +#define D2S_ITEMDATA_IDENTIFIER_SCISSORS_SUWAYYAH "7qr "
  1508 +#define D2S_ITEMDATA_IDENTIFIER_EAGLE_ORB "ob1 "
  1509 +#define D2S_ITEMDATA_IDENTIFIER_GLOWING_ORB "ob6 "
  1510 +#define D2S_ITEMDATA_IDENTIFIER_HEAVENLY_STONE "obb "
  1511 +#define D2S_ITEMDATA_IDENTIFIER_SACRED_GLOBE "ob2 "
  1512 +#define D2S_ITEMDATA_IDENTIFIER_CRYSTALLINE_GLB "ob7 "
  1513 +#define D2S_ITEMDATA_IDENTIFIER_ELDRITCH_ORB "obc "
  1514 +#define D2S_ITEMDATA_IDENTIFIER_SMOKED_SPHERE "ob3 "
  1515 +#define D2S_ITEMDATA_IDENTIFIER_CLOUDY_SPHERE "ob8 "
  1516 +#define D2S_ITEMDATA_IDENTIFIER_DEMON_HEART "obd "
  1517 +#define D2S_ITEMDATA_IDENTIFIER_CLASPED_ORB "ob4 "
  1518 +#define D2S_ITEMDATA_IDENTIFIER_SPARKLING_BALL "ob9 "
  1519 +#define D2S_ITEMDATA_IDENTIFIER_VORTEX_ORB "obe "
  1520 +#define D2S_ITEMDATA_IDENTIFIER_DRAGON_STONE "ob5 "
  1521 +#define D2S_ITEMDATA_IDENTIFIER_SWIRLING_CRYSTAL "oba "
  1522 +#define D2S_ITEMDATA_IDENTIFIER_DIMENSIONAL_SHARD "obf "
  1523 +#define D2S_ITEMDATA_IDENTIFIER_STAG_BOW "am1 "
  1524 +#define D2S_ITEMDATA_IDENTIFIER_ASHWOOD_BOW "am6 "
  1525 +#define D2S_ITEMDATA_IDENTIFIER_MATRIARCHAL_BOW "amb "
  1526 +#define D2S_ITEMDATA_IDENTIFIER_REFLEX_BOW "am2 "
  1527 +#define D2S_ITEMDATA_IDENTIFIER_CEREMONIAL_BOW "am7 "
  1528 +#define D2S_ITEMDATA_IDENTIFIER_GRAND_MATRON_BOW "amc "
  1529 +#define D2S_ITEMDATA_IDENTIFIER_MAIDEN_SPEAR "am3 "
  1530 +#define D2S_ITEMDATA_IDENTIFIER_CEREMONIAL_SPEAR "am8 "
  1531 +#define D2S_ITEMDATA_IDENTIFIER_MATRIARCHAL_SPEAR "amd "
  1532 +#define D2S_ITEMDATA_IDENTIFIER_MAIDEN_PIKE "am4 "
  1533 +#define D2S_ITEMDATA_IDENTIFIER_CEREMONIAL_PIKE "am9 "
  1534 +#define D2S_ITEMDATA_IDENTIFIER_MATRIARCHAL_PIKE "ame "
  1535 +#define D2S_ITEMDATA_IDENTIFIER_MAIDEN_JAVELIN "am5 "
  1536 +#define D2S_ITEMDATA_IDENTIFIER_CEREMONIAL_JAVELIN "ama "
  1537 +#define D2S_ITEMDATA_IDENTIFIER_MATRIARCHAL_JAVELIN "amf "
  1538 +#define D2S_ITEMDATA_IDENTIFIER_CIRCLET "ci0 "
  1539 +#define D2S_ITEMDATA_IDENTIFIER_CORONET "ci1 "
  1540 +#define D2S_ITEMDATA_IDENTIFIER_TIARA "ci2 "
  1541 +#define D2S_ITEMDATA_IDENTIFIER_DIADEM "ci3 "
  1542 +#define D2S_ITEMDATA_IDENTIFIER_RANCID_GAS_POTION "gps "
  1543 +#define D2S_ITEMDATA_IDENTIFIER_OIL_POTION "ops "
  1544 +#define D2S_ITEMDATA_IDENTIFIER_CHOKING_GAS_POTION "gpm "
  1545 +#define D2S_ITEMDATA_IDENTIFIER_EXPLODING_POTION "opm "
  1546 +#define D2S_ITEMDATA_IDENTIFIER_STRANGLING_GAS_POTION "gpl "
  1547 +#define D2S_ITEMDATA_IDENTIFIER_FULMINATING_POTION "opl "
  1548 +#define D2S_ITEMDATA_IDENTIFIER_WIRTS_LEG "leg "
  1549 +#define D2S_ITEMDATA_IDENTIFIER_HORADRIC_MALUS "hdm "
  1550 +#define D2S_ITEMDATA_IDENTIFIER_SCROLL_OF_INIFUSS1 "bks "
  1551 +#define D2S_ITEMDATA_IDENTIFIER_SCROLL_OF_INIFUSS2 "bkd "
  1552 +#define D2S_ITEMDATA_IDENTIFIER_BOOK_OF_SKILL "ass "
  1553 +#define D2S_ITEMDATA_IDENTIFIER_HORADRIC_CUBE "box "
  1554 +#define D2S_ITEMDATA_IDENTIFIER_HORADRIC_SCROLL "tr1 "
  1555 +#define D2S_ITEMDATA_IDENTIFIER_STAFF_OF_KINGS "msf "
  1556 +#define D2S_ITEMDATA_IDENTIFIER_VIPER_AMULET "vip "
  1557 +#define D2S_ITEMDATA_IDENTIFIER_HORADRIC_STAFF "hst "
  1558 +#define D2S_ITEMDATA_IDENTIFIER_POTION_OF_LIFE "xyz "
  1559 +#define D2S_ITEMDATA_IDENTIFIER_JADE_FIGURINE "j34 "
  1560 +#define D2S_ITEMDATA_IDENTIFIER_GOLDEN_BIRD "g34 "
  1561 +#define D2S_ITEMDATA_IDENTIFIER_LAM_ESENS_TOME "bbb "
  1562 +#define D2S_ITEMDATA_IDENTIFIER_GIDBINN "g33 "
  1563 +#define D2S_ITEMDATA_IDENTIFIER_KHALIMS_FLAIL "qf1 "
  1564 +#define D2S_ITEMDATA_IDENTIFIER_KHALIMS_WILL "qf2 "
  1565 +#define D2S_ITEMDATA_IDENTIFIER_KHALIMS_EYE "qey "
  1566 +#define D2S_ITEMDATA_IDENTIFIER_KHALIMS_HEART "qhr "
  1567 +#define D2S_ITEMDATA_IDENTIFIER_KHALIMS_BRAIN "qbr "
  1568 +#define D2S_ITEMDATA_IDENTIFIER_MEPHISTOS_SOULSTONE "mss "
  1569 +#define D2S_ITEMDATA_IDENTIFIER_HELLFORGE_HAMMER "hfh "
  1570 +#define D2S_ITEMDATA_IDENTIFIER_MALAH_POTION "ice "
  1571 +#define D2S_ITEMDATA_IDENTIFIER_SCROLL_OF_RESISTANCE "tr2 "
  1572 +#define D2S_ITEMDATA_IDENTIFIER_CHIPPED_AMETHYST "gcv "
  1573 +#define D2S_ITEMDATA_IDENTIFIER_CHIPPED_DIAMOND "gcw "
  1574 +#define D2S_ITEMDATA_IDENTIFIER_CHIPPED_EMERALD "gcg "
  1575 +#define D2S_ITEMDATA_IDENTIFIER_CHIPPED_RUBY "gcr "
  1576 +#define D2S_ITEMDATA_IDENTIFIER_CHIPPED_SAPHIRE "gcb "
  1577 +#define D2S_ITEMDATA_IDENTIFIER_CHIPPED_SKULL "skc "
  1578 +#define D2S_ITEMDATA_IDENTIFIER_CHIPPED_TOPAZ "gcy "
  1579 +#define D2S_ITEMDATA_IDENTIFIER_FLAWED_AMETHYST "gfv "
  1580 +#define D2S_ITEMDATA_IDENTIFIER_FLAWED_DIAMOND "gfw "
  1581 +#define D2S_ITEMDATA_IDENTIFIER_FLAWED_EMERALD "gfg "
  1582 +#define D2S_ITEMDATA_IDENTIFIER_FLAWED_RUBY "gfr "
  1583 +#define D2S_ITEMDATA_IDENTIFIER_FLAWED_SAPHIRE "gfb "
  1584 +#define D2S_ITEMDATA_IDENTIFIER_FLAWED_SKULL "skf "
  1585 +#define D2S_ITEMDATA_IDENTIFIER_FLAWED_TOPAZ "gfy "
  1586 +#define D2S_ITEMDATA_IDENTIFIER_AMETHYST "gsv "
  1587 +#define D2S_ITEMDATA_IDENTIFIER_DIAMOND "gsw "
  1588 +#define D2S_ITEMDATA_IDENTIFIER_EMERALD "gsg "
  1589 +#define D2S_ITEMDATA_IDENTIFIER_RUBY "gsr "
  1590 +#define D2S_ITEMDATA_IDENTIFIER_SAPHIRE "gsb "
  1591 +#define D2S_ITEMDATA_IDENTIFIER_SKULL "sku "
  1592 +#define D2S_ITEMDATA_IDENTIFIER_TOPAZ "gsy "
  1593 +#define D2S_ITEMDATA_IDENTIFIER_FLAWLESS_AMETHYST "gzv "
  1594 +#define D2S_ITEMDATA_IDENTIFIER_FLAWLESS_DIAMOND "glw "
  1595 +#define D2S_ITEMDATA_IDENTIFIER_FLAWLESS_EMERALD "glg "
  1596 +#define D2S_ITEMDATA_IDENTIFIER_FLAWLESS_RUBY "glr "
  1597 +#define D2S_ITEMDATA_IDENTIFIER_FLAWLESS_SAPHIRE "glb "
  1598 +#define D2S_ITEMDATA_IDENTIFIER_FLAWLESS_SKULL "skl "
  1599 +#define D2S_ITEMDATA_IDENTIFIER_FLAWLESS_TOPAZ "gly "
  1600 +#define D2S_ITEMDATA_IDENTIFIER_PERFECT_DIAMOND "gpw "
  1601 +#define D2S_ITEMDATA_IDENTIFIER_PERFECT_AMETHYST "gpv "
  1602 +#define D2S_ITEMDATA_IDENTIFIER_PERFECT_SAPPHIRE "gpb "
  1603 +#define D2S_ITEMDATA_IDENTIFIER_PERFECT_TOPAZ "gpy "
  1604 +#define D2S_ITEMDATA_IDENTIFIER_PERFECT_RUBY "gpr "
  1605 +#define D2S_ITEMDATA_IDENTIFIER_PERFECT_SKULL "skz "
  1606 +#define D2S_ITEMDATA_IDENTIFIER_PERFECT_EMERALD "gpg "
  1607 +#define D2S_ITEMDATA_IDENTIFIER_EL_RUNE "r01 "
  1608 +#define D2S_ITEMDATA_IDENTIFIER_ELD_RUNE "r02 "
  1609 +#define D2S_ITEMDATA_IDENTIFIER_TIR_RUNE "r03 "
  1610 +#define D2S_ITEMDATA_IDENTIFIER_NEF_RUNE "r04 "
  1611 +#define D2S_ITEMDATA_IDENTIFIER_ETH_RUNE "r05 "
  1612 +#define D2S_ITEMDATA_IDENTIFIER_ITH_RUNE "r06 "
  1613 +#define D2S_ITEMDATA_IDENTIFIER_TAL_RUNE "r07 "
  1614 +#define D2S_ITEMDATA_IDENTIFIER_RAL_RUNE "r08 "
  1615 +#define D2S_ITEMDATA_IDENTIFIER_ORT_RUNE "r09 "
  1616 +#define D2S_ITEMDATA_IDENTIFIER_THUL_RUNE "r10 "
  1617 +#define D2S_ITEMDATA_IDENTIFIER_AMN_RUNE "r11 "
  1618 +#define D2S_ITEMDATA_IDENTIFIER_SOL_RUNE "r12 "
  1619 +#define D2S_ITEMDATA_IDENTIFIER_SHAEL_RUNE "r13 "
  1620 +#define D2S_ITEMDATA_IDENTIFIER_DOL_RUNE "r14 "
  1621 +#define D2S_ITEMDATA_IDENTIFIER_HEL_RUNE "r15 "
  1622 +#define D2S_ITEMDATA_IDENTIFIER_IO_RUNE "r16 "
  1623 +#define D2S_ITEMDATA_IDENTIFIER_LUM_RUNE "r17 "
  1624 +#define D2S_ITEMDATA_IDENTIFIER_KO_RUNE "r18 "
  1625 +#define D2S_ITEMDATA_IDENTIFIER_FAL_RUNE "r19 "
  1626 +#define D2S_ITEMDATA_IDENTIFIER_LEM_RUNE "r20 "
  1627 +#define D2S_ITEMDATA_IDENTIFIER_PUL_RUNE "r21 "
  1628 +#define D2S_ITEMDATA_IDENTIFIER_UM_RUNE "r22 "
  1629 +#define D2S_ITEMDATA_IDENTIFIER_MAL_RUNE "r23 "
  1630 +#define D2S_ITEMDATA_IDENTIFIER_IST_RUNE "r24 "
  1631 +#define D2S_ITEMDATA_IDENTIFIER_GUL_RUNE "r25 "
  1632 +#define D2S_ITEMDATA_IDENTIFIER_VEX_RUNE "r26 "
  1633 +#define D2S_ITEMDATA_IDENTIFIER_OHM_RUNE "r27 "
  1634 +#define D2S_ITEMDATA_IDENTIFIER_LO_RUNE "r28 "
  1635 +#define D2S_ITEMDATA_IDENTIFIER_SUR_RUNE "r29 "
  1636 +#define D2S_ITEMDATA_IDENTIFIER_BER_RUNE "r30 "
  1637 +#define D2S_ITEMDATA_IDENTIFIER_JAH_RUNE "r31 "
  1638 +#define D2S_ITEMDATA_IDENTIFIER_CHAM_RUNE "r32 "
  1639 +#define D2S_ITEMDATA_IDENTIFIER_ZOD_RUNE "r33 "
  1640 +#define D2S_ITEMDATA_IDENTIFIER_ANTIDOTE_POTION "yps "
  1641 +#define D2S_ITEMDATA_IDENTIFIER_STAMINA_POTION "vps "
  1642 +#define D2S_ITEMDATA_IDENTIFIER_THAWING_POTION "wms "
  1643 +#define D2S_ITEMDATA_IDENTIFIER_MINOR_HEALING_POTION "hp1 "
  1644 +#define D2S_ITEMDATA_IDENTIFIER_MINOR_MANA_POTION "mp1 "
  1645 +#define D2S_ITEMDATA_IDENTIFIER_LIGHT_HEALING_POTION "hp2 "
  1646 +#define D2S_ITEMDATA_IDENTIFIER_LIGHT_MANA_POTION "mp2 "
  1647 +#define D2S_ITEMDATA_IDENTIFIER_HEALING_POTION "hp3 "
  1648 +#define D2S_ITEMDATA_IDENTIFIER_MANA_POTION "mp3 "
  1649 +#define D2S_ITEMDATA_IDENTIFIER_GREATER_HEALING_POTION "hp4 "
  1650 +#define D2S_ITEMDATA_IDENTIFIER_GREATER_MANA_POTION "mp4 "
  1651 +#define D2S_ITEMDATA_IDENTIFIER_SUPER_HEALING_POTION "hp5 "
  1652 +#define D2S_ITEMDATA_IDENTIFIER_SUPER_MANA_POTION "mp5 "
  1653 +#define D2S_ITEMDATA_IDENTIFIER_REJUVENATION_POTION "rvs "
  1654 +#define D2S_ITEMDATA_IDENTIFIER_FULL_REJUVENATION_POTION "rvl "
  1655 +#define D2S_ITEMDATA_IDENTIFIER_CHARM_SMALL "cm1 "
  1656 +#define D2S_ITEMDATA_IDENTIFIER_CHARM_LARGE "cm2 "
  1657 +#define D2S_ITEMDATA_IDENTIFIER_CHARM_GRAND "cm3 "
  1658 +#define D2S_ITEMDATA_IDENTIFIER_IDENTIFY_SCROLL "isc "
  1659 +#define D2S_ITEMDATA_IDENTIFIER_TOWN_PORTAL_SCROLL "tsc "
  1660 +#define D2S_ITEMDATA_IDENTIFIER_TOME_OF_TOWN_PORTAL "tbk "
  1661 +#define D2S_ITEMDATA_IDENTIFIER_TOME_OF_IDENTIFY "ibk "
  1662 +#define D2S_ITEMDATA_IDENTIFIER_ARROWS "aqv "
  1663 +#define D2S_ITEMDATA_IDENTIFIER_BOLTS "cqv "
  1664 +#define D2S_ITEMDATA_IDENTIFIER_JEWEL "jew "
  1665 +#define D2S_ITEMDATA_IDENTIFIER_KEY "key "
  1666 +#define D2S_ITEMDATA_IDENTIFIER_AMULET "amu "
  1667 +#define D2S_ITEMDATA_IDENTIFIER_GOLD "gld "
  1668 +#define D2S_ITEMDATA_IDENTIFIER_RING "rin "
  1669 +#define D2S_ITEMDATA_IDENTIFIER_EAR "ear "
  1670 +
  1671 +// Unused
  1672 +#define D2S_ITEMDATA_IDENTIFIER_TORCH "tch "
  1673 +#define D2S_ITEMDATA_IDENTIFIER_HEART "hrt "
  1674 +#define D2S_ITEMDATA_IDENTIFIER_BRAIN "brz "
  1675 +#define D2S_ITEMDATA_IDENTIFIER_JAWBONE "jaw "
  1676 +#define D2S_ITEMDATA_IDENTIFIER_EYE "eyz "
  1677 +#define D2S_ITEMDATA_IDENTIFIER_HORN "hrn "
  1678 +#define D2S_ITEMDATA_IDENTIFIER_HERB "hrb "
  1679 +#define D2S_ITEMDATA_IDENTIFIER_TAIL "tal "
  1680 +#define D2S_ITEMDATA_IDENTIFIER_FLAG "flg "
  1681 +#define D2S_ITEMDATA_IDENTIFIER_FANG "fng "
  1682 +#define D2S_ITEMDATA_IDENTIFIER_QUILL "qll "
  1683 +#define D2S_ITEMDATA_IDENTIFIER_SOUL "sol "
  1684 +#define D2S_ITEMDATA_IDENTIFIER_SCALP "scz "
  1685 +#define D2S_ITEMDATA_IDENTIFIER_SPLEEN "spe "
  1686 +#define D2S_ITEMDATA_IDENTIFIER_BLACK_TOWER_KEY "luv "
  1687 +#define D2S_ITEMDATA_IDENTIFIER_ELIXIR "elx "
  1688 +#define D2S_ITEMDATA_IDENTIFIER_SCROLL_OF_KNOWLEDGE "0sc "
  1689 +
1048 1690 #endif
1049 1691 \ No newline at end of file
... ...
docs/d2s_save_item_format_1.13d.txt
... ... @@ -191,7 +191,7 @@ the future. All sizes are in bits unless otherwise specified.
191 191 │ │ │old data from the last time the item was stored. I.e., it │
192 192 │ │ │may be non-zero, but the value is unused. │
193 193 ├────────┼───────┼────────────────────────────────────────────────────────────┤
194   -│72 │1 │unknown
  194 +│72 │1 │Set Name Has Suffix (?)
195 195 ├────────┼───────┼────────────────────────────────────────────────────────────┤
196 196 │ │ │Actually, bit 74 seems to always be 0, but since bits 73 and│
197 197 │ │ │75 are related I just lump them all together. If the item is│
... ... @@ -670,7 +670,7 @@ personalized.
670 670 │7 │0 (this indicates the end of the name) │
671 671 └───────────────┴─────────────────────────────────────────────────────────────┘
672 672  
673   -Unknown Field
  673 +Unknown Field MAYBE WROOOOONG
674 674  
675 675 All items have this field between the personalization (if it exists) and the
676 676 item-specific data:
... ...
docs/design
... ... @@ -27,6 +27,17 @@ User should be able to:
27 27 - get waypoint active
28 28 - set waypoint active
29 29  
  30 + items
  31 + ---------
  32 + - add/remove sockets
  33 + - add/remove personalisation
  34 + - add/remove ethereal
  35 + - add/remove indestructible
  36 + - change durability
  37 + - change item level
  38 + - spawn unique # get normal and unique and compare
  39 + - spawn set # get normal and set and compare
  40 + - import/export
30 41  
31 42  
32 43  
... ...