Commit 8cc5ee28 authored by Max-Wilhelm Bruker's avatar Max-Wilhelm Bruker
Browse files

disallow face-down cards in other zones than the table

parent e326f961
...@@ -374,6 +374,8 @@ Response::ResponseCode Server_Player::moveCard(GameEventStorage &ges, Server_Car ...@@ -374,6 +374,8 @@ Response::ResponseCode Server_Player::moveCard(GameEventStorage &ges, Server_Car
Server_Card *card = cardsToMove[cardIndex].first; Server_Card *card = cardsToMove[cardIndex].first;
const CardToMove *thisCardProperties = cardProperties.value(card); const CardToMove *thisCardProperties = cardProperties.value(card);
bool faceDown = thisCardProperties->has_face_down() ? thisCardProperties->face_down() : card->getFaceDown(); bool faceDown = thisCardProperties->has_face_down() ? thisCardProperties->face_down() : card->getFaceDown();
if (!targetzone->hasCoords())
faceDown = false;
int originalPosition = cardsToMove[cardIndex].second; int originalPosition = cardsToMove[cardIndex].second;
int position = startzone->removeCard(card); int position = startzone->removeCard(card);
......
Supports Markdown
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