-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTypes.proto
188 lines (165 loc) · 3.51 KB
/
Types.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
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
syntax = "proto3";
option java_package = "com.visitor.protocol";
/**
* Custom type messages. Should not be sent directly.
*/
enum Phase {
NOPHASE = 0;
REDRAW = 1;
BEGIN = 2;
MAIN_BEFORE = 3;
ATTACK = 4;
ATTACK_PLAY = 5;
BLOCK = 6;
BLOCK_PLAY = 7;
MAIN_AFTER = 8;
END = 9;
}
enum SelectFromType {
NOTYPE = 0;
LIST = 1;
HAND = 3;
PLAY = 4;
DISCARD_PILE = 5;
STACK = 6;
}
enum GameType {
NOGAME = 0;
BO1_CONSTRUCTED = 1;
P2_DRAFT = 2;
P2_DRAFT_GAME = 3;
AI_BO1_CONSTRUCTED = 4;
}
message Table
{
string id = 1;
string creator = 2;
string opponent = 3;
}
enum Knowledge {
NONE = 0;
PURPLE = 1;
GREEN = 2;
RED = 3;
BLUE = 4;
YELLOW = 5;
}
message KnowledgeGroup {
Knowledge knowledge = 1;
int32 count = 2;
}
enum Counter {
NOCOUNTER = 0;
CHARGE = 1;
}
message CounterGroup {
Counter counter = 1;
int32 count = 2;
}
message Blocker {
string blockerId = 1;
repeated string possibleBlockTargets = 2;
}
message Attacker {
string attackerId = 1;
repeated string possibleAttackTargets = 2;
}
message AttackerAssignment {
string attackerId = 1;
string attacksTo = 2;
}
message BlockerAssignment {
string blockerId = 1;
string blockedBy = 2;
}
message DamageAssignment {
string targetId = 1;
int32 damage = 2;
}
message TargetSelection {
string id = 1;
repeated string targets = 2;
}
message Combat {
int32 health = 1;
int32 shield = 2;
int32 attack = 3;
bool deploying = 4;
string blockedAttacker = 5;
string attackTarget = 6;
repeated string combatAbilities = 7;
repeated string possibleBlockTargets = 8;
}
message Targeting {
string id = 1;
repeated string possibleTargets = 2;
int32 minTargets = 3;
int32 maxTargets = 4;
string targetMessage = 5;
SelectFromType targetingZone = 6;
}
message TargetingAbility {
string id = 1;
repeated Targeting targets = 2;
string text = 3;
}
message CardP {
string id = 1;
string name = 2;
repeated CounterGroup counters = 3;
bool depleted = 4;
bool marked = 5;
repeated string targets = 6;
bool canAttack = 7;
string cost = 8;
repeated KnowledgeGroup knowledgeCost = 9;
repeated string types = 10;
bool canBlock = 11;
repeated string subtypes = 12;
int32 delay = 13;
int32 loyalty = 14;
bool canActivate = 15;
Combat combat = 16;
string set = 17;
repeated string attachments = 18;
string description = 19;
bool canPlay = 20;
bool canStudy = 21;
repeated Targeting playTargets = 22;
repeated TargetingAbility activateTargets = 23;
string Zone = 24;
string controller = 25;
}
message Player {
string id = 1;
string username = 2;
int32 deckSize = 3;
int32 energy = 4;
int32 maxEnergy = 5;
repeated CardP hand = 6;
repeated CardP play = 7;
repeated CardP discardPile = 8;
repeated KnowledgeGroup knowledgePool = 9;
int32 shield = 10;
int32 handSize = 11;
int32 health = 12;
int32 time = 13;
repeated KnowledgeGroup deckColors = 14;
}
message GameStateP {
string id = 1;
Phase phase = 2;
string turnPlayer = 3;
string activePlayer = 4;
repeated string attackers = 5;
repeated string blockers = 6;
repeated CardP stack = 7;
Player player = 8;
Player opponent = 9;
}
message DraftState {
string id = 1;
repeated string decklist = 2;
bool completed = 3;
string playerId = 4;
}