Exemple #1
0
 def __init__(self,x , y):
     GameObject.__init__(self, x, y)
     self.renderer = ImageRenderer('Scene4/images/trap/single_thorn_1.png')
     # self.image = pygame.image.load('../images/trap/medium_thorn.png')
     self.collider = BoxCollider(20, 60)
     self.limit = 448
     self.Active = False
 def __init__(self, x, y):
     GameObject.__init__(self, x, y)
     self.renderer = ImageRenderer('Scene4/images/map/grass1.png')
     # self.image = pygame.image.load('../images/map/grass1.png')
     self.collider = BoxCollider(32, 32)
     self.isActive = False
     self.Active = False
     self.count = 176
     self.limit = 416
 def __init__(self, x, y, frame_delay=1):
     self.frame_counter = FrameCounter(frame_delay)
     GameObject.__init__(self, x, y)
     self.renderer = Animation([
         "Scene4/images/player/player_stand.png",
         "Scene4/images/player/playerDeath1.png",
         "Scene4/images/player/playerDeath2.png",
         "Scene4/images/player/playerDeath3.png"
     ])
 def __init__(self, x, y, input_manager):
     GameObject.__init__(self, x, y)
     self.image = pygame.image.load('Scene4/images/player/player_stand.png')
     self.image = pygame.transform.scale(self.image, (32, 64))
     self.width = self.image.get_width()
     self.heigth = self.image.get_height()
     self.win = False
     self.isJump = False
     self.speed = 4
     self.jumpHight = 16
     self.input_manager = input_manager
     self.counter = FrameCounter(24)
     self.pressJump = False
     self.collider = BoxCollider(self.width, self.heigth)
     self.resetLock()
     self.Alive = True
     self.renderer = PlayerAnimation()
     self.dx = 0
     self.dy = 0
 def __init__(self,x , y):
     GameObject.__init__(self, x, y)
     self.renderer = ImageRenderer('Scene4/images/map/platform.png')
     # self.image = pygame.image.load('../images/map/platform.png')
     self.collider = BoxCollider(32, 32)
 def __init__(self, x, y):
     GameObject.__init__(self, x, y)
     self.renderer = ImageRenderer('Scene4/images/trap/hidden_thorn.png')
     # self.image = pygame.image.load('../images/trap/hidden_thorn.png')
     self.collider = BoxCollider(30, 32)
     self.isActive = False
 def __init__(self, width, height):
     GameObject.__init__(self, 0 , 0)
     self.width = width
     self.height = height
 def __init__(self, x, y):
     GameObject.__init__(self, x, y)
     self.renderer = ImageRenderer('Scene4/images/trap/thorn.png')
     # self.image = pygame.image.load('../images/trap/thorn.png')
     self.collider = BoxCollider(24, 30)
 def __init__(self, x, y):
     GameObject.__init__(self, x, y)
     self.renderer = ImageRenderer('Scene4/images/map/laser.png')
 def __init__(self, x, y):
     GameObject.__init__(self, x, y)
     self.renderer = ImageRenderer('Scene4/images/map/locked_door.png')
     # self.image = pygame.image.load('../images/map/grass1.png')
     self.collider = BoxCollider(32, 544)