/// <summary> /// Determines whether this instance is ready to join zone the specified target. /// </summary> /// <returns><c>true</c> if this instance is ready to join zone the specified target; otherwise, <c>false</c>.</returns> /// <param name="target">Target.</param> public bool IsReadyToJoinZone(CardDataProperties target, bool IsTargetBiggerThan = false, bool IsSameColor = true) { if (IsTargetBiggerThan) { // TODO: Check if this card has the value smaller than target and has the same card type. if (properties.GetCardValue() == target.GetCardValue() + 1) { if (!IsSameColor) { if (!IsSameColorCard(target.GetCardType())) { return(true); } } else { if (properties.GetCardType() == target.GetCardType()) { // TODO: Return true if this condition is true. return(true); } } } } else { // TODO: Check if this card has the value smaller than target and has the same card type. if (properties.GetCardValue() == target.GetCardValue() - 1) { if (!IsSameColor) { if (!IsSameColorCard(target.GetCardType())) { return(true); } } else { if (properties.GetCardType() == target.GetCardType()) { // TODO: Return true if this condition is true. return(true); } } } } // TODO: Return false. return(false); }
/// <summary> /// Gets the value. /// </summary> /// <returns>The value.</returns> public int GetValue() { // TODO: return the value of card. return(properties.GetCardValue()); }