// Reads the owner's designs extract ($SOTS_DESIGNS_JSON): every design of // every player in the real saves, decoded into the save-record shape // (`raw_slots`: species index, section id, one weapon id/file per bank, the // DOpts list) plus the player's researched techs and the reference reader's // resolved view (section stems, stripped options) that the test cross-checks. // The file is game-derived and never enters the repo. #pragma once #include #include #include #include "game/design/design.h" struct StockDesign { int player_index = 0, design_index = 0; std::string save, player, race_text, list; bool npc = false; game::design::Design design; // options hold the raw DOpts until stripped std::array expect_stem{}; // reference view: section stem per used slot ("" = empty) std::array, 3> expect_options{}; // reference view: chosen options std::array, 3> dopts{}; // the save's DOpts per used slot std::array bank_count{}; // the save's bank count per used slot }; // False (and `err`) when the file cannot be read or has an unexpected shape. bool load_stock_designs(const std::string& path, std::vector& out, std::string& err);