Reorganized assets
Before Width: | Height: | Size: 78 KiB After Width: | Height: | Size: 78 KiB |
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 17 KiB |
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 17 KiB |
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 138 B |
Before Width: | Height: | Size: 76 KiB After Width: | Height: | Size: 76 KiB |
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 24 KiB |
Before Width: | Height: | Size: 212 B After Width: | Height: | Size: 212 B |
Before Width: | Height: | Size: 195 B After Width: | Height: | Size: 195 B |
|
@ -11,17 +11,17 @@ module SpaceTac.View {
|
|||
this.load.setPreloadSprite(this.preloadBar);
|
||||
|
||||
// Load assets
|
||||
this.load.image("ui-shiplist-own", "assets/images/battle/shiplist-own.png");
|
||||
this.load.image("ui-shiplist-enemy", "assets/images/battle/shiplist-enemy.png");
|
||||
this.load.image("ui-arena-background", "assets/images/battle/arena-background.png");
|
||||
this.load.image("ui-battle-actionbar", "assets/images/ui/battle/actionbar.png");
|
||||
this.load.image("ui-battle-actionpointsempty", "assets/images/ui/battle/actionpointsempty.png");
|
||||
this.load.image("ui-battle-actionpointsfull", "assets/images/ui/battle/actionpointsfull.png");
|
||||
this.load.image("ui-battle-shipspritehover", "assets/images/ui/battle/shipspritehover.png");
|
||||
this.load.image("ui-ship-card", "assets/images/battle/ship-card.png");
|
||||
this.load.image("arena-ship", "assets/images/battle/ship01.png");
|
||||
this.load.image("ui-bar-standard-background", "assets/images/ui/bars/standard-background.png");
|
||||
this.load.image("ui-bar-standard-foreground", "assets/images/ui/bars/standard-foreground.png");
|
||||
this.load.image("battle-shiplist-own", "assets/images/battle/shiplist-own.png");
|
||||
this.load.image("battle-shiplist-enemy", "assets/images/battle/shiplist-enemy.png");
|
||||
this.load.image("battle-arena-background", "assets/images/battle/arena/background.png");
|
||||
this.load.image("battle-actionbar", "assets/images/battle/actionbar.png");
|
||||
this.load.image("battle-actionpointsempty", "assets/images/battle/actionpointsempty.png");
|
||||
this.load.image("battle-actionpointsfull", "assets/images/battle/actionpointsfull.png");
|
||||
this.load.image("battle-arena-shipspritehover", "assets/images/battle/arena/shipspritehover.png");
|
||||
this.load.image("battle-ship-card", "assets/images/battle/ship-card.png");
|
||||
this.load.image("battle-arena-ship01", "assets/images/battle/arena/ship01.png");
|
||||
this.load.image("common-standard-bar-background", "assets/images/common/standard-bar-background.png");
|
||||
this.load.image("common-standard-bar-foreground", "assets/images/common/standard-bar-foreground.png");
|
||||
}
|
||||
|
||||
create() {
|
||||
|
|
|
@ -21,12 +21,12 @@ module SpaceTac.View {
|
|||
this.actions = [];
|
||||
this.ship = null;
|
||||
|
||||
super(battleview.game, 170, 0, "ui-battle-actionbar");
|
||||
super(battleview.game, 170, 0, "battle-actionbar");
|
||||
battleview.ui.add(this);
|
||||
|
||||
// Action points progress bar
|
||||
this.actionpoints = new ValueBar(battleview.game, 119, 76, "ui-battle-actionpointsempty");
|
||||
this.actionpoints.setBarImage("ui-battle-actionpointsfull");
|
||||
this.actionpoints = new ValueBar(battleview.game, 119, 76, "battle-actionpointsempty");
|
||||
this.actionpoints.setBarImage("battle-actionpointsfull");
|
||||
this.addChild(this.actionpoints);
|
||||
}
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ module SpaceTac.View {
|
|||
|
||||
super(battleview.game);
|
||||
|
||||
var background = new Phaser.Button(battleview.game, 0, 0, "ui-arena-background");
|
||||
var background = new Phaser.Button(battleview.game, 0, 0, "battle-arena-background");
|
||||
var expected_width = 1280 - 252;
|
||||
var expected_height = 720 - 100;
|
||||
background.scale.set(expected_width / background.width, expected_height / background.height);
|
||||
|
|
|
@ -19,14 +19,14 @@ module SpaceTac.View {
|
|||
super(battleview.game);
|
||||
|
||||
// Add hover effect
|
||||
this.hover = new Phaser.Image(battleview.game, 0, 0, "ui-battle-shipspritehover", 0);
|
||||
this.hover = new Phaser.Image(battleview.game, 0, 0, "battle-arena-shipspritehover", 0);
|
||||
this.hover.scale.set(0.4, 0.4);
|
||||
this.hover.anchor.set(0.5, 0.5);
|
||||
this.hover.visible = false;
|
||||
this.addChild(this.hover);
|
||||
|
||||
// Add ship sprite
|
||||
this.sprite = new Phaser.Button(battleview.game, 0, 0, "arena-ship");
|
||||
this.sprite = new Phaser.Button(battleview.game, 0, 0, "battle-arena-ship01");
|
||||
this.sprite.scale.set(0.1, 0.1);
|
||||
this.sprite.rotation = ship.arena_angle;
|
||||
this.sprite.anchor.set(0.5, 0.5);
|
||||
|
|
|
@ -8,7 +8,7 @@ module SpaceTac.View {
|
|||
|
||||
// Build an empty ship card
|
||||
constructor(battleview: BattleView, x: number, y: number) {
|
||||
super(battleview.game, x, y, "ui-ship-card");
|
||||
super(battleview.game, x, y, "battle-ship-card");
|
||||
|
||||
this.ship = null;
|
||||
this.visible = false;
|
||||
|
|
|
@ -10,7 +10,7 @@ module SpaceTac.View {
|
|||
constructor(list: ShipList, x: number, y: number, ship: Game.Ship, owned: boolean) {
|
||||
this.ship = ship;
|
||||
|
||||
super(list.battleview.game, x, y, owned ? "ui-shiplist-own" : "ui-shiplist-enemy");
|
||||
super(list.battleview.game, x, y, owned ? "battle-shiplist-own" : "battle-shiplist-enemy");
|
||||
|
||||
this.input.useHandCursor = true;
|
||||
this.onInputOver.add(() => {
|
||||
|
|
|
@ -17,8 +17,8 @@ module SpaceTac.View {
|
|||
|
||||
// Create a quick standard bar
|
||||
static newStandard(game: Phaser.Game, x: number, y: number): ValueBar {
|
||||
var result = new ValueBar(game, x, y, "ui-bar-standard-background");
|
||||
result.setBarImage("ui-bar-standard-foreground", 5, 5);
|
||||
var result = new ValueBar(game, x, y, "common-standard-bar-background");
|
||||
result.setBarImage("common-standard-bar-foreground", 5, 5);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|