Files
2026-11-23 03:28:32 +02:00

47 lines
3.1 KiB
C++

// Turtle server-generated transmog item templates (Claude lane, 2026-11-22).
// Tortoise creates one item_template per transmog: entry >= 600000 (910000-919999 are real items), same name/class/
// subclass/inventory type as a real base item, display of the transmog source. They are not catalogue items: the
// gateway resolves transmog looks through item_render_profile. The codec sends their Item/ItemSparse rows, and
// ItemModifiedAppearance rows naming them, as removals so cached copies leave the client.
// Rule source: tw_world item_template (131 entries); see docs/AUDIT-unshipped-fixes-20261122.md.
#pragma once
#include <algorithm>
#include <cstdint>
#include <iterator>
namespace gateway::generated_transmog_items {
inline constexpr std::uint32_t Ids[] = {
604518, 939836, 1245005, 1245747, 1283385, 1297629, 1316602, 1351767, 1363583, 1447079,
1447080, 1447081, 1447082, 1467905, 1487825, 1568468, 1568469, 1586121, 1586329, 1594113,
1634105, 1634107, 1696579, 1710912, 1725529, 1732025, 1732029, 1732038, 1738324, 1745702,
1756154, 1758375, 1784242, 1784244, 1784245, 1784248, 1784249, 1784250, 1802333, 1814423,
1861523, 1891641, 1892919, 1899480, 1899481, 1899482, 1899483, 1899596, 1901786, 1901787,
1906961, 1915084, 1918162, 1918525, 1921162, 1927291, 1927738, 1927740, 1943560, 1943561,
1943602, 1956206, 1956860, 1956894, 1957950, 1958997, 1963148, 1965577, 1966257, 1968914,
1968915, 1971301, 1976791, 1978815, 1980135, 1980518, 1980584, 1980971, 1980972, 1980973,
1980974, 1980975, 1980976, 1980977, 1980978, 1980979, 1981001, 1981142, 1981843, 1982111,
1982112, 1982313, 1982338, 1982860, 1982861, 1982862, 1983122, 1983136, 1983137, 1983138,
1983148, 1983149, 1983150, 1983151, 1983152, 1983153, 1983154, 1983292, 1983345, 1983346,
1983348, 1983349, 1983350, 1983351, 1983352, 1983353, 1983411, 1983618, 1983619, 1983851,
1983863, 1984562, 1984977, 1984978, 1984979, 1984980, 1984981, 1985402, 1985403, 1985404,
1985406
};
inline constexpr std::uint32_t ItemTable = 0x50238ec2u, ItemSparseTable = 0x919be54eu, ModifiedAppearanceTable = 0xe491ac55u;
inline bool generated(std::uint32_t item) {
return std::binary_search(std::begin(Ids), std::end(Ids), item);
}
// Toy table rows hand an item's spell to the toy box, which the Turtle server never fills: the client then drops
// those spells from the known list. Toys stay ordinary known spells (spellbook Toys tab), so Toy rows are removed.
inline constexpr std::uint32_t ToyTable = 0x7b03245cu;
// True for a packaged row the client must not keep: generated transmog templates and Toy rows.
template <class Row> bool row(const Row& r) {
if (r.table == ToyTable) return true;
if (r.table == ItemTable || r.table == ItemSparseTable) return generated(std::uint32_t(r.id));
if (r.table == ModifiedAppearanceTable && r.data.size() >= 8) {
const auto* p = reinterpret_cast<const unsigned char*>(r.data.data()) + 4; // ID, then ItemID
return generated(std::uint32_t(p[0]) | std::uint32_t(p[1]) << 8 | std::uint32_t(p[2]) << 16 | std::uint32_t(p[3]) << 24);
}
return false;
}
} // namespace gateway::generated_transmog_items