Compare commits
No commits in common. '00fdf1b02b823e044f185efecf5960eb5f4d3ec5' and '32ed351d9543f1f5946e438b0f7d63b64563786b' have entirely different histories.
00fdf1b02b
...
32ed351d95
|
Before Width: | Height: | Size: 2.9 MiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.5 MiB |
|
Before Width: | Height: | Size: 1.4 MiB |
|
Before Width: | Height: | Size: 101 KiB |
|
Before Width: | Height: | Size: 121 KiB |
|
Before Width: | Height: | Size: 98 KiB |
@ -1,14 +0,0 @@
|
|||||||
import pygame
|
|
||||||
import settings
|
|
||||||
|
|
||||||
class Obstacle:
|
|
||||||
def __init__(self, x, y, image_path):
|
|
||||||
self.image = pygame.image.load(image_path).convert_alpha()
|
|
||||||
self.image = pygame.transform.scale(self.image, (300, 150)) # Größe anpassen
|
|
||||||
self.rect = self.image.get_rect(topleft=(x, y))
|
|
||||||
|
|
||||||
def draw(self, screen, camera_offset):
|
|
||||||
screen.blit(self.image, (self.rect.x - camera_offset, self.rect.y))
|
|
||||||
|
|
||||||
def get_rect(self):
|
|
||||||
return self.rect
|
|
||||||
Loading…
Reference in new issue