about summary refs log tree commit diff stats
path: root/src/game_data.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/game_data.h')
-rw-r--r--src/game_data.h40
1 files changed, 37 insertions, 3 deletions
diff --git a/src/game_data.h b/src/game_data.h index e30675a..b787e6f 100644 --- a/src/game_data.h +++ b/src/game_data.h
@@ -64,6 +64,7 @@ struct ProgressiveRequirement {
64}; 64};
65 65
66struct Door { 66struct Door {
67 int id;
67 int room; 68 int room;
68 std::string name; 69 std::string name;
69 std::string location_name; 70 std::string location_name;
@@ -88,14 +89,17 @@ struct Exit {
88}; 89};
89 90
90struct PaintingExit { 91struct PaintingExit {
91 std::string id; 92 int id;
93 int room;
94 std::string internal_id;
92 std::optional<int> door; 95 std::optional<int> door;
96 bool entrance = false;
93}; 97};
94 98
95struct Room { 99struct Room {
96 std::string name; 100 std::string name;
97 std::vector<Exit> exits; 101 std::vector<Exit> exits;
98 std::vector<PaintingExit> paintings; 102 std::vector<int> paintings;
99 std::vector<int> sunwarps; 103 std::vector<int> sunwarps;
100 std::vector<int> panels; 104 std::vector<int> panels;
101}; 105};
@@ -114,12 +118,37 @@ struct MapArea {
114 int id; 118 int id;
115 std::string name; 119 std::string name;
116 std::vector<Location> locations; 120 std::vector<Location> locations;
121 std::vector<int> paintings;
117 int map_x; 122 int map_x;
118 int map_y; 123 int map_y;
119 int classification = 0; 124 int classification = 0;
120 bool hunt = false; 125 bool hunt = false;
121}; 126};
122 127
128enum class SubwaySunwarpType {
129 kEnter,
130 kExit,
131 kFinal
132};
133
134struct SubwaySunwarp {
135 int dots;
136 SubwaySunwarpType type;
137
138 bool operator<(const SubwaySunwarp& rhs) const;
139};
140
141struct SubwayItem {
142 int id;
143 int x;
144 int y;
145 std::optional<int> door;
146 std::vector<std::string> paintings;
147 std::vector<std::string> tags;
148 std::optional<SubwaySunwarp> sunwarp;
149 std::optional<std::string> special;
150};
151
123const std::vector<MapArea>& GD_GetMapAreas(); 152const std::vector<MapArea>& GD_GetMapAreas();
124const MapArea& GD_GetMapArea(int id); 153const MapArea& GD_GetMapArea(int id);
125int GD_GetRoomByName(const std::string& name); 154int GD_GetRoomByName(const std::string& name);
@@ -128,10 +157,15 @@ const std::vector<Door>& GD_GetDoors();
128const Door& GD_GetDoor(int door_id); 157const Door& GD_GetDoor(int door_id);
129int GD_GetDoorByName(const std::string& name); 158int GD_GetDoorByName(const std::string& name);
130const Panel& GD_GetPanel(int panel_id); 159const Panel& GD_GetPanel(int panel_id);
131int GD_GetRoomForPainting(const std::string& painting_id); 160const PaintingExit& GD_GetPaintingExit(int painting_id);
161int GD_GetPaintingByName(const std::string& name);
132const std::vector<int>& GD_GetAchievementPanels(); 162const std::vector<int>& GD_GetAchievementPanels();
133int GD_GetItemIdForColor(LingoColor color); 163int GD_GetItemIdForColor(LingoColor color);
134const std::vector<int>& GD_GetSunwarpDoors(); 164const std::vector<int>& GD_GetSunwarpDoors();
135int GD_GetRoomForSunwarp(int index); 165int GD_GetRoomForSunwarp(int index);
166const std::vector<SubwayItem>& GD_GetSubwayItems();
167const SubwayItem& GD_GetSubwayItem(int id);
168std::optional<int> GD_GetSubwayItemForPainting(const std::string& painting_id);
169int GD_GetSubwayItemForSunwarp(const SubwaySunwarp& sunwarp);
136 170
137#endif /* end of include guard: GAME_DATA_H_9C42AC51 */ 171#endif /* end of include guard: GAME_DATA_H_9C42AC51 */