Snake bug fixes, stil WIP. Moved page logic into a separate JS file.

This commit is contained in:
Joanthan Bernard
2014-12-18 21:01:12 -06:00
parent e247071dc4
commit dd63438ae6
4 changed files with 66 additions and 67 deletions

View File

@@ -7,7 +7,7 @@
// Level 1: Hello Snake!
small.push({
small.levels.push({
"name": "Hello Snake!", "rows":10, "cols":10,
"easy": { "fps": 2, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps": 4, "targetScore": 7, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -26,7 +26,7 @@
1,1,1,1,1,1,1,1,1,1]});
// Level 2: Room to Grow
small.push({
small.levels.push({
"name": "Room to Grow", "rows":16, "cols":16,
"easy": { "fps":3, "targetScore": 7, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 7, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -51,7 +51,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 3: North and South
small.push({
small.levels.push({
"name": "North and South", "rows":15, "cols":15,
"easy": { "fps":3, "targetScore": 6, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 6, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -75,7 +75,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 4: Four Small Rooms
small.push({
small.levels.push({
"name": "Four Small Rooms","rows":15,"cols":15,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -99,7 +99,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 5: Polka Dots
small.push({
small.levels.push({
"name": "Polka Dots" ,"rows":15,"cols":15,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -123,7 +123,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 6: Toaster Face
small.push({
small.levels.push({
"name": "Toaster Face","rows":15,"cols":15,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -147,7 +147,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 7: Wierd Walls
small.push({
small.levels.push({
"name": "Wierd Walls","rows":15,"cols":15,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -171,7 +171,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 8: Feast and Famine
small.push({
small.levels.push({
"name": "Feast and Famine","rows":15,"cols":15,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -195,7 +195,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 1: Maze 1
mazes.push({
mazes.levels.push({
"name": "Maze 1","rows":15,"cols":15,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -219,7 +219,7 @@
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
// Level 2: Spiral
mazes.push({
mazes.levels.push({
"name": "Spiral","rows":15,"cols":15,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -244,7 +244,7 @@
// Level 3: Maze 2
mazes.push({
mazes.levels.push({
"name": "Maze 2","rows":17,"cols":17,
"easy": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
"medium": { "fps":3, "targetScore": 5, "growthFactor": 2, "growthFactorIncrease": 1},
@@ -267,8 +267,7 @@
1,0,1,1,1,1,0,0,0,0,1,1,1,1,1,0,1,
1,0,1,0,0,0,1,1,1,1,0,0,0,1,0,0,1,
1,0,0,0,1,0,0,0,0,0,0,1,0,0,0,1,1,
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]}
]);
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]});
window.SnakeLevels = {
"Small Rooms": small,