about summary refs log tree commit diff stats
path: root/tools/validator/structs.h
diff options
context:
space:
mode:
Diffstat (limited to 'tools/validator/structs.h')
-rw-r--r--tools/validator/structs.h52
1 files changed, 52 insertions, 0 deletions
diff --git a/tools/validator/structs.h b/tools/validator/structs.h index c3427f4..62974a8 100644 --- a/tools/validator/structs.h +++ b/tools/validator/structs.h
@@ -20,6 +20,17 @@ struct MalformedIdentifiers {
20 } 20 }
21}; 21};
22 22
23struct GameNodeInfo {
24 bool defined = false;
25 int uses = 0;
26};
27
28struct MapInfo {
29 std::map<std::string, GameNodeInfo> game_nodes;
30
31 std::optional<PortIdentifier> malformed_worldport_entrance;
32};
33
23struct RoomInfo { 34struct RoomInfo {
24 std::vector<HumanRoom> definitions; 35 std::vector<HumanRoom> definitions;
25 36
@@ -30,26 +41,33 @@ struct RoomInfo {
30 41
31struct DoorInfo { 42struct DoorInfo {
32 std::vector<HumanDoor> definitions; 43 std::vector<HumanDoor> definitions;
44 bool has_id = false;
33 45
34 std::vector<HumanConnection> connections_referenced_by; 46 std::vector<HumanConnection> connections_referenced_by;
35 std::vector<DoorIdentifier> doors_referenced_by; 47 std::vector<DoorIdentifier> doors_referenced_by;
36 std::vector<PanelIdentifier> panels_referenced_by; 48 std::vector<PanelIdentifier> panels_referenced_by;
37 std::vector<PaintingIdentifier> paintings_referenced_by; 49 std::vector<PaintingIdentifier> paintings_referenced_by;
38 std::vector<PortIdentifier> ports_referenced_by; 50 std::vector<PortIdentifier> ports_referenced_by;
51 std::vector<std::string> progressives_referenced_by;
52 std::vector<std::string> door_groups_referenced_by;
39 53
40 MalformedIdentifiers malformed_identifiers; 54 MalformedIdentifiers malformed_identifiers;
41}; 55};
42 56
43struct PortInfo { 57struct PortInfo {
44 std::vector<HumanPort> definitions; 58 std::vector<HumanPort> definitions;
59 bool has_id = false;
45 60
46 std::vector<HumanConnection> connections_referenced_by; 61 std::vector<HumanConnection> connections_referenced_by;
62 std::vector<HumanConnection> target_connections_referenced_by;
63 std::vector<std::string> map_worldport_entrances;
47}; 64};
48 65
49struct PaintingInfo { 66struct PaintingInfo {
50 std::vector<HumanPainting> definitions; 67 std::vector<HumanPainting> definitions;
51 68
52 std::vector<HumanConnection> connections_referenced_by; 69 std::vector<HumanConnection> connections_referenced_by;
70 std::vector<HumanConnection> target_connections_referenced_by;
53 std::vector<DoorIdentifier> doors_referenced_by; 71 std::vector<DoorIdentifier> doors_referenced_by;
54}; 72};
55 73
@@ -62,8 +80,12 @@ struct ProxyInfo {
62 80
63struct PanelInfo { 81struct PanelInfo {
64 std::vector<HumanPanel> definitions; 82 std::vector<HumanPanel> definitions;
83 bool has_id = false;
84
85 std::string map_area_name;
65 86
66 std::vector<HumanConnection> connections_referenced_by; 87 std::vector<HumanConnection> connections_referenced_by;
88 std::vector<HumanConnection> target_connections_referenced_by;
67 std::vector<DoorIdentifier> doors_referenced_by; 89 std::vector<DoorIdentifier> doors_referenced_by;
68 90
69 std::map<std::string, ProxyInfo> proxies; 91 std::map<std::string, ProxyInfo> proxies;
@@ -71,6 +93,7 @@ struct PanelInfo {
71 93
72struct KeyholderInfo { 94struct KeyholderInfo {
73 std::vector<HumanKeyholder> definitions; 95 std::vector<HumanKeyholder> definitions;
96 bool has_id = false;
74 97
75 std::vector<DoorIdentifier> doors_referenced_by; 98 std::vector<DoorIdentifier> doors_referenced_by;
76}; 99};
@@ -79,9 +102,34 @@ using LetterIdentifier = std::tuple<char, bool>;
79 102
80struct LetterInfo { 103struct LetterInfo {
81 std::vector<RoomIdentifier> defined_in; 104 std::vector<RoomIdentifier> defined_in;
105 bool has_id = false;
106};
107
108struct EndingInfo {
109 std::vector<RoomIdentifier> defined_in;
110 bool has_id = false;
111};
112
113struct PanelNameInfo {
114 std::vector<PanelIdentifier> panels_used_by;
115};
116
117struct ProgressiveInfo {
118 std::vector<HumanProgressive> definitions;
119 bool has_id = false;
120
121 std::vector<DoorIdentifier> malformed_doors;
122};
123
124struct DoorGroupInfo {
125 std::vector<HumanDoorGroup> definitions;
126 bool has_id = false;
127
128 std::vector<DoorIdentifier> malformed_doors;
82}; 129};
83 130
84struct CollectedInfo { 131struct CollectedInfo {
132 std::map<std::string, MapInfo> maps;
85 std::map<RoomIdentifier, RoomInfo, RoomIdentifierLess> rooms; 133 std::map<RoomIdentifier, RoomInfo, RoomIdentifierLess> rooms;
86 std::map<DoorIdentifier, DoorInfo, DoorIdentifierLess> doors; 134 std::map<DoorIdentifier, DoorInfo, DoorIdentifierLess> doors;
87 std::map<PortIdentifier, PortInfo, PortIdentifierLess> ports; 135 std::map<PortIdentifier, PortInfo, PortIdentifierLess> ports;
@@ -90,6 +138,10 @@ struct CollectedInfo {
90 std::map<KeyholderIdentifier, KeyholderInfo, KeyholderIdentifierLess> 138 std::map<KeyholderIdentifier, KeyholderInfo, KeyholderIdentifierLess>
91 keyholders; 139 keyholders;
92 std::map<LetterIdentifier, LetterInfo> letters; 140 std::map<LetterIdentifier, LetterInfo> letters;
141 std::map<std::string, EndingInfo> endings;
142 std::map<std::string, PanelNameInfo> panel_names;
143 std::map<std::string, ProgressiveInfo> progressives;
144 std::map<std::string, DoorGroupInfo> door_groups;
93}; 145};
94 146
95} // namespace com::fourisland::lingo2_archipelago 147} // namespace com::fourisland::lingo2_archipelago