CardRPG 1.0
 
Loading...
Searching...
No Matches
CardRPG.Card Class Reference

Represents a card in the Card RPG system. Cards are ScriptableObjects that define their cost, type, effects, targeting, and logic. Cards can be cloned, displayed in shops, and used in duels by Duelers. More...

Inheritance diagram for CardRPG.Card:
CardRPG.IShopableItem CardRPG.IStatus

Public Member Functions

int GetCardBaseDamage (Dueler caster, Dueler target)
 Gets the sum of minimum values of all DamageLogic components on this card.
 
string DisplayStatus ()
 
List< DuelerGetTargetsBasedOnCard (Dueler caster, List< Dueler > selectedTarget)
 Determines the list of targets for this card based on its Target property.
 
object Clone ()
 

Protected Attributes

List< int > elementalPipCost = new()
 
List< CardsubCard
 
List< CardLogiccardLogics = new()
 
EnchantLogic enchantLogics
 
List< CardModifiercardModifier
 

Properties

int PipCost [get, set]
 Gets the pip cost required to play this card. If set to a negative value, removes elemental pips to increase the cost by 2 per removed element.
 
List< int > ElementalPipCost [get]
 
bool PerPip [get]
 Gets whether the card's effect scales per pip spent.
 
int MaxPip [get]
 Gets the maximum number of pips that can be spent on this card.
 
int Element [get]
 Gets the element associated with this card.
 
bool RequireSameElement [get]
 Gets whether the card requires the caster to have the same element.
 
int Accuracy [get]
 Gets the accuracy of the card (chance to hit).
 
CardType Type [get]
 Gets the type of the card (damage, heal, etc.).
 
CardSpecial CardSpecial [get, set]
 Gets the special category of the card (treasure, item, etc.).
 
Target Target [get]
 Gets the targeting type of the card.
 
bool PlayAgain [get]
 Property indicating whether the card can be played again after use.
 
string Description [get]
 Gets the description of the card.
 
int Value [get]
 Gets the value of the card (for shop or scoring).
 
int LevelRequirement [get]
 Gets the level requirement to use this card.
 
bool NotForSale [get]
 Gets whether the card is not for sale.
 
List< CardSubCard [get]
 Gets the list of sub-cards (for multi-part cards).
 
Sprite Image [get]
 Gets the image representing the card.
 
List< CardLogicCardLogics [get]
 Gets the list of logic components that define the card's effects.
 
EnchantLogic EnchantLogic [get]
 Gets the enchantment logic applied to this card.
 
List< CardModifierCardModifier [get]
 
string Name [get]
 Gets the name of the card.
 
int GetNumberOfDamageLogics [get]
 
int GetCardInitDamage [get]
 Gets the minimum value of the first DamageLogic that is not damage over time.
 

Detailed Description

Represents a card in the Card RPG system. Cards are ScriptableObjects that define their cost, type, effects, targeting, and logic. Cards can be cloned, displayed in shops, and used in duels by Duelers.

Member Function Documentation

◆ DisplayStatus()

string CardRPG.Card.DisplayStatus ( )

Implements CardRPG.IStatus.

◆ GetTargetsBasedOnCard()

List< Dueler > CardRPG.Card.GetTargetsBasedOnCard ( Dueler caster,
List< Dueler > selectedTarget )
inline

Determines the list of targets for this card based on its Target property.

Parameters
casterThe dueler casting the card.
selectedTargetThe selected target, if any.
Returns
List of Duelers to target.

Property Documentation

◆ LevelRequirement

int CardRPG.Card.LevelRequirement
get

Gets the level requirement to use this card.

Implements CardRPG.IShopableItem.

◆ Name

string CardRPG.Card.Name
get

Gets the name of the card.

Implements CardRPG.IShopableItem.

◆ NotForSale

bool CardRPG.Card.NotForSale
get

Gets whether the card is not for sale.

Implements CardRPG.IShopableItem.

◆ Value

int CardRPG.Card.Value
get

Gets the value of the card (for shop or scoring).

Implements CardRPG.IShopableItem.


The documentation for this class was generated from the following file: