We have audio! Thanks @orsi!

This commit is contained in:
jorsi
2020-05-28 19:10:09 -04:00
committed by Michael Townsend
parent d6d1c1b987
commit a601473645
106 changed files with 1415 additions and 399 deletions
+4 -1
View File
@@ -7,7 +7,6 @@ var Ship = {
ALLOY_PER_THRUSTER: 1,
BASE_HULL: 0,
BASE_THRUSTERS: 1,
name: _("Ship"),
init: function(options) {
this.options = $.extend(
@@ -91,6 +90,7 @@ var Ship = {
Notifications.notify(Ship, _('somewhere above the debris cloud, the wanderer fleet hovers. been on this rock too long.'));
$SM.set('game.spaceShip.seenShip', true);
}
AudioEngine.playBackgroundMusic(AudioLibrary.MUSIC_SHIP);
Engine.moveStoresView(null, transition_diff);
},
@@ -112,6 +112,7 @@ var Ship = {
Button.setDisabled($('#liftoffButton', Ship.panel), false);
}
$('#hullRow .row_val', Ship.panel).text($SM.get('game.spaceShip.hull'));
AudioEngine.playSound(AudioLibrary.REINFORCE_HULL);
},
upgradeEngine: function() {
@@ -122,6 +123,7 @@ var Ship = {
$SM.add('stores["alien alloy"]', -Ship.ALLOY_PER_THRUSTER);
$SM.add('game.spaceShip.thrusters', 1);
$('#engineRow .row_val', Ship.panel).text($SM.get('game.spaceShip.thrusters'));
AudioEngine.playSound(AudioLibrary.UPGRADE_ENGINE);
},
getMaxHull: function() {
@@ -166,6 +168,7 @@ var Ship = {
$('#outerSlider').animate({top: '700px'}, 300);
Space.onArrival();
Engine.activeModule = Space;
AudioEngine.playSound(AudioLibrary.LIFT_OFF);
},
handleStateUpdates: function(e){