|
@@ -10,6 +10,10 @@
|
|
|
#include <ostream>
|
|
|
|
|
|
enum PRODUCT { FUEL = 0, ORG = 1, EQUIP = 2 };
|
|
|
+
|
|
|
+// Class 0 : Special
|
|
|
+// Class 9 : StarDock BBB
|
|
|
+
|
|
|
// typedef std::array<bool, 3> buysell;
|
|
|
struct buysell {
|
|
|
bool foe[3];
|
|
@@ -27,6 +31,22 @@ struct buysell_text {
|
|
|
friend std::ostream& operator<<(std::ostream& os, const buysell_text &bst);
|
|
|
};
|
|
|
|
|
|
+#define MAX_WARPS 6
|
|
|
+
|
|
|
+typedef uint16_t sector_type;
|
|
|
+
|
|
|
+struct sector_warps {
|
|
|
+ sector_type sector;
|
|
|
+ // std::set<sector_type> warps; // possibly
|
|
|
+ sector_type warps[MAX_WARPS];
|
|
|
+ // ports
|
|
|
+ // planets
|
|
|
+ // ctor that zeros everything out?
|
|
|
+ sector_warps();
|
|
|
+ void add(sector_type sector);
|
|
|
+ // add() that adds warp to end of warps?
|
|
|
+};
|
|
|
+
|
|
|
/*
|
|
|
1 : "BBS", TTF
|
|
|
2 : "BSB", TFT
|
|
@@ -36,6 +56,7 @@ struct buysell_text {
|
|
|
6 : "BSS", TFF
|
|
|
7 : "SSS", FFF
|
|
|
8 : "BBB", TTT
|
|
|
+9 : "BBB", TTT
|
|
|
*/
|
|
|
|
|
|
/* convert type to buysell flag values, buy = true */
|
|
@@ -57,6 +78,7 @@ constexpr buysell get_buysell(uint8_t type) {
|
|
|
case 7: // SSS FFF
|
|
|
return {false, false, false};
|
|
|
case 8: // BBB TTT
|
|
|
+ case 9:
|
|
|
return {true, true, true};
|
|
|
default:
|
|
|
throw std::invalid_argument("invalid buysell type");
|
|
@@ -88,6 +110,7 @@ constexpr buysell_text text_from_type(uint8_t type) {
|
|
|
case 7:
|
|
|
return buysell_text{'S', 'S', 'S'};
|
|
|
case 8:
|
|
|
+ case 9:
|
|
|
return buysell_text{'B', 'B', 'B'};
|
|
|
default:
|
|
|
throw std::invalid_argument("invalid text_from_type type");
|