Skip to content

Commit 2dd8b43

Browse files
committed
Update protobuf documentation
1 parent a772965 commit 2dd8b43

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

proto/ssl_gc_api.proto

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,25 +8,42 @@ import "ssl_gc_engine.proto";
88

99
import "google/protobuf/duration.proto";
1010

11+
// Message format that is pushed from the GC to the client
1112
message Output {
13+
// The current match state
1214
optional State match_state = 1;
15+
// The current GC state
1316
optional GcState gc_state = 2;
17+
// The protocol
1418
optional Protocol protocol = 3;
1519
}
1620

21+
// The game protocol
1722
message Protocol {
23+
// Is this a delta only?
24+
// Entries that were already sent are not sent again, because the protocol is immutable anyway.
25+
// But if the game is reset, the whole protocol must be replaced. That's what this flag is for.
1826
optional bool delta = 1;
27+
// The (delta) list of entries
1928
repeated ProtocolEntry entry = 2;
2029
}
2130

31+
// A protocol entry of a change
2232
message ProtocolEntry {
33+
// Id of the entry
2334
optional int32 id = 1;
35+
// The change that was made
2436
optional Change change = 2;
37+
// The match time elapsed when this change was made
2538
optional google.protobuf.Duration match_time_elapsed = 3;
39+
// The stage time elapsed when this change was made
2640
optional google.protobuf.Duration stage_time_elapsed = 4;
2741
}
2842

43+
// Message format that can be send from the client to the GC
2944
message Input {
45+
// A change to be enqueued into the GC engine
3046
optional Change change = 1;
47+
// Reset the match
3148
optional bool reset_match = 2;
3249
}

proto/ssl_gc_ci.proto

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,14 @@ import "ssl_gc_referee_message.proto";
77

88
// The input format to the GC
99
message CiInput {
10+
// New unix timestamp in [ns] for the GC
1011
optional int64 timestamp = 1;
12+
// New tracker packet with ball and robot data
1113
optional TrackerWrapperPacket tracker_packet = 2;
1214
}
1315

1416
// The output format of the GC response
1517
message CiOutput {
18+
// Latest referee message
1619
optional Referee referee_msg = 1;
1720
}

0 commit comments

Comments
 (0)