mirror of
https://github.com/ysoftdevs/pf2016.git
synced 2026-01-17 17:22:09 +01:00
finish marker
This commit is contained in:
BIN
data/images/gfx64/finish_marker.png
Normal file
BIN
data/images/gfx64/finish_marker.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 9.1 KiB |
@@ -14,6 +14,7 @@ state.preload = function() {
|
||||
this.addSpriteSheet('base', './data/images/gfx64/tiles.png', 64, 64);
|
||||
this.addSpriteSheet('character', './data/images/gfx64/marble_black.png', 80, 80 );
|
||||
this.addSpriteSheet('oneWay', './data/images/gfx64/st_oneway.png', 64, 64 );
|
||||
this.addSpriteSheet('finishMarker', './data/images/gfx64/finish_marker.png', 64, 64 );
|
||||
}
|
||||
|
||||
state.create = function() {
|
||||
@@ -37,6 +38,11 @@ state.create = function() {
|
||||
this.redirector2.cellIndex = 6;
|
||||
this.redirector2.box.hitbox = new Kiwi.Geom.Rectangle( 20, 20, 50, 50 );
|
||||
this.redirector2.input.enableDrag();
|
||||
|
||||
this.finishMarker = new Kiwi.GameObjects.Sprite(this, this.textures.finishMarker, 6*64, 4*64);
|
||||
this.finishMarker.box.hitbox = new Kiwi.Geom.Rectangle( 20, 20, 50, 50 );
|
||||
this.finishMarker.animation.add('idle', [ 0, 1, 2, 3, 2, 1 ], 0.3, true);
|
||||
this.finishMarker.animation.play('idle', true);
|
||||
|
||||
// Ground layer
|
||||
this.addChild(this.tilemap.layers[0]);
|
||||
@@ -45,9 +51,10 @@ state.create = function() {
|
||||
|
||||
// Walls layer
|
||||
this.addChild(this.tilemap.layers[1]);
|
||||
this.addChild(this.finishMarker);
|
||||
|
||||
this.addChild(this.redirector);
|
||||
this.addChild(this.redirector2);
|
||||
this.addChild(this.redirector2);
|
||||
|
||||
// Sky layer
|
||||
this.addChild(this.tilemap.layers[2]);
|
||||
|
||||
Reference in New Issue
Block a user