def __init__(self, name, pos, sprite, sprite_empty, effect, times):
     Entity.__init__(self, name, pos, sprite)
     self.effect = effect
     self.times = times
     self.sprite_empty = pg.transform.scale(
         pg.image.load(sprite_empty).convert_alpha(),
         (TILE_SIZE, TILE_SIZE))
Ejemplo n.º 2
0
 def __init__(self, pos, sprite_close, sprite_open, potential_items):
     Entity.__init__(self, "Chest", pos, sprite_close)
     self.sprite_open_link = sprite_open
     self.sprite_close_link = sprite_close
     self.sprite_open = pg.transform.scale(
         pg.image.load(sprite_open).convert_alpha(), (TILE_SIZE, TILE_SIZE))
     self.item = Chest.determine_item(potential_items)
     self.opened = False
     self.pick_lock_initiated = False
    def __init__(self, name, pos, sprite, interaction=None):
        Entity.__init__(self, name, pos, sprite)
        self.sprite_name = sprite
        self.interaction = interaction

        self.door_sfx = pg.mixer.Sound(os.path.join('sound_fx', 'door.ogg'))
        self.gold_sfx = pg.mixer.Sound(os.path.join('sound_fx', 'trade.ogg'))
        self.talk_sfx = pg.mixer.Sound(os.path.join('sound_fx', 'talking.ogg'))
        self.inventory_sfx = pg.mixer.Sound(os.path.join('sound_fx', 'inventory.ogg'))
Ejemplo n.º 4
0
    def __init__(self, name, pos, sprite, hp, defense, res):
        Entity.__init__(self, name, pos, sprite)
        self.hp_max = hp
        self.hp = hp
        self.defense = defense
        self.res = res

        self.attack_sfx = pg.mixer.Sound(os.path.join('sound_fx',
                                                      'attack.ogg'))
Ejemplo n.º 5
0
    def __init__(self, pos, sprite_close, sprite_open, potential_items):
        Entity.__init__(self, "Chest", pos, sprite_close)
        self.sprite_open_link = sprite_open
        self.sprite_close_link = sprite_close
        self.sprite_open = pg.transform.scale(
            pg.image.load(sprite_open).convert_alpha(), (TILE_SIZE, TILE_SIZE))
        self.item = Chest.determine_item(potential_items)
        self.opened = False
        self.pick_lock_initiated = False

        self.chest_sfx = pg.mixer.Sound(os.path.join('sound_fx', 'chest.ogg'))
Ejemplo n.º 6
0
 def __init__(self, pos_first, sprite):
     Entity.__init__(self, "Portal", pos_first, sprite)
     self.linked_to = None
Ejemplo n.º 7
0
 def __init__(self, name, pos, sprite, hp, defense, res):
     Entity.__init__(self, name, pos, sprite)
     self.hp_max = hp
     self.hp = hp
     self.defense = defense
     self.res = res
Ejemplo n.º 8
0
 def __init__(self, name, pos, sprite, interaction=None):
     Entity.__init__(self, name, pos, sprite)
     self.sprite_name = sprite
     self.interaction = interaction