-
Notifications
You must be signed in to change notification settings - Fork 44
/
Copy pathssl_gc_state.proto
133 lines (118 loc) · 3.86 KB
/
ssl_gc_state.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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
syntax = "proto2";
option go_package = "github.com/RoboCup-SSL/ssl-game-controller/internal/app/state";
import "ssl_gc_common.proto";
import "ssl_gc_geometry.proto";
import "ssl_gc_game_event.proto";
import "ssl_gc_referee_message.proto";
import "google/protobuf/duration.proto";
import "google/protobuf/timestamp.proto";
message YellowCard {
optional uint32 id = 1;
optional GameEvent caused_by_game_event = 2;
optional google.protobuf.Duration time_remaining = 3;
}
message RedCard {
optional uint32 id = 1;
optional GameEvent caused_by_game_event = 2;
}
message Foul {
optional uint32 id = 1;
optional GameEvent caused_by_game_event = 2;
optional google.protobuf.Timestamp timestamp = 3;
}
message Command {
required Type type = 1;
required Team for_team = 2;
enum Type {
UNKNOWN = 0;
HALT = 1;
STOP = 2;
NORMAL_START = 3;
FORCE_START = 4;
DIRECT = 5;
reserved 6; // INDIRECT
KICKOFF = 7;
PENALTY = 8;
TIMEOUT = 9;
BALL_PLACEMENT = 10;
}
}
message GameState {
required Type type = 1;
optional Team for_team = 2;
enum Type {
UNKNOWN = 0;
HALT = 1;
STOP = 2;
RUNNING = 3;
FREE_KICK = 4;
KICKOFF = 5;
PENALTY = 6;
TIMEOUT = 7;
BALL_PLACEMENT = 8;
}
}
message Proposal {
// The timestamp when the game event proposal occurred
optional google.protobuf.Timestamp timestamp = 1;
// The proposed game event.
optional GameEvent game_event = 2;
}
message ProposalGroup {
// Unique ID of this group
optional string id = 4;
// The proposals in this group
repeated Proposal proposals = 1;
// Whether the proposal group was accepted
optional bool accepted = 2;
reserved 3; // uint32 id
}
message TeamInfo {
optional string name = 1;
optional int32 goals = 2;
optional int32 goalkeeper = 3;
repeated YellowCard yellow_cards = 4;
repeated RedCard red_cards = 5;
optional int32 timeouts_left = 6;
optional google.protobuf.Duration timeout_time_left = 7;
optional bool on_positive_half = 8;
repeated Foul fouls = 9;
optional int32 ball_placement_failures = 10;
optional bool ball_placement_failures_reached = 11;
optional bool can_place_ball = 12;
optional int32 max_allowed_bots = 13;
optional google.protobuf.Timestamp requests_bot_substitution_since = 14;
optional google.protobuf.Timestamp requests_timeout_since = 15;
optional google.protobuf.Timestamp requests_emergency_stop_since = 16;
optional int32 challenge_flags = 17;
optional bool bot_substitution_allowed = 18;
optional int32 bot_substitutions_left = 19;
optional google.protobuf.Duration bot_substitution_time_left = 20;
}
message State {
optional Referee.Stage stage = 1;
optional Command command = 2;
optional GameState game_state = 19;
optional google.protobuf.Duration stage_time_elapsed = 4;
optional google.protobuf.Duration stage_time_left = 5;
optional google.protobuf.Timestamp match_time_start = 6;
map<string, TeamInfo> team_state = 8;
optional Vector2 placement_pos = 9;
optional Command next_command = 10;
optional google.protobuf.Duration current_action_time_remaining = 12;
repeated GameEvent game_events = 13;
repeated ProposalGroup proposal_groups = 14;
optional Division division = 15;
reserved 16;
optional Team first_kickoff_team = 17;
optional MatchType match_type = 18;
optional google.protobuf.Timestamp ready_continue_time = 20;
optional ShootoutState shootout_state = 21;
optional string status_message = 22;
// The maximum number of bots per team (overwrites the division config)
optional int32 max_bots_per_team = 23;
}
message ShootoutState {
optional Team next_team = 1;
map<string, int32> number_of_attempts = 2;
}