2023-03-31 11:54:10 +02:00
|
|
|
import pygame
|
|
|
|
|
2023-04-14 12:31:54 +02:00
|
|
|
# Farbe Weiß
|
|
|
|
WHITE = (255, 255, 255)
|
2023-03-31 11:54:10 +02:00
|
|
|
|
|
|
|
class Erz(pygame.sprite.Sprite):
|
|
|
|
def __init__(self):
|
|
|
|
super().__init__()
|
2023-04-14 12:31:54 +02:00
|
|
|
self.image = pygame.image.load("Erzmine.png").convert_alpha()
|
2023-03-31 11:54:10 +02:00
|
|
|
self.rect = self.image.get_rect()
|
|
|
|
self.rect = 330, 20
|
|
|
|
|
|
|
|
|
|
|
|
def draw(self, win):
|
|
|
|
groesse = pygame.transform.scale(self.image, (100, 100))
|
|
|
|
win.blit(groesse, self.rect)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class Tank(pygame.sprite.Sprite):
|
|
|
|
|
|
|
|
def __init__(self):
|
|
|
|
super().__init__()
|
|
|
|
self.image = pygame.image.load("Tank.png").convert_alpha()
|
|
|
|
self.rect = self.image.get_rect()
|
|
|
|
self.rect = 30, 220
|
|
|
|
|
|
|
|
|
|
|
|
def draw(self, win):
|
|
|
|
groesse = pygame.transform.scale(self.image, (100, 100))
|
|
|
|
win.blit(groesse, self.rect)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class Ziel(pygame.sprite.Sprite):
|
|
|
|
|
|
|
|
def __init__(self):
|
|
|
|
super().__init__()
|
2023-04-14 12:31:54 +02:00
|
|
|
self.image = pygame.image.load("Ziel.png").convert_alpha()
|
2023-03-31 11:54:10 +02:00
|
|
|
self.rect = self.image.get_rect()
|
|
|
|
self.rect = 330, 520
|
|
|
|
|
|
|
|
|
|
|
|
def draw(self, win):
|
|
|
|
groesse = pygame.transform.scale(self.image, (100, 100))
|
|
|
|
win.blit(groesse, self.rect)
|
|
|
|
|