Add rabbits, beavers and teddy bears

This commit is contained in:
Yohann D'ANELLO 2020-11-11 17:39:48 +01:00
parent a4eaab0db6
commit c329ec927f
3 changed files with 27 additions and 2 deletions

View File

@ -46,6 +46,9 @@ TexturePack.ASCII_PACK = TexturePack(
HEDGEHOG='*', HEDGEHOG='*',
HEART='', HEART='',
BOMB='o', BOMB='o',
RABBIT='Y',
BEAVER='_',
TEDDY_BEAR='8',
) )
TexturePack.SQUIRREL_PACK = TexturePack( TexturePack.SQUIRREL_PACK = TexturePack(
@ -62,4 +65,7 @@ TexturePack.SQUIRREL_PACK = TexturePack(
HEDGEHOG='🦔', HEDGEHOG='🦔',
HEART='💜', HEART='💜',
BOMB='💣', BOMB='💣',
RABBIT='🐇',
BEAVER='🦫',
TEDDY_BEAR='🧸',
) )

View File

@ -34,7 +34,25 @@ class Monster(FightingEntity):
break break
class Beaver(Monster):
name = "beaver"
maxhealth = 30
strength = 2
class Hedgehog(Monster): class Hedgehog(Monster):
name = "hedgehog" name = "hedgehog"
maxhealth = 10 maxhealth = 10
strength = 3 strength = 3
class Rabbit(Monster):
name = "rabbit"
maxhealth = 15
strength = 1
class TeddyBear(Monster):
name = "teddy_bear"
maxhealth = 500
strength = 0

View File

@ -202,8 +202,9 @@ class Entity:
@staticmethod @staticmethod
def get_all_entity_classes(): def get_all_entity_classes():
from dungeonbattle.entities.items import Heart, Bomb from dungeonbattle.entities.items import Heart, Bomb
from dungeonbattle.entities.monsters import Hedgehog from dungeonbattle.entities.monsters import Beaver, Hedgehog, \
return [Hedgehog, Heart, Bomb] Rabbit, TeddyBear
return [Beaver, Bomb, Heart, Hedgehog, Rabbit, TeddyBear]
class FightingEntity(Entity): class FightingEntity(Entity):