Fixed some things, did some other stuff as well.

This commit is contained in:
Bram van der Veen 2014-07-08 19:08:19 +02:00
parent 84f214bc74
commit d8b2661da8
10 changed files with 16 additions and 14 deletions

Binary file not shown.

View file

File diff suppressed because one or more lines are too long

Binary file not shown.

View file

@ -1,13 +1,13 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<project> <project>
<meta title="openfltest" package="com.example.app" version="1.0.0" company="" /> <meta title="Spááácè" package="hexlime.space" version="0.5.0" company="Bram van der Veen" />
<app file="Main" main="Main" path="bin" /> <app file="Main" main="Main" path="bin" />
<window fps="120þ" background="0x000000" /> <window fps="120þ" background="0x000000" />
<window width="360" height="640" resizable="false" unless="mobile" /> <window width="360" height="640" resizable="false" unless="mobile" />
<window orientation="portrait" fullscreen="true" if="mobile" /> <window orientation="portrait" fullscreen="true" if="mobile" />
<window orientation="portrait" vsync="true" antialiasing="0" if="cpp" /> <window orientation="portrait" vsync="true" antialiasing="8" if="cpp" />
<source path="src" /> <source path="src" />

View file

@ -16,7 +16,7 @@ class Lives extends Entity {
]; ];
liveBar = Image.createRect(Math.floor(baseSprite.width * .75), 10, 0x00FF00); liveBar = Image.createRect(Math.floor(baseSprite.width * .75), 10, 0x00FF00);
liveBar.y += 70; liveBar.y += 65;
baseSprite.scale = .75; baseSprite.scale = .75;
@ -24,7 +24,7 @@ class Lives extends Entity {
sprite[i].scale = .75; sprite[i].scale = .75;
} }
super(HXP.width - (baseSprite.width * .75 + 20), HXP.height - (baseSprite.height * .75 + 50)); super(HXP.width - (baseSprite.width * .75 + 20), 10);
graphic = baseSprite; graphic = baseSprite;

View file

@ -15,7 +15,7 @@ class MenuScene extends Scene {
backdrop = new Backdrop("graphics/darkPurple.png", true, true); backdrop = new Backdrop("graphics/darkPurple.png", true, true);
var play = new MenuButton(HXP.width / 2, HXP.height / 2, "Play!"); var play = new MenuButton(HXP.width / 2, HXP.height / 2, "Play!");
var title = new Title(); var title = new Title();
var copy = new Text("By Bram \"96AA48\" van der Veen, 2014", HXP.width / 2, HXP.height - 50); var copy = new Text("By Bram \"96AA48\" van der Veen, 2014\nGraphics and Sfx by Kenney\nMusic by Jensan", HXP.width / 2, HXP.height - 50, {align: "center"});
var spawner = new Spawner(); var spawner = new Spawner();
copy.size = 22; copy.size = 22;

View file

@ -17,7 +17,7 @@ class Pickup extends Entity {
sound = new Sfx("audio/powerUp6.wav"); sound = new Sfx("audio/powerUp6.wav");
#end #end
var tempRand = .9 /*Math.random()*/; var tempRand = Math.random();
if (tempRand < .15) if (tempRand < .15)
randType = 1; randType = 1;

View file

@ -93,14 +93,15 @@ class Player extends Entity {
} }
public function shoot() { public function shoot() {
var score:Array<Score> = []; if (this.y > 0) {
var score:Array<Score> = [];
this.scene.getClass(Score, score); this.scene.getClass(Score, score);
score[0].rem(500); score[0].rem(500);
this.scene.add(new Bullet(this.x + this.width / 2, this.y)); this.scene.add(new Bullet(this.x + this.width / 2, this.y));
laser.play(); laser.play();
}
} }
public function die() { public function die() {

View file

@ -11,7 +11,7 @@ class Score extends Entity {
name = "score"; name = "score";
score = 1000; score = 1000;
scoreText = new Text("$1000", 0, 0, 0, 0, {size : 50, align : "center", color : 0xFFF000}); scoreText = new Text("$1000", 0, 0, 0, 0, {size : 50, /*align : "center",*/ color : 0xFFF000});
scoreText.font = Assets.getFont("font/kenpixel_mini_square.ttf").fontName; scoreText.font = Assets.getFont("font/kenpixel_mini_square.ttf").fontName;
layer = -3; layer = -3;