about summary refs log tree commit diff stats
path: root/data/maps/the_ancient/connections.txtpb
diff options
context:
space:
mode:
Diffstat (limited to 'data/maps/the_ancient/connections.txtpb')
0 files changed, 0 insertions, 0 deletions
a7e0868c7e97d862b1feb468d3'>7f4b6b4 ^
738d970 ^
4ffb587 ^
7f4b6b4 ^

738d970 ^
7f4b6b4 ^


738d970 ^
7f4b6b4 ^


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35








                              







                                               



                  
                                               
 
                                                                        
 

                                     
                                                             


         
                                                        


                                                         
#ifndef NETWORK_SET_H_3036B8E3
#define NETWORK_SET_H_3036B8E3

#include <map>
#include <optional>
#include <set>
#include <utility>
#include <vector>

struct NetworkNode {
  int entry;
  int exit;
  bool two_way;

  bool operator<(const NetworkNode& rhs) const;
};

class NetworkSet {
 public:
  void Clear();

  void AddLink(int id1, int id2, bool two_way);

  void AddLinkToNetwork(int network_id, int id1, int id2, bool two_way);

  bool IsItemInNetwork(int id) const;

  const std::set<NetworkNode>& GetNetworkGraph(int id) const;

 private:

  std::map<int, std::set<NetworkNode>> network_by_item_;
};

#endif /* end of include guard: NETWORK_SET_H_3036B8E3 */