Commit 621489ac authored by Chunchi Che's avatar Chunchi Che

Merge branch 'feat/move' into 'main'

add move msg

See merge request !13
parents 8cfeb7ac e4b93b42
Pipeline #18922 passed with stage
in 16 seconds
......@@ -20,6 +20,18 @@ enum CardZone {
PZONE = 10; // 灵摆区
}
// 卡牌的表示方式类型
enum CardPosition {
FACEUP_ATTACK = 0;
FACEDOWN_ATTACK = 1;
FACEUP_DEFENSE = 2;
FACEDOWN_DEFENSE = 3;
FACEUP = 4;
FACEDOWN = 5;
ATTACK = 6;
DEFENSE = 7;
}
message CardInfo {
int32 code = 1;
int32 controler = 2;
......@@ -27,6 +39,14 @@ message CardInfo {
int32 sequence = 4;
}
message CardLocation {
int32 controler = 1;
int32 location = 2;
int32 sequence = 3;
CardPosition position = 4;
int32 overlay_sequence = 5;
}
// ----- Service -----
// reference: https://github.com/mycard/srvpro/blob/master/data/structs.json
......@@ -347,6 +367,14 @@ message StocGameMessage {
repeated SelectAblePlace places = 3;
}
// 卡牌位置移动
message MsgMove {
int32 code = 1; // 移动的卡牌code
CardLocation from = 2; // 移动前的位置信息
CardLocation to = 3; // 移动后的位置信息
int32 reason = 4; // 移动的原因
}
oneof gameMsg {
MsgStart start = 1;
MsgDraw draw = 2;
......@@ -355,6 +383,7 @@ message StocGameMessage {
MsgHint hint = 5;
MsgSelectIdleCmd select_idle_cmd = 6;
MsgSelectPlace select_place = 7;
MsgMove move = 8;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment