public async Task <IActionResult> FixCardText() { IList <Card> cards = _context.Cards.ToList(); foreach (Card c in cards) { try { StringWriter stringWriter = new StringWriter(); string newText; CardEffects cardEffects = _context.CardEffects.Where(x => x.CardId == c.CardId).FirstOrDefault(); HttpUtility.HtmlDecode(cardEffects.Text, stringWriter); newText = stringWriter.ToString(); cardEffects.Text = newText; _context.Update(cardEffects); await _context.SaveChangesAsync(); } catch { } } return(View()); }
protected override void PlayableCards() { foreach (CardComponent card in ActiveInvestigator.Hand.ListCards) { CardEffects.Add(new CardEffect( card: card, effect: () => new MoveCardAction(card, ActiveInvestigator.InvestigatorDiscard).RunNow(), type: EffectType.Choose, name: "Descartar " + card.Info.Name)); } foreach (CardComponent card in ActiveInvestigator.InvestigatorDiscard.ListCards) { if (card.Info.Subtype_code != "weakness" && card.Info.Subtype_code != "basicweakness") { CardEffects.Add(new CardEffect( card: card, effect: () => ReturnMulliganCard(card), type: EffectType.Choose, name: "Devolver " + card.Info.Name)); } } IEnumerator ReturnMulliganCard(CardComponent card) { if (card.CurrentZone.ListCards.Last() != card) { yield return(card.transform.DOLocalMoveX(1, GameData.ANIMATION_TIME_DEFAULT).WaitForCompletion()); } yield return(new MoveCardAction(card, ActiveInvestigator.Hand).RunNow()); } }
private void Start() { fighter1 = GameObject.Find("Fighter1").transform; fighter2 = GameObject.Find("Fighter2").transform; fighter1Properties = fighter1.GetComponent <Properties>(); fighter2Properties = fighter2.GetComponent <Properties>(); _cardDatabase = GameObject.Find("CardDatabase").GetComponent <CardDatabase>(); _cardEffects = GameObject.Find("CardDatabase").GetComponent <CardEffects>(); _battleScreen = GetComponent <BattleScreen>(); _cardDatabase.LoadCardDatabase(); fighter1Properties.fighterName = GameObject.Find("Client").GetComponent <Client>().clientName; fighter1.Find("FighterName").GetComponent <Text>().text = fighter1Properties.fighterName; fighter2Properties.fighterName = GameObject.Find("Client").GetComponent <Client>().opponentName; fighter2.Find("FighterName").GetComponent <Text>().text = fighter2Properties.fighterName; fighter1Properties.oldHP = fighter1Properties.maxHP; fighter2Properties.oldHP = fighter2Properties.maxHP; fighter1Properties.currentHP = fighter1Properties.maxHP; fighter2Properties.currentHP = fighter2Properties.maxHP; fighter1.Find("HPBar").transform.Find("Text").GetComponent <Text>().text = fighter1Properties.maxHP.ToString(); fighter2.Find("HPBar").transform.Find("Text").GetComponent <Text>().text = fighter2Properties.maxHP.ToString(); Init(); }
protected override void PlayableCards() { CardEffects.AddRange(ChosenCardEffects); if (CardEffects.Count < 1) { AnyIsClicked = true; } }
public Inflame() { UniqueCardId = new Guid("48002444-bad6-4b18-8b2c-0c92fe675758"); CardEffects.Add(CardEffect.AddStrengthSelf, new CardEffectValueObject(typeof(int), 2)); CardColor = CardColor.Red; CardType = CardType.Power; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Inflame"; Description = "Gain 2 Strength"; }
public NewCard() { UniqueCardId = new Guid("764d2334-94d2-48fd-8219-07cb51e54324"); CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(typeof(int), 50)); CardColor = CardColor.Colorless; CardType = CardType.Skill; CardUseType = CardUseType.Exhaust; UpgradeTarget = null; CardRarity = CardRarity.Mythic; Cost = 1; Name = "New Card"; Description = "New Card from modded content"; }
public GhostlyArmor() { UniqueCardId = new Guid("b901657f-683a-4545-ad9d-bedeae61212b"); CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(typeof(int), 10)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Ghostly Armor"; Description = "Gain 10 Block."; }
public WarCry() { UniqueCardId = new Guid("590f79c1-da0e-4d0a-8abf-fdf3498a10f6"); CardEffects.Add(CardEffect.DrawCards, new CardEffectValueObject(typeof(int), 1)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Exhaust; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 0; Name = "Warcry"; Description = "Draw 1 card. Put a card from your hand onto the top of your draw pile."; }
public Card(string a_sName, string a_sDesc, string a_sDamage) { m_cardName = a_sName; m_cardDesc = a_sDesc; m_tag1 = a_sDamage; float damage = 0; float.TryParse(a_sDamage, out damage); m_Effect = CardEffects.Attack(damage); m_CrewEffect = CardEffects.AttackCrew(damage); }
public Disarm() { UniqueCardId = new Guid("360f51a4-054f-466a-b690-645df9b4dcab"); CardEffects.Add(CardEffect.AddStrengthEnemy, new CardEffectValueObject(typeof(int), -2)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Exhaust; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Disarm"; Description = "Enemy loses 2 Strength"; }
public BattleTrance() { UniqueCardId = new Guid("c06ddf6a-e3c7-4dec-9da9-629b3b3d650e"); CardEffects.Add(CardEffect.DrawCards, new CardEffectValueObject(typeof(int), 3)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 0; Name = "Battle Trance"; Description = "Draw 3 cards. You cannot draw additional cards this turn"; }
public ShrugItOff() { UniqueCardId = new Guid("a41ed1dc-2d36-40b6-ba45-e0b4695f2ccf"); CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(typeof(int), 8)); CardColor = CardColor.Red; CardType = CardType.Attack; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Shrug It Off"; Description = "Gain 8 Block. Draw 1 card."; }
public Intimidate() { UniqueCardId = new Guid("ee687027-d342-441b-8434-b919d2b8b85a"); CardEffects.Add(CardEffect.AddWeakEnemy, new CardEffectValueObject(typeof(int), 1)); CardColor = CardColor.Red; CardType = CardType.Power; CardUseType = CardUseType.Exhaust; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Intimidate"; Description = "Apply 1 Weak to ALL enemies"; }
public BodySlam() { UniqueCardId = new Guid("8df6594b-0e7e-4609-91cb-57cbbde759df"); CardEffects.Add(CardEffect.DamageAsBlock, null); CardColor = CardColor.Red; CardType = CardType.Attack; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Body Slam"; Description = "Deal damage equal to your Block"; }
public Bloodletting() { UniqueCardId = new Guid("8b8c062e-d085-4896-8c6b-82ea5cb4d04c"); CardEffects.Add(CardEffect.GainEnergy, new CardEffectValueObject(typeof(int), 1)); CardEffects.Add(CardEffect.LoseHealth, new CardEffectValueObject(typeof(int), 3)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Exhaust; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 0; Name = "Bloodletting"; Description = "Lose 3 HP, Gain 1 Energy"; }
public BurningPact() { UniqueCardId = new Guid("7839238f-7bd0-4d49-8bcd-66302dc3e0bd"); CardEffects.Add(CardEffect.ExhaustCard, new CardEffectValueObject(typeof(int), 1)); CardEffects.Add(CardEffect.DrawCards, new CardEffectValueObject(typeof(int), 2)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Burning Pact"; Description = "Exhaust 1 card. Draw 2 cards."; }
public TrueGrit() { UniqueCardId = new Guid("a2e5e06e-3dbe-427e-8080-c0a1dfbeebfd"); CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(typeof(int), 7)); CardEffects.Add(CardEffect.ExhaustCard, null); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "True Grit"; Description = "Gain 7 Block. Exhaust a card in your hand"; }
public Arnaments() { UniqueCardId = new Guid("764d2334-94d2-48fd-8219-07cb51e54324"); CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(typeof(int), 5)); CardEffects.Add(CardEffect.UpgradeCard, null); CardColor = CardColor.Red; CardType = CardType.Attack; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Average; Cost = 1; Name = "Arnaments"; Description = "Gain 5 Block and upgrade a card in your hand for the rest of combat."; }
// Start is called before the first frame update void Start() { playerStatsScript = GameObject.Find("Player").GetComponent <PlayerStats>(); backgroundMouseFlag = GameObject.Find("Field Background").GetComponent <BackgroundMouseFlag>(); selected = false; myHUDPosition = transform.position; myCardStats = GetComponent <CardStats>(); myCardEffects = GetComponent <CardEffects>(); myRenderer = GetComponent <Renderer>(); listOfAlliedUnitsToSpawn = new List <GameObject>(); }
public DefendPlus2() { UniqueCardId = new Guid("4e99a125-0815-412e-a112-b9088119d0b6"); var value = 10; CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(value.GetType(), value)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; CardRarity = CardRarity.Normal; Cost = 1; Name = "Defend++"; Description = "Gain 10 Block"; }
public Defend() { UniqueCardId = new Guid("c704e77b-2208-435c-b2ef-83b557b2aa0c"); var value = 5; CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(value.GetType(), value)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; UpgradeTarget = typeof(DefendPlus); CardRarity = CardRarity.Normal; Cost = 1; Name = "Defend"; Description = "Gain 5 Block"; }
public DefendPlus() { UniqueCardId = new Guid("f50d89a8-c94a-4583-8877-254d1d7af693"); var value = 7; CardEffects.Add(CardEffect.AddBlockSelf, new CardEffectValueObject(value.GetType(), value)); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; UpgradeTarget = typeof(DefendPlus2); CardRarity = CardRarity.Normal; Cost = 1; Name = "Defend+"; Description = "Gain 7 Block"; }
public Evolve() { UniqueCardId = new Guid("47d86ae7-c34c-4dcc-a845-a0e291d63ffa"); CardEffects.Add(CardEffect.AddPowerToHero, new CardEffectValueObject(typeof(EvolvePower), new EvolvePower(this) { PowerTrigger = PowerTrigger.OnCardDraw })); CardColor = CardColor.Red; CardType = CardType.Power; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Evolve"; Description = "Whenever you draw a Status card, draw 1 card."; }
public Metallicize() { UniqueCardId = new Guid("20def8cd-9b13-4cf1-a717-98fcdfa94d13"); CardEffects.Add(CardEffect.AddPowerToHero, new CardEffectValueObject(typeof(MetallicizePower), new MetallicizePower(this) { PowerTrigger = PowerTrigger.EndOfPlayerTurn })); CardColor = CardColor.Red; CardType = CardType.Power; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Metallicize"; Description = "At the end of your turn, gain 3 Block"; }
public Dropkick() { UniqueCardId = new Guid("37755ad4-a6d6-446a-b0f4-2736c8e45c74"); CardEffects.Add(CardEffect.Damage, new CardEffectValueObject(typeof(DamageMultipleTimesEffect), new DamageMultipleTimesEffect() { DamageAmount = 5, HitTimes = 1 })); CardColor = CardColor.Red; CardType = CardType.Attack; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Dropkick"; Description = "Deal 5 damage. If the enemy has Vulnerable, gain 1 Energy and draw 1 card"; }
public HeavyBlade() { UniqueCardId = new Guid("3c27f381-00a0-415a-97ab-1d18337bbfaf"); CardEffects.Add(CardEffect.Damage, new CardEffectValueObject(typeof(DamageMultipleTimesEffect), new DamageMultipleTimesEffect() { DamageAmount = 14, HitTimes = 1 })); CardColor = CardColor.Red; CardType = CardType.Attack; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 2; Name = "Heavy Blade"; Description = "Deal 14 damage. Strength affects this card 3 times."; }
public TwinStrike() { UniqueCardId = new Guid("590f79c1-da0e-4d0a-8abf-fdf3498a10f6"); CardEffects.Add(CardEffect.Damage, new CardEffectValueObject(typeof(DamageMultipleTimesEffect), new DamageMultipleTimesEffect() { DamageAmount = 5, HitTimes = 2 })); CardColor = CardColor.Red; CardType = CardType.Skill; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Twin Strike"; Description = "Deal 5 damage twice"; }
public Corruption() { UniqueCardId = new Guid("ac378a4d-5f5a-48e1-804a-1d6db98a8668"); CardEffects.Add(CardEffect.AddPowerToHero, new CardEffectValueObject(typeof(CorruptionPower), new CorruptionPower(this) { PowerTrigger = PowerTrigger.Always })); CardColor = CardColor.Red; CardType = CardType.Power; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 3; Name = "Corruption"; Description = "Skills cost 0. Whenever you play a Skill, Exhaust it."; }
public SwordBoomerang() { UniqueCardId = new Guid("0963394e-b1e2-4147-ab10-9f2589829e7f"); CardEffects.Add(CardEffect.DamageRandomTargets, new CardEffectValueObject(typeof(DamageMultipleTimesEffect), new DamageMultipleTimesEffect() { DamageAmount = 3, HitTimes = 3 })); CardColor = CardColor.Red; CardType = CardType.Attack; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 1; Name = "Sword Boomerang"; Description = "Deal 3 damage to a random enemy 3 times"; }
public BloodForBlood() { UniqueCardId = new Guid("c06ddf6a-e3c7-4dec-9da9-629b3b3d650e"); CardEffects.Add(CardEffect.Damage, new CardEffectValueObject(typeof(DamageMultipleTimesEffect), new DamageMultipleTimesEffect() { DamageAmount = 18, HitTimes = 1 })); CardColor = CardColor.Red; CardType = CardType.Attack; CardUseType = CardUseType.Default; UpgradeTarget = null; CardRarity = CardRarity.Normal; Cost = 4; Name = "Blood for Blood"; Description = "Costs 1 less energy for each time you lose HP this combat. Deal 18 damage"; }