Began implementing even more of the logic.
This commit is contained in:
parent
93d3a20e06
commit
ef8b29d2fc
|
@ -72,8 +72,10 @@ class Level1(level.Level):
|
||||||
|
|
||||||
playfield_pos = (64*2, 48*2)
|
playfield_pos = (64*2, 48*2)
|
||||||
|
|
||||||
playfield, nsteps = (
|
playfield, nsteps, directions = (
|
||||||
logic.rollingstone.generate_simple_playfield(10, 10, 7, 50))
|
logic.rollingstone.generate_simple_unsolved_solvable_extra(10, 10, 7, 20))
|
||||||
|
|
||||||
|
arrowblocks = []
|
||||||
|
|
||||||
for i in range(10):
|
for i in range(10):
|
||||||
for j in range(10):
|
for j in range(10):
|
||||||
|
@ -86,6 +88,18 @@ class Level1(level.Level):
|
||||||
self.imgs['block1'],
|
self.imgs['block1'],
|
||||||
movable=True))
|
movable=True))
|
||||||
|
|
||||||
|
else:
|
||||||
|
arrowblocks.append(
|
||||||
|
(0, -1)
|
||||||
|
if playfield[(i, j)] is logic.rollingstone.Up
|
||||||
|
else (0, 1)
|
||||||
|
if playfield[(i, j)] is logic.rollingstone.Down
|
||||||
|
else (1, 0)
|
||||||
|
if playfield[(i, j)] is logic.rollingstone.Right
|
||||||
|
else (-1, 0))
|
||||||
|
|
||||||
|
print(arrowblocks)
|
||||||
|
|
||||||
def load(self):
|
def load(self):
|
||||||
"""Load all resources used in the level."""
|
"""Load all resources used in the level."""
|
||||||
tile_list = ['ground1', 'ground2']
|
tile_list = ['ground1', 'ground2']
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
# maintained by : Sakse Dalum <don_s@hongabar.org>
|
# maintained by : Sakse Dalum <don_s@hongabar.org>
|
||||||
|
|
||||||
"""
|
"""
|
||||||
A generic level.
|
The player.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import pygame
|
import pygame
|
||||||
|
|
Loading…
Reference in New Issue