Update applications/sokoban/sokoban.ring - Separate Game Data from User Interface
-load "gameengine.ring"
-
-func main
-
- oGame = New Game
- {
-
- title = "Sokoban"
+#---------------#
+# Sokoban Game #
+#---------------#
- Map {
+# Game Data
- blockwidth = 60
- blockheight = 60
+ aPlayer = [
+ :Row = 3,
+ :Col = 4
+ ]
- aMap = [
+ aLevel = [
[1,1,1,2,2,2,2,2,1,1,1,1,1,1],
[1,2,2,2,1,1,1,2,1,1,1,1,1,1],
[1,2,4,3,5,1,1,2,1,1,1,1,1,1],
@@ -25,6 +22,22 @@ func main
[1,1,1,1,1,1,1,1,1,1,1,1,1,1]
]
+load "gameengine.ring"
+
+func main
+
+ oGame = New Game
+ {
+
+ title = "Sokoban"
+
+ Map {
+
+ blockwidth = 60
+ blockheight = 60
+
+ aMap = aLevel
+
aImages = [
"images/empty.jpg",
"images/wall.jpg",
