Ejemplo n.º 1
0
        CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.GVG_110t);//chillwind

        public override void getBattlecryEffect(Playfield p, Minion own, Minion target, int choice)
        {
            int pos = (own.own) ? p.ownMinions.Count : p.enemyMinions.Count;
            p.callKid(kid, pos, own.own);
            pos = (own.own) ? p.ownMinions.Count : p.enemyMinions.Count;
            p.callKid(kid, pos, own.own);
        }
Ejemplo n.º 2
0
        CardDB.Card c = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.EX1_301);//felguard
//    todesröcheln:/ legt einen zufälligen dämon aus eurer hand auf das schlachtfeld.

        public override void onDeathrattle(Playfield p, Minion m)
        {
            if (m.own)
            {
                List<Handmanager.Handcard> temp = new List<Handmanager.Handcard>();
                foreach (Handmanager.Handcard hc in p.owncards)
                {
                    if ((TAG_RACE)hc.card.race == TAG_RACE.DEMON)
                    {
                        temp.Add(hc);
                    }
                }

                temp.Sort((x, y) => x.card.Attack.CompareTo(y.card.Attack));

                foreach (Handmanager.Handcard mnn in temp)
                {
                    p.callKid(mnn.card, p.ownMinions.Count, true);
                    p.removeCard(mnn);
                    break;
                }

            }
            else
            {
                if (p.enemyAnzCards >= 1)
                {
                    p.callKid(c, p.enemyMinions.Count , false);
                }
            }
        }
Ejemplo n.º 3
0
        CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.FP1_007t);//nerub

        public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
        {
            int pos = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
            if (p.isServer)
            {
                //TODO
                if (ownplay)
                {
                    p.enemyDeckSize += 3;
                }
                else
                {
                    p.ownDeckSize += 3;
                }
                p.callKid(kid, pos, ownplay);
                p.callKid(kid, pos, ownplay);
                return;
            }
            //hard to simulate
            if (ownplay)
            {
                p.enemyDeckSize += 3;
            }
            else
            {
                p.ownDeckSize += 3;
            }
            p.callKid(kid, pos, ownplay);
            p.callKid(kid, pos, ownplay);
        }
Ejemplo n.º 4
0
		CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.FP1_007t);//4/4Nerubian

		public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
		{
			if (p.ownDeckSize > 0)
            {
                p.callKid(kid, p.ownMinions.Count, true, false);
                p.ownDeckSize--;
            }
			
            if (p.enemyDeckSize > 0)
            {
                p.callKid(kid, p.enemyMinions.Count, false, false);
                p.enemyDeckSize--;
            }
			
			if (ownplay)
			{
				if (p.ownDeckSize > 0)
				{
                    p.callKid(kid, p.ownMinions.Count, true, false);
					p.ownDeckSize--;
				}
			}
			else
			{
				if (p.enemyDeckSize > 0)
				{
                    p.callKid(kid, p.enemyMinions.Count, false, false);
					p.enemyDeckSize--;
				}
			}
		}
Ejemplo n.º 5
0
        CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.CS2_101t);//silverhandrecruit

        //    Summon two 1/1 Recruits.
        public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
        {
            int posi = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;

            p.callKid(kid, posi, ownplay);
            p.callKid(kid, posi, ownplay);
        }
Ejemplo n.º 6
0
        public override void onSecretPlay(Playfield p, bool ownplay, Minion attacker, Minion target, out int number)
        {
            number = 0;
            if (ownplay)
            {
                int posi = p.ownMinions.Count;
                p.callKid(kid, posi, true);
                if (p.ownMinions.Count >= 1)
                {
                    if (p.ownMinions[p.ownMinions.Count - 1].name == CardDB.cardName.spellbender)
                    {
                        number = p.ownMinions[p.ownMinions.Count - 1].entityID;
                    }
                }
            }
            else
            {
                int posi = p.enemyMinions.Count;
                p.callKid(kid, posi, false);

                if (p.enemyMinions.Count >= 1)
                {
                    if (p.enemyMinions[p.enemyMinions.Count - 1].name == CardDB.cardName.spellbender)
                    {
                        number = p.enemyMinions[p.enemyMinions.Count - 1].entityID;
                    }
                }
            }

        }
Ejemplo n.º 7
0
        CardDB.Card copymin = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.CS2_182); // we take a icewindjety :D

		public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
		{

            if (p.isServer)
            {
                List<Handmanager.Handcard> temp = new List<Handmanager.Handcard>();
                List<Handmanager.Handcard> cards = (ownplay)? p.enemyDeck : p.myDeck;

                foreach (Handmanager.Handcard hc in cards)
                {
                    if (hc.card.type == CardDB.cardtype.MOB)
                    {
                        temp.Add(hc);
                    }
                }

                if (temp.Count >= 1)
                {

                    int rand = p.getRandomNumber_SERVER(0, temp.Count - 1);
                    int posi = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
                    p.callKid(cards[rand].card, posi, true);
                }
                else
                {
                    int posi = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
                    p.callKid(shadow, posi, true);
                }
                return;
            }
            p.callKid(copymin, p.ownMinions.Count, true);
		}
Ejemplo n.º 8
0
        public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
        {
            int dmg = (ownplay) ? p.getSpellDamageDamage(2) : p.getEnemySpellDamageDamage(2);
            p.minionGetDamageOrHeal(target, dmg);

            int posi = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
            p.callKid(kid, posi, ownplay);
            posi++;
            p.callKid(kid, posi, ownplay);
        }
Ejemplo n.º 9
0
 CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.CS2_050);//searing
 public override void getBattlecryEffect(Playfield p, Minion own, Minion target, int choice)
 {
     int pos = (own.own) ? p.ownMinions.Count : p.enemyMinions.Count;
     if (p.isServer)
     {
         //TODO
         p.callKid(kid, pos, own.own, true);
         return;
     }
     p.callKid(kid, pos, own.own, true);
 }
Ejemplo n.º 10
0
        CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.GVG_110t);//chillwind

        public override void getBattlecryEffect(Playfield p, Minion own, Minion target, int choice)
        {
            /*int pos = (own.own) ? p.ownMinions.Count : p.enemyMinions.Count;
            p.callKid(kid, pos, own.own);
            pos = (own.own) ? p.ownMinions.Count : p.enemyMinions.Count;
            p.callKid(kid, pos, own.own);*/
            int pos = own.zonepos;
            p.callKid(kid, pos, own.own, true);
            p.callKid(kid, pos, own.own, true);
            own.zonepos++;  // move Boom to the middle of our bots
        }
Ejemplo n.º 11
0
 CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.CS2_050);//searing
 public override void getBattlecryEffect(Playfield p, Minion own, Minion target, int choice)
 {
     int pos = own.zonepos;
     if (p.isServer)
     {
         //TODO
         p.callKid(kid, pos, own.own, true);
         return;
     }
     p.callKid(kid, pos, own.own, true);
 }
Ejemplo n.º 12
0
        CardDB.Card c = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.EX1_301);//felguard
//    todesröcheln:/ legt einen zufälligen dämon aus eurer hand auf das schlachtfeld.

        public override void onDeathrattle(Playfield p, Minion m)
        {
            if (p.isServer)
            {
                List<Handmanager.Handcard> temp = new List<Handmanager.Handcard>();
                List<Handmanager.Handcard> cards = (m.own) ? p.owncards : p.EnemyCards;

                foreach (Handmanager.Handcard hc in cards)
                {
                    if ((TAG_RACE)hc.card.race == TAG_RACE.DEMON)
                    {
                        temp.Add(hc);
                    }
                }

                if (temp.Count == 0) return;

                int rand = p.getRandomNumber_SERVER(0, temp.Count - 1);

                p.callKid(cards[rand].card, p.ownMinions.Count, m.own);
                p.removeCard_SERVER(cards[rand], m.own);

                return;
            }

            if (m.own)
            {
                List<Handmanager.Handcard> temp = new List<Handmanager.Handcard>();
                foreach (Handmanager.Handcard hc in p.owncards)
                {
                    if ((TAG_RACE)hc.card.race == TAG_RACE.DEMON)
                    {
                        temp.Add(hc);
                    }
                }

                temp.Sort((x, y) => x.card.Attack.CompareTo(y.card.Attack));

                foreach (Handmanager.Handcard mnn in temp)
                {
                    p.callKid(mnn.card, p.ownMinions.Count, true);
                    p.removeCard(mnn);
                    break;
                }

            }
            else
            {
                if (p.enemyAnzCards >= 1)
                {
                    p.callKid(c, p.enemyMinions.Count , false);
                }
            }
        }
Ejemplo n.º 13
0
        CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.EX1_050); //coldlight oracle

        public override void onInspire(Playfield p, Minion m)
        {
            int pos = (m.own) ? p.ownMinions.Count : p.enemyMinions.Count;

            if (p.isServer)
            {
                //TODO
                p.callKid(kid, pos, m.own);
                return;
            }

            p.callKid(kid, pos, m.own);
        }
Ejemplo n.º 14
0
        CardDB.Card warleader = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.EX1_507); //murloc warleader

        public override void onInspire(Playfield p, Minion m)
        {
            int pos = (m.own) ? p.ownMinions.Count : p.enemyMinions.Count;

            if (p.isServer)
            {
                //TODO
                p.callKid(kid, pos, m.own);
                return;
            }

            p.callKid((m.own ? kid : warleader), pos, m.own);  // assume worse scenario (warleader) for enemy vs average scenario (oracle) for us
        }
Ejemplo n.º 15
0
        public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
        {

            int pos = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
            p.callKid(kid, pos, ownplay, false);

            for (int i = 0; i < 2; i++)
            {
                pos = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
                p.callKid(kid, pos + 1, ownplay, true);  // spawnkid
            }
            p.equipWeapon(w, ownplay);
        }
Ejemplo n.º 16
0
//    vernichtet alle diener und ruft für jeden einen treant (2/2) als ersatz herbei.

		public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
		{
            int ownanz = p.ownMinions.Count;
            int enemanz = p.enemyMinions.Count;
            p.allMinionsGetDestroyed();
            for (int i = 0; i < ownanz; i++)
            {
                p.callKid(d, 1, true);
            }
            for (int i = 0; i < enemanz; i++)
            {
                p.callKid(d, 1, false);
            }
		}
Ejemplo n.º 17
0
//    kampfschrei:/ konstruiert eine fantastische erfindung.
		public override void getBattlecryEffect(Playfield p, Minion own, Minion target, int choice)
		{
            if (p.isServer)
            {
                int random = p.getRandomNumber_SERVER(0, 3);
                if (random == 0) p.callKid(kid, own.zonepos, own.own, true);
                if (random == 1) p.callKid(kid1, own.zonepos, own.own, true);
                if (random == 2) p.callKid(kid2, own.zonepos, own.own, true);
                if (random == 3) p.callKid(kid3, own.zonepos, own.own, true);
                
                return;
            }
            p.callKid(kid, own.zonepos, own.own, true);
		}
Ejemplo n.º 18
0
		CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.NAX11_03);//Fallout Slime

		public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
		{
            int dmg = (ownplay) ? p.getHeroPowerDamage(1) : p.getEnemyHeroPowerDamage(1);
			p.allMinionsGetDamage(dmg);
			
            int place = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
            foreach (Minion m in p.ownMinions)
            {
				if (m.Hp <= 0) p.callKid(kid, place, ownplay);
			}
            foreach (Minion m in p.enemyMinions)
            {
				if (m.Hp <= 0) p.callKid(kid, place, ownplay);
			}
		}
Ejemplo n.º 19
0
        public override void onTurnStartTrigger(Playfield p, Minion triggerEffectMinion, bool turnStartOfOwner)
        {
            if(turnStartOfOwner != triggerEffectMinion.own) return;
            List<Minion> temp = (turnStartOfOwner) ? p.ownMinions : p.enemyMinions;
            int anz =0;
            foreach (Minion m in temp)
            {
                if ((TAG_RACE)m.handcard.card.race == TAG_RACE.MECHANICAL && m.Hp >=1 )
                {
                    anz++;
                }
            }
            if (anz >= 3)
            {
                foreach (Minion m in temp)
                {
                    if ((TAG_RACE)m.handcard.card.race == TAG_RACE.MECHANICAL)
                    {
                        p.minionGetDestroyed(m);
                    }
                }

                int pos = (triggerEffectMinion.own) ? p.ownMinions.Count : p.enemyMinions.Count;
                p.callKid(kid, pos, triggerEffectMinion.own,false, true); // we allow to summon one minion more (because 3 are destroyed)
            }
        }
Ejemplo n.º 20
0
        //    todesröcheln:/ ruft thaddius herbei, wenn feugen in diesem duell bereits gestorben ist.

        public override void onDeathrattle(Playfield p, Minion m)
        {
            if (p.stalaggDead)
            {
                p.callKid(thaddius, m.zonepos - 1, m.own);
            }
        }
Ejemplo n.º 21
0
//    combo:/ ruft einen banditen der defias (2/1) herbei.
		public override void getBattlecryEffect(Playfield p, Minion own, Minion target, int choice)
		{
            if (p.cardsPlayedThisTurn >= 1)
            {
                p.callKid(card, own.zonepos, own.own);
            }
		}
Ejemplo n.º 22
0
        //todo secret
        //    geheimnis:/ wenn euer gegner einen diener ausspielt, beschwört ihr eine kopie desselben herbei.

        public override void onSecretPlay(Playfield p, bool ownplay, Minion target, int number)
        {

            int posi = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
            p.callKid(target.handcard.card, posi, ownplay);
            if (ownplay)
            {
                if (p.ownMinions.Count >= 1 && p.ownMinions[p.ownMinions.Count - 1].name == target.handcard.card.name)
                {
                    int e = p.ownMinions[p.ownMinions.Count - 1].entitiyID;
                    p.ownMinions[p.ownMinions.Count - 1].setMinionTominion(target);
                    p.ownMinions[p.ownMinions.Count - 1].entitiyID = e;
                    p.ownMinions[p.ownMinions.Count - 1].own = true;
                }
            }
            else
            {
                if (p.enemyMinions.Count >= 1 && p.enemyMinions[p.enemyMinions.Count - 1].name == target.handcard.card.name)
                {
                    int e = p.enemyMinions[p.enemyMinions.Count - 1].entitiyID;
                    p.enemyMinions[p.enemyMinions.Count - 1].setMinionTominion(target);
                    p.enemyMinions[p.enemyMinions.Count - 1].entitiyID = e;
                    p.enemyMinions[p.enemyMinions.Count - 1].own = false;
                }
            }
        }
Ejemplo n.º 23
0
        CardDB.Card d = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.EX1_614t);//flameofazzinoth
//    beschwört jedes mal eine flamme von azzinoth (2/1), wenn ihr eine karte ausspielt.

        public override void onCardIsGoingToBePlayed(Playfield p, CardDB.Card c, bool wasOwnCard, Minion triggerEffectMinion, Minion target)
        {
            if (wasOwnCard == triggerEffectMinion.own)
            {
                    p.callKid(d, triggerEffectMinion.zonepos, triggerEffectMinion.own);

            }
        }
Ejemplo n.º 24
0
 public override void onCardIsGoingToBePlayed(Playfield p, CardDB.Card c, bool wasOwnCard, Minion triggerEffectMinion)
 {
     if (wasOwnCard == triggerEffectMinion.own && c.type == CardDB.cardtype.SPELL)
     {
         int place = (wasOwnCard)? p.ownMinions.Count : p.enemyMinions.Count;
         p.callKid(card, place, wasOwnCard);
     }
 }
Ejemplo n.º 25
0
//    vernichtet einen diener und bringt ihn dann mit vollem leben wieder auf das schlachtfeld zurück.

		public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
		{
            bool own = target.own;
            int place = target.zonepos;
            CardDB.Card d = target.handcard.card;
            p.minionGetDestroyed(target);
            p.callKid(d, place, own);
		}
Ejemplo n.º 26
0
        public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
        {
            if (ownplay && Probabilitymaker.Instance.ownGraveYardCommonAttack>=1)
            {
                int posi = p.ownMinions.Count;
                if (Probabilitymaker.Instance.ownGraveYardCommonTaunt == 1)
                {

                    
                    p.callKid(kid, posi, true);
                    Minion m = p.ownMinions[p.ownMinions.Count-1];
                    p.minionGetBuffed(m, Probabilitymaker.Instance.ownGraveYardCommonAttack - 1, Probabilitymaker.Instance.ownGraveYardCommonHP - 1);
                }
                else
                {
                    // create minion without taunt
                    p.callKid(kid, posi, true);
                    Minion m = p.ownMinions[p.ownMinions.Count - 1];
                    p.minionGetBuffed(m, Probabilitymaker.Instance.ownGraveYardCommonAttack - 1, Probabilitymaker.Instance.ownGraveYardCommonHP - 1);
                    m.taunt = false;
                }
            }


            if (!ownplay && Probabilitymaker.Instance.enemyGraveYardCommonAttack >= 1)
            {
                int posi = p.enemyMinions.Count;
                if (Probabilitymaker.Instance.enemyGraveYardCommonTaunt == 1)
                {


                    p.callKid(kid, posi, false);
                    Minion m = p.enemyMinions[p.enemyMinions.Count - 1];
                    p.minionGetBuffed(m, Probabilitymaker.Instance.enemyGraveYardCommonAttack - 1, Probabilitymaker.Instance.enemyGraveYardCommonHP - 1);
                }
                else
                {
                    // create minion without taunt
                    p.callKid(kid, posi, false);
                    Minion m = p.enemyMinions[p.enemyMinions.Count - 1];
                    p.minionGetBuffed(m, Probabilitymaker.Instance.enemyGraveYardCommonAttack - 1, Probabilitymaker.Instance.enemyGraveYardCommonHP - 1);
                    m.taunt = false;
                }
            }
        }
Ejemplo n.º 27
0
        CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.NEW1_040t);//gnoll
//    ruft am ende eures zuges einen gnoll (2/2) mit spott/ herbei.

        public override void onTurnEndsTrigger(Playfield p, Minion triggerEffectMinion, bool turnEndOfOwner)
        {
            if (triggerEffectMinion.own == turnEndOfOwner)
            {
                int posi = triggerEffectMinion.zonepos;

                p.callKid(kid, posi, triggerEffectMinion.own);
            }
        }
Ejemplo n.º 28
0
 public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
 {
     for (int i = 0; i < 3; i++)
     {
         int pos = (ownplay) ? p.ownMinions.Count : p.enemyMinions.Count;
         p.callKid(kid, pos, ownplay);
     }
     p.equipWeapon(w, ownplay);
 }
Ejemplo n.º 29
0
        CardDB.Card kid = CardDB.Instance.getCardDataFromID(CardDB.cardIDEnum.EX1_573t); //special treant
//    wählt aus:/ verleiht euren anderen dienern +2/+2; oder ruft zwei treants (2/2) mit spott/ herbei.
		public override void getBattlecryEffect(Playfield p, Minion own, Minion target, int choice)
		{
            if (choice == 1)
            {
                List<Minion> temp = (own.own) ? p.ownMinions : p.enemyMinions;
                foreach (Minion m in temp)
                {
                    p.minionGetBuffed(m, 2, 2);
                }
            }
            if (choice == 2)
            {

                int pos = (own.own) ? p.ownMinions.Count : p.enemyMinions.Count;
                p.callKid(kid, pos, own.own, true);
                p.callKid(kid, pos, own.own, true);
            }
		}
Ejemplo n.º 30
0
		// Summon a random friendly minion that died this game.
		
		public override void onCardPlay(Playfield p, bool ownplay, Minion target, int choice)
		{
            if (p.ownMaxMana >= 6)
            {
                int posi = ownplay ? p.ownMinions.Count : p.enemyMinions.Count;
                CardDB.Card kid = CardDB.Instance.getCardDataFromID((p.OwnLastDiedMinion == CardDB.cardIDEnum.None) ? CardDB.cardIDEnum.EX1_345t : p.OwnLastDiedMinion); // Shadow of Nothing 0:1 or ownMinion
                p.callKid(kid, posi, ownplay);
            }
		}