
Granblue Fantasy Character Game Art Black knight, Knight, game, cg Artwork, fictional Character png 640圆88px 164.33KB.female character holding scepter illustration, Dungeons & Dragons Pathfinder Roleplaying Game d20 System Role-playing game Sorcerer, rpg, elf, middle Ages, roleplaying png 576x1088px 648.19KB.Pathfinder Roleplaying Game Dungeons & Dragons Half-orc Warrior, pathfinder, game, fictional Character, action Figure png 2172x3631px 3.53MB.Dungeons & Dragons Pathfinder Roleplaying Game d20 System Fighter Warrior, cleric, human, fictional Character, d20 System png 727x1000px 711.72KB.Pathfinder Roleplaying Game Dungeons & Dragons Troll Fantasy, Dwarf, legendary Creature, game, elf png 962x1120px 1.45MB.Dungeons & Dragons Pathfinder Roleplaying Game Role-playing game Warrior Player character, warrior, game, weapon, forest png 564x798px 295.8KB.Pathfinder Roleplaying Game Dungeons & Dragons Ranger Non-player character, bearded dragon, game, animals, human png 750x750px 301.52KB.female knight illustration, Knight Female Plate armour Woman, Shield sword warrior woman, business Woman, shields, cartoon png 658x1000px 539.71KB.World of Warcraft female elf illustration, Dungeons & Dragons Pathfinder Roleplaying Game d20 System Character Fantasy, Woman Warrior Pic, cg Artwork, elf, human png 649x1000px 542.96KB.woman holding 2 swords illustration, Dungeons & Dragons Pathfinder Roleplaying Game Elf Concept art Character, dungeons and dragons, game, fictional Character, cartoon png 534x732px 331.28KB.man holding black sword illustration, Dungeons & Dragons Pathfinder Roleplaying Game d20 System Elf Sorcerer, Elf, cartoon, wizard, d20 System png 481x765px 285.94KB.black hair cartoon character, Soulcalibur IV Soul Edge Soulcalibur V Soulcalibur II, samurai, video Game, fictional Character, weapon png 1524x2204px 3.3MB.Nier: Automata Video game Anime, Anime, comics, game, cg Artwork png 692x1200px 586.8KB.Werewolf Pathfinder Roleplaying Game Dungeons & Dragons d20 System Thief, werewolf, game, fictional Character, d20 System png 623x1000px 479.57KB.Dungeons & Dragons Aasimar Role-playing game Player character Angel, warrior, fictional Character, weapon, mythology png 545x797px 425.75KB.Dungeons & Dragons Pathfinder Roleplaying Game Elf Concept art Character, Elf, fictional Character, cartoon, weapon png 900x1200px 661.06KB.Now we'll do some dark magic, we'll move the sort function at the beginning of previously shown code, like so: Sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum()) M_map_itemTableByVnum.insert(std::map::value_type(item_table->dwVnum, item_table)) Sys_log(1, "ITEM: #%-5lu %-24s %-24s VAL: %ld %ld %ld %ld %ld %ld WEAR %lu ANTI %lu IMMUNE %lu REFINE %lu REFINE_SET %u MAGIC_PCT %u", Go over to server source, database/ClientManagerBoot.cpp, at the end of the following function:īool CClientManager::InitializeItemTable() Guessed what happened? An item with vnum 19709 had an item table of the item with vnum 20009 because you donkey were too lazy to put new proto entries in the correct order. Long story short: It first inserts key-value to map m_map_itemTableByVnum where the key was an integer (item vnum) and the value was a pointer that pointed to an item table object at position X in m_vec_itemTable but at the end, it sorted this very vector while values in map still pointed to the same positions in the vector.

Recently I've come across an issue with a customer who had item proto entries all over the place and when the database tried to sort that mess, it messed it up even more, eventually, it messed up this very Monday for me as I spent hours debugging this.
