void ServerPlayer::addCard(const Card *card, Place place){ switch(place){ case Hand: handcards << card; break; case Equip: { const EquipCard *equip = qobject_cast<const EquipCard *>(card); setEquip(equip); equip->onInstall(this); break; } case Judging:{ addDelayedTrick(card); break; } default: // FIXME ; } }
void ClientPlayer::addCard(const Card *card, Place place) { switch (place) { case PlaceHand: { if (card) known_cards << card; handcard_num++; break; } case PlaceEquip: { WrappedCard *equip = Sanguosha->getWrappedCard(card->getEffectiveId()); setEquip(equip); break; } case PlaceDelayedTrick: { addDelayedTrick(card); break; } default: break; } }
void ClientPlayer::addCard(const Card *card, Place place){ switch(place){ case PlaceHand: { if(card) known_cards << card; handcard_num++; break; } case PlaceEquip: { const EquipCard *equip = qobject_cast<const EquipCard*>(card); setEquip(equip); break; } case PlaceDelayedTrick:{ addDelayedTrick(card); break; } default: // FIXME ; } }