コード例 #1
0
ファイル: druid.py プロジェクト: futouyiba/HyperbolaAI
 def __init__(self):
     super().__init__("Cenarius", 9, CHARACTER_CLASS.DRUID, CARD_RARITY.LEGENDARY, choices=[
         Choice(IncreaseStats(), Give([Buff(ChangeAttack(2)),
                                       Buff(ChangeHealth(2)),
                                       Buff(Taunt())]), MinionSelector()),
         Choice(SummonTreants(), Summon(TauntTreant(), 2), PlayerSelector())
     ])
コード例 #2
0
ファイル: priest.py プロジェクト: smallsweet/hearthbreaker
 def __init__(self):
     super().__init__("Temple Enforcer",
                      6,
                      CHARACTER_CLASS.PRIEST,
                      CARD_RARITY.COMMON,
                      battlecry=Battlecry(
                          Give(ChangeHealth(3)),
                          MinionSelector(picker=UserPicker())))
コード例 #3
0
ファイル: shaman.py プロジェクト: futouyiba/HyperbolaAI
 def create_weapon(self, player):
     return Weapon(3,
                   2,
                   deathrattle=Deathrattle(
                       Give([Buff(ChangeHealth(2)),
                             Buff(ChangeAttack(2))]),
                       MinionSelector(IsType(MINION_TYPE.MECH),
                                      picker=RandomPicker())))
コード例 #4
0
 def create_minion(self, player):
     return Minion(
         3,
         3,
         effects=[
             Effect(TurnEnded(HasSecret()),
                    ActionTag(Give(ChangeAttack(2)), SelfSelector())),
             Effect(TurnEnded(HasSecret()),
                    ActionTag(Give(ChangeHealth(2)), SelfSelector()))
         ])
コード例 #5
0
ファイル: priest.py プロジェクト: smallsweet/hearthbreaker
 def __init__(self):
     super().__init__("Upgraded Repair Bot",
                      5,
                      CHARACTER_CLASS.PRIEST,
                      CARD_RARITY.RARE,
                      minion_type=MINION_TYPE.MECH,
                      battlecry=Battlecry(
                          Give(ChangeHealth(4)),
                          MinionSelector(IsType(MINION_TYPE.MECH),
                                         picker=UserPicker())))
コード例 #6
0
 def __init__(self):
     super().__init__(
         "Quartermaster",
         5,
         CHARACTER_CLASS.PALADIN,
         CARD_RARITY.EPIC,
         battlecry=Battlecry(
             Give([Buff(ChangeAttack(2)),
                   Buff(ChangeHealth(2))]),
             MinionSelector(HasCardName("Silver Hand Recruit"))))
コード例 #7
0
 def create_minion(self, player):
     return Minion(
         2,
         2,
         effects=[
             Effect(MinionDied(IsType(MINION_TYPE.BEAST)),
                    ActionTag(Give(ChangeAttack(2)), SelfSelector())),
             Effect(MinionDied(IsType(MINION_TYPE.BEAST)),
                    ActionTag(Give(ChangeHealth(1)), SelfSelector()))
         ])
コード例 #8
0
 def create_minion(self, player):
     return Minion(0,
                   1,
                   stealth=True,
                   effects=[
                       Effect(
                           TurnEnded(),
                           ActionTag(Give(ChangeHealth(1)),
                                     MinionSelector(picker=RandomPicker())))
                   ])
コード例 #9
0
 def create_minion(self, player):
     return Minion(9,
                   7,
                   auras=[
                       Aura(ChangeHealth(2),
                            MinionSelector(IsType(MINION_TYPE.DEMON))),
                       Aura(ChangeAttack(2),
                            MinionSelector(IsType(MINION_TYPE.DEMON))),
                       Aura(Immune(), HeroSelector())
                   ])
コード例 #10
0
 def create_minion(self, player):
     return Minion(
         2,
         4,
         effects=[
             Effect(CardPlayed(HasOverload()),
                    ActionTag(Give(ChangeAttack(1)), SelfSelector())),
             Effect(CardPlayed(HasOverload()),
                    ActionTag(Give(ChangeHealth(1)), SelfSelector()))
         ])
コード例 #11
0
 def __init__(self):
     super().__init__(
         "Core Rager",
         4,
         CHARACTER_CLASS.HUNTER,
         CARD_RARITY.RARE,
         minion_type=MINION_TYPE.BEAST,
         battlecry=(Battlecry(
             Give([Buff(ChangeAttack(3)),
                   Buff(ChangeHealth(3))]), SelfSelector(),
             Not(GreaterThan(Count(CardSelector()), value=0)))))
コード例 #12
0
 def create_minion(self, player):
     return Minion(
         4,
         4,
         effects=[
             Effect(
                 CharacterDamaged(And(IsHero(), OwnersTurn())),
                 ActionTag(
                     Give([Buff(ChangeAttack(2)),
                           Buff(ChangeHealth(2))]), SelfSelector()))
         ])
コード例 #13
0
 def __init__(self):
     super().__init__(
         "Screwjank Clunker",
         4,
         CHARACTER_CLASS.WARRIOR,
         CARD_RARITY.RARE,
         minion_type=MINION_TYPE.MECH,
         battlecry=Battlecry(
             Give([Buff(ChangeHealth(2)),
                   Buff(ChangeAttack(2))]),
             MinionSelector(IsType(MINION_TYPE.MECH), picker=UserPicker())))
コード例 #14
0
ファイル: game_objects.py プロジェクト: futouyiba/HyperbolaAI
    def increase_health(self, amount):
        """
        Increase the amount of  total health this :class:`Character` has.  This is a permanent effect (unless the
        Character is silenced).  This effect will increase both the player's current health and maximum health

        :param int amount: the amount to increase health by
        """

        self.trigger("health_increased", amount)
        self.add_buff(Buff(ChangeHealth(amount)))
        self.trigger("health_changed")
コード例 #15
0
ファイル: priest.py プロジェクト: futouyiba/HyperbolaAI
 def __init__(self):
     super().__init__(
         "Twilight Whelp",
         1,
         CHARACTER_CLASS.PRIEST,
         CARD_RARITY.COMMON,
         minion_type=MINION_TYPE.DRAGON,
         battlecry=(Battlecry(
             Give(Buff(ChangeHealth(2))), SelfSelector(),
             GreaterThan(Count(
                 CardSelector(condition=IsType(MINION_TYPE.DRAGON))),
                         value=0))))
コード例 #16
0
 def __init__(self):
     super().__init__("Anodized Robo Cub",
                      2,
                      CHARACTER_CLASS.DRUID,
                      CARD_RARITY.COMMON,
                      minion_type=MINION_TYPE.MECH,
                      choices=[
                          Choice(AttackMode(),
                                 Give([Buff(ChangeAttack(1))]),
                                 SelfSelector()),
                          Choice(TankMode(), Give([Buff(ChangeHealth(1))]),
                                 SelfSelector())
                      ])
コード例 #17
0
 def create_minion(self, player):
     return Minion(
         2,
         2,
         effects=[
             Effect(
                 TurnEnded(),
                 ActionTag(
                     Give([Buff(ChangeAttack(2)),
                           Buff(ChangeHealth(2))]),
                     MinionSelector(IsType(MINION_TYPE.MECH),
                                    picker=RandomPicker())))
         ])
コード例 #18
0
 def create_weapon(self, player):
     return Weapon(
         1,
         5,
         effects=[
             Effect(
                 MinionSummoned(),
                 ActionTag(
                     Give([Buff(ChangeAttack(1)),
                           Buff(ChangeHealth(1))]), TargetSelector())),
             Effect(MinionSummoned(),
                    ActionTag(DecreaseDurability(), WeaponSelector()))
         ])
コード例 #19
0
 def __init__(self):
     super().__init__("Houndmaster",
                      4,
                      CHARACTER_CLASS.HUNTER,
                      CARD_RARITY.FREE,
                      minion_type=MINION_TYPE.NONE,
                      battlecry=Battlecry(
                          Give([
                              Buff(ChangeHealth(2)),
                              Buff(ChangeAttack(2)),
                              Buff(Taunt())
                          ]),
                          MinionSelector(IsType(MINION_TYPE.BEAST),
                                         picker=UserPicker())))
コード例 #20
0
    def __init__(self):

        super().__init__("Ancient of War",
                         7,
                         CHARACTER_CLASS.DRUID,
                         CARD_RARITY.EPIC,
                         choices=[
                             Choice(
                                 Health(),
                                 Give([Buff(ChangeHealth(5)),
                                       Buff(Taunt())]), SelfSelector()),
                             Choice(Attack(), Give([Buff(ChangeAttack(5))]),
                                    SelfSelector()),
                         ])
コード例 #21
0
ファイル: game_objects.py プロジェクト: futouyiba/HyperbolaAI
    def decrease_health(self, amount):
        """
        Decrease the amount of  total health this :class:`Character` has.  This is a permanent effect (unless the
        Character is silenced).  This effect will decrease the player's maximum health, but will only decrease
        the player's health if it is above the new value for maximum health

        :param int amount: the amount to decrease health by
        """
        if self.enraged and self.health == self.calculate_max_health():
            self.enraged = False
            self.trigger("unenraged")
            self._do_unenrage()
        self.add_buff(Buff(ChangeHealth(-amount)))
        self.trigger("health_changed")
        self.trigger("health_decreased", amount)
コード例 #22
0
 def __init__(self):
     super().__init__("Edwin VanCleef",
                      3,
                      CHARACTER_CLASS.ROGUE,
                      CARD_RARITY.LEGENDARY,
                      battlecry=Battlecry(
                          Give([
                              Buff(
                                  ChangeAttack(
                                      Attribute("cards_played",
                                                PlayerSelector()), 2)),
                              Buff(
                                  ChangeHealth(
                                      Attribute("cards_played",
                                                PlayerSelector()), 2))
                          ]), SelfSelector()))
コード例 #23
0
 def __init__(self):
     super().__init__(
         "Void Terror",
         3,
         CHARACTER_CLASS.WARLOCK,
         CARD_RARITY.RARE,
         minion_type=MINION_TYPE.DEMON,
         battlecry=(Battlecry(
             Give([
                 Buff(
                     ChangeHealth(
                         Attribute("health", MinionSelector(Adjacent())))),
                 Buff(
                     ChangeAttack(
                         Attribute("attack", MinionSelector(Adjacent()))))
             ]),
             SelfSelector()), Battlecry(Kill(),
                                        MinionSelector(Adjacent()))))
コード例 #24
0
ファイル: priest.py プロジェクト: smallsweet/hearthbreaker
 def create_minion(self, player):
     return Minion(3,
                   4,
                   deathrattle=Deathrattle(
                       Give(ChangeHealth(3)),
                       MinionSelector(picker=RandomPicker())))