public CardInstance Clone() { CardInstance cardInstance = new CardInstance(srcPlayer, cardSeed, cardFlags); foreach (IModifier modifier in modifiers) { cardInstance.AddModifier(modifier); } return(cardInstance); }
public void ServerAddModifier(IModifier modifier) { if (modifier is StatModifier statMod) { cardData.AddModifier(modifier); RpcAddStatModifier(statMod); } else if (modifier is KeywordModifier keywordMod) { cardData.AddModifier(modifier); RpcAddKeywordModifier(keywordMod); } else if (modifier is ManaCostModifier manaMod) { cardData.AddModifier(modifier); RpcAddManaCostModifier(manaMod); } }