diff --git a/Zombie.py b/Zombie.py new file mode 100644 index 0000000..d159959 --- /dev/null +++ b/Zombie.py @@ -0,0 +1,15 @@ +# Zombie.py +import pygame +from Enemy import Enemy + + +# 僵尸类 +class Zombie(Enemy): + def __init__(self, x, y): + super(Zombie, self).__init__() + self.image = pygame.image.load(f"imgs/{__name__}.png") + self.rect = self.image.get_rect() + self.rect.x = x + self.rect.y = y + + self.damage = 2