int GuiOpponentHand::receiveEventPlus(WEvent* e) { if (WEventZoneChange* event = dynamic_cast<WEventZoneChange*>(e)) if (event->to == zone) { CardView* t; if (event->card->view) t = NEW CardView(CardView::nullZone, event->card, *(event->card->view)); else t = NEW CardView(CardView::nullZone, event->card, x, y); t->x = x + Width / 2; t->y = y + Height / 2; t->zoom = 0.6f; t->alpha = 0; cards.push_back(t); return 1; } return 0; }
void CardDisplay::AddCard(MTGCardInstance * _card) { CardGui * card = NEW CardView(CardView::nullZone, _card, static_cast<float> (x + 20 + (mObjects.size() - start_item) * 30), static_cast<float> (y + 25)); Add(card); }