Skip to content

Commit

Permalink
fix audio
Browse files Browse the repository at this point in the history
Signed-off-by: Robert Müller 🚀 <[email protected]>
  • Loading branch information
Robert Müller 🚀 committed Oct 15, 2019
1 parent 8e435f5 commit 330ce7d
Show file tree
Hide file tree
Showing 13 changed files with 9 additions and 6 deletions.
Binary file added assets/sounds/effects/sfx_deathscream_alien4.mp3
Binary file not shown.
Binary file removed assets/sounds/effects/sfx_deathscream_alien4.wav
Binary file not shown.
Binary file not shown.
Binary file removed assets/sounds/effects/sfx_deathscream_human12.wav
Binary file not shown.
Binary file added assets/sounds/effects/sfx_menu_select1.mp3
Binary file not shown.
Binary file removed assets/sounds/effects/sfx_menu_select1.wav
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added assets/sounds/effects/sfx_wpn_dagger.mp3
Binary file not shown.
Binary file removed assets/sounds/effects/sfx_wpn_dagger.wav
Binary file not shown.
3 changes: 3 additions & 0 deletions index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ export const config: Types.Core.GameConfig = {
render: {
pixelArt: true,
},
audio: {
disableWebAudio: true,
},
};

const game = new Game(config);
10 changes: 5 additions & 5 deletions src/scenes/Intro.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export class Intro extends Scene {
this.load.audio('thriller', 'assets/sounds/thriller.mp3');
this.load.audio(
'menu-select',
'assets/sounds/effects/sfx_menu_select1.wav'
'assets/sounds/effects/sfx_menu_select1.mp3'
);
this.load.image('background', 'assets/backgrounds/map.png');
this.load.image('fullHeart', 'assets/heart.png');
Expand All @@ -49,19 +49,19 @@ export class Intro extends Scene {
this.load.audio('battle-main', 'assets/sounds/battle_main.mp3');
this.load.audio(
'enemy-death',
'assets/sounds/effects/sfx_deathscream_alien4.wav'
'assets/sounds/effects/sfx_deathscream_alien4.mp3'
);
this.load.audio(
'player-impact',
'assets/sounds/effects/sfx_deathscream_human12.wav'
'assets/sounds/effects/sfx_deathscream_human12.mp3'
);
this.load.audio(
'element-switch',
'assets/sounds/effects/sfx_wpn_dagger.wav'
'assets/sounds/effects/sfx_wpn_dagger.mp3'
);
this.load.audio(
'footsteps',
'assets/sounds/effects/sfx_movement_footstepsloop4_fast.wav'
'assets/sounds/effects/sfx_movement_footstepsloop4_fast.mp3'
);
this.load.spritesheet('firespirit', 'assets/objects/firespirit.png', {
frameWidth: 10,
Expand Down
2 changes: 1 addition & 1 deletion src/scenes/Room.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ export class Room extends Scene {
this._healthbar.ouch();
this._player.onHit();
this.cameras.main.shake(100, 0.01);
this.sound.add('player-impact', { volume: 2 }).play();
this.sound.add('player-impact').play();
}
);

Expand Down

0 comments on commit 330ce7d

Please sign in to comment.