Level Changes

Adding in a new layer in later levels caused old levels to crash due to
missing layer. Added empty layer for the older levels.
This commit is contained in:
ESloman 2016-02-22 14:30:33 +00:00
parent 9f2627947c
commit d91ee3946c
6 changed files with 23 additions and 4 deletions

View file

@ -29,4 +29,9 @@
<polyline points="0,0 0,640 128,640 128,0 0,0"/> <polyline points="0,0 0,640 128,640 128,0 0,0"/>
</object> </object>
</objectgroup> </objectgroup>
<layer name="SPIKES" width="50" height="8">
<data encoding="base64" compression="zlib">
eJxjYBgFo2AUjIJRMApIBwAGQAAB
</data>
</layer>
</map> </map>

View file

@ -29,4 +29,9 @@
<polyline points="0,0 128,0 128,512 0,512 0,0"/> <polyline points="0,0 128,0 128,512 0,512 0,0"/>
</object> </object>
</objectgroup> </objectgroup>
<layer name="SPIKES" width="50" height="8">
<data encoding="base64" compression="zlib">
eJxjYBgFo2AUjIJRMApIBwAGQAAB
</data>
</layer>
</map> </map>

View file

@ -29,4 +29,9 @@
<polyline points="0,0 0,640 128,640 128,0 0,0"/> <polyline points="0,0 0,640 128,640 128,0 0,0"/>
</object> </object>
</objectgroup> </objectgroup>
<layer name="SPIKES" width="50" height="8">
<data encoding="base64" compression="zlib">
eJxjYBgFo2AUjIJRMApIBwAGQAAB
</data>
</layer>
</map> </map>

View file

@ -29,4 +29,9 @@
<polyline points="0,0 128,0 128,512 0,512 0,0"/> <polyline points="0,0 128,0 128,512 0,512 0,0"/>
</object> </object>
</objectgroup> </objectgroup>
<layer name="SPIKES" width="50" height="8">
<data encoding="base64" compression="zlib">
eJxjYBgFo2AUjIJRMApIBwAGQAAB
</data>
</layer>
</map> </map>

View file

@ -29,10 +29,9 @@ public class Spike extends Base {
new Vector2((-size.x / 2 + 5) / PPM, (size.y / 2 + 5) / PPM), new Vector2((-size.x / 2 + 5) / PPM, (size.y / 2 + 5) / PPM),
new Vector2((size.x / 2 - 5) / PPM, (size.y / 2 + 5) / PPM) new Vector2((size.x / 2 - 5) / PPM, (size.y / 2 + 5) / PPM)
}, },
"SPIKE", "SPIKES",
true, true,
Vars.BIT_MISC, Vars.BIT_MISC, maskBits
Vars.BIT_PLAYER
); );
} }
} }

View file

@ -352,7 +352,7 @@ public class Play extends AbstractScreen {
{ {
introWindow = new Window("Level "+levelNumber, skin); introWindow = new Window("Level "+levelNumber, skin);
introWindow.getTitleLabel().setPosition(350, 500); introWindow.getTitleLabel().setPosition(350, 500);
introBackground = new Image(app.assets.get("textures/level1Intro.png", Texture.class)); introBackground = new Image(app.assets.get("textures/level" + levelNumber + "Intro.png", Texture.class));
introWindow.setBackground(introBackground.getDrawable()); introWindow.setBackground(introBackground.getDrawable());
introWindow.setSize(700, 500); introWindow.setSize(700, 500);
introWindow.setPosition(280, 50); introWindow.setPosition(280, 50);