summary refs log tree commit diff stats
path: root/proto
diff options
context:
space:
mode:
authorStar Rauchenberger <fefferburbia@gmail.com>2025-08-07 13:34:42 -0400
committerStar Rauchenberger <fefferburbia@gmail.com>2025-08-07 13:34:42 -0400
commite9d9da34e86a1e5f0de155bf9086d3e5ff6b2da0 (patch)
tree432e1177f11e7e2b5e0d6400fad977def7d31129 /proto
parent1eacf01378d4dff3aed73fffcc42e0352b93835e (diff)
downloadlingo2-archipelago-e9d9da34e86a1e5f0de155bf9086d3e5ff6b2da0.tar.gz
lingo2-archipelago-e9d9da34e86a1e5f0de155bf9086d3e5ff6b2da0.tar.bz2
lingo2-archipelago-e9d9da34e86a1e5f0de155bf9086d3e5ff6b2da0.zip
Protobuf works! Parsing connections
Diffstat (limited to 'proto')
-rw-r--r--proto/CMakeLists.txt11
-rw-r--r--proto/common.proto13
-rw-r--r--proto/data.proto13
-rw-r--r--proto/human.proto12
4 files changed, 36 insertions, 13 deletions
diff --git a/proto/CMakeLists.txt b/proto/CMakeLists.txt new file mode 100644 index 0000000..c5abd46 --- /dev/null +++ b/proto/CMakeLists.txt
@@ -0,0 +1,11 @@
1find_package(Protobuf REQUIRED)
2
3add_library(protos)
4
5protobuf_generate(
6 LANGUAGE cpp
7 TARGET protos
8 PROTOS human.proto data.proto common.proto
9)
10
11target_link_libraries(protos PUBLIC protobuf::libprotobuf)
diff --git a/proto/common.proto b/proto/common.proto new file mode 100644 index 0000000..eb1d6b5 --- /dev/null +++ b/proto/common.proto
@@ -0,0 +1,13 @@
1edition = "2023";
2
3package com.fourisland.lingo2_archipelago;
4
5message Proxy {
6 string answer = 1;
7 string path = 2;
8}
9
10message Letter {
11 string letter = 1;
12 bool double = 2;
13}
diff --git a/proto/data.proto b/proto/data.proto index 71c3aeb..b3b6e6b 100644 --- a/proto/data.proto +++ b/proto/data.proto
@@ -1,5 +1,7 @@
1edition = "2023"; 1edition = "2023";
2 2
3import "common.proto";
4
3package com.fourisland.lingo2_archipelago; 5package com.fourisland.lingo2_archipelago;
4 6
5message ProxyIdentifier { 7message ProxyIdentifier {
@@ -8,11 +10,9 @@ message ProxyIdentifier {
8} 10}
9 11
10message Connection { 12message Connection {
11 uint64 id = 7;
12
13 uint64 from_room = 1; 13 uint64 from_room = 1;
14 uint64 to_room = 2; 14 uint64 to_room = 2;
15 repeated uint64 required_door = 3; 15 uint64 required_door = 3;
16 16
17 oneof trigger { 17 oneof trigger {
18 uint64 port = 4; 18 uint64 port = 4;
@@ -82,6 +82,7 @@ message Port {
82 82
83message Room { 83message Room {
84 uint64 id = 1; 84 uint64 id = 1;
85 uint64 map_id = 8;
85 string name = 2; 86 string name = 2;
86 string display_name = 3; 87 string display_name = 3;
87 88
@@ -91,7 +92,13 @@ message Room {
91 repeated uint64 ports = 7; 92 repeated uint64 ports = 7;
92} 93}
93 94
95message Map {
96 uint64 id = 1;
97 string name = 2;
98}
99
94message AllObjects { 100message AllObjects {
101 repeated Map maps = 7;
95 repeated Room rooms = 1; 102 repeated Room rooms = 1;
96 repeated Door doors = 2; 103 repeated Door doors = 2;
97 repeated Panel panels = 3; 104 repeated Panel panels = 3;
diff --git a/proto/human.proto b/proto/human.proto index 06c89cd..cdbb8b9 100644 --- a/proto/human.proto +++ b/proto/human.proto
@@ -1,5 +1,7 @@
1edition = "2023"; 1edition = "2023";
2 2
3import "common.proto";
4
3package com.fourisland.lingo2_archipelago; 5package com.fourisland.lingo2_archipelago;
4 6
5message RoomIdentifier { 7message RoomIdentifier {
@@ -93,11 +95,6 @@ message HumanDoors {
93 repeated HumanDoor doors = 1; 95 repeated HumanDoor doors = 1;
94} 96}
95 97
96message Proxy {
97 string answer = 1;
98 string path = 2;
99}
100
101message HumanPanel { 98message HumanPanel {
102 string name = 1; 99 string name = 1;
103 string path = 5; 100 string path = 5;
@@ -125,11 +122,6 @@ message HumanPainting {
125 DoorIdentifier required_door = 5; 122 DoorIdentifier required_door = 5;
126} 123}
127 124
128message Letter {
129 string letter = 1;
130 bool double = 2;
131}
132
133message HumanPort { 125message HumanPort {
134 string name = 1; 126 string name = 1;
135 string path = 2; 127 string path = 2;