-
Notifications
You must be signed in to change notification settings - Fork 44
/
ssl_gc_api.proto
56 lines (49 loc) · 1.7 KB
/
ssl_gc_api.proto
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
syntax = "proto2";
option go_package = "github.com/RoboCup-SSL/ssl-game-controller/internal/app/api";
import "ssl_gc_state.proto";
import "ssl_gc_change.proto";
import "ssl_gc_engine.proto";
import "ssl_gc_engine_config.proto";
import "google/protobuf/duration.proto";
// Message format that is pushed from the GC to the client
message Output {
// The current match state
optional State match_state = 1;
// The current GC state
optional GcState gc_state = 2;
// The protocol
optional Protocol protocol = 3;
// The engine config
optional Config config = 4;
}
// The game protocol
message Protocol {
// Is this a delta only?
// Entries that were already sent are not sent again, because the protocol is immutable anyway.
// But if the game is reset, the whole protocol must be replaced. That's what this flag is for.
optional bool delta = 1;
// The (delta) list of entries
repeated ProtocolEntry entry = 2;
}
// A protocol entry of a change
message ProtocolEntry {
// Id of the entry
optional int32 id = 1;
// The change that was made
optional Change change = 2;
// The match time elapsed when this change was made
optional google.protobuf.Duration match_time_elapsed = 3;
// The stage time elapsed when this change was made
optional google.protobuf.Duration stage_time_elapsed = 4;
}
// Message format that can be send from the client to the GC
message Input {
// A change to be enqueued into the GC engine
optional Change change = 1;
// Reset the match
optional bool reset_match = 2;
// An updated config delta
optional Config config_delta = 3;
// Continue with action
optional ContinueAction continue_action = 4;
}