Added Spaceship image for example
This commit is contained in:
BIN
_5587d010-1481-491b-8ce6-5e3dbc14e74e.jpeg
Normal file
BIN
_5587d010-1481-491b-8ce6-5e3dbc14e74e.jpeg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 186 KiB |
10
test.py
10
test.py
@@ -70,16 +70,8 @@ while(gamestate):
|
||||
pos_x = mouse_pos[0]
|
||||
pos_y = mouse_pos[1]
|
||||
|
||||
#Rendere alle Objecte in objects Liste
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
player.firecontrol(screen)
|
||||
|
||||
|
||||
for projectiles in GameObject.Projectile.shots:
|
||||
projectiles:dict
|
||||
for key, projectile in projectiles.items():
|
||||
@@ -92,6 +84,8 @@ while(gamestate):
|
||||
player.points += 10
|
||||
index = spawned_enemys.index(enemy)
|
||||
del spawned_enemys[index]
|
||||
index = GameObject.Projectile.shots.index(projectiles)
|
||||
del GameObject.Projectile.shots[index]
|
||||
print(F"Player-Points: {player.points}")
|
||||
if(pygame.Rect.colliderect(projectile.rect, player.rect)):
|
||||
print("Game-OVer")
|
||||
|
||||
Reference in New Issue
Block a user