public override void OnDrop(GameObject Card) { PlayCard card = Card.GetComponent <PlayCard>(); if (card.isUsed) { card.GetComponent <CardBody>().ResetDrop(); baseZone.CloseZone(); return; } if (baseBuilding.CheckPreview(card.Value)) { baseBuilding.Fill(card.Value); EffectResolver.TriggerCardEffects(card); card.Use(); if (baseBuilding.CheckReady()) { baseZone.ForceOpen(); return; } } else { CardBody.dragged.ResetDrop(); } baseZone.CloseZone(); }
public override void OnDrop(GameObject CardObj) { PlayCard card = CardObj.GetComponent <PlayCard>(); if (card.isUsed) { CardBody.dragged.ResetDrop(); baseZone.ResetZone(); return; } if (baseCard.CheckPreview(card.Value)) { baseCard.Fill(card.Value); EffectResolver.TriggerCardEffects(card); card.Use(); } else { CardBody.dragged.ResetDrop(); } baseZone.ResetZone(); }