2 tipos de enemigos
This commit is contained in:
parent
e80a88cb13
commit
0830bc5d46
@ -398,14 +398,20 @@ class Game:
|
||||
)
|
||||
self.spares.append(spare)
|
||||
|
||||
# Generar bloques y ambos tipos de enemigos a lo largo del mapa
|
||||
for y in range(10, GRID_SIZE_Y - 15, 6):
|
||||
self.entities.append(PushBlock(y % GRID_SIZE_X, y))
|
||||
# Generar bloques y enemigos a lo largo de toda la autopista (de y = 10 hasta la salida)
|
||||
for y in range(10, GRID_SIZE_Y - 12):
|
||||
# 1. Bloques de prueba blancos en diferentes carriles
|
||||
if y % 6 == 0:
|
||||
lane = (y * 3) % GRID_SIZE_X
|
||||
self.entities.append(PushBlock(lane, y))
|
||||
|
||||
# Alternar entre enemigos destructibles e indestructibles
|
||||
if y % 12 == 0:
|
||||
destructible = (y % 24) == 0
|
||||
self.entities.append(Enemy(3.5, y - 2, destructible=destructible))
|
||||
# 2. Enemigos destructibles (Prismas Rojos - 3 disparos)
|
||||
if y % 14 == 0:
|
||||
self.entities.append(Enemy(2.0, y, destructible=True))
|
||||
|
||||
# 3. Enemigos indestructibles (Prismas Blancos - Solo bloqueables)
|
||||
if y % 20 == 0:
|
||||
self.entities.append(Enemy(5.0, y, destructible=False))
|
||||
|
||||
def handle_collisions(self):
|
||||
# Muerte por contacto con enemigo
|
||||
|
||||
BIN
img-versiones/version_2.1.png
Normal file
BIN
img-versiones/version_2.1.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 18 KiB |
Loading…
x
Reference in New Issue
Block a user