Improve sound
This commit is contained in:
parent
34311e3181
commit
b8e7df198d
10 changed files with 117 additions and 105 deletions
|
@ -53,11 +53,7 @@ export default Vue.extend({
|
|||
(this.$refs.tl as any).prepend(note);
|
||||
|
||||
if (this.sound) {
|
||||
const audio = new Audio(note.userId === this.$store.state.i.id
|
||||
? `/assets/sounds/${this.$store.state.device.sfxNoteMy}.mp3`
|
||||
: `/assets/sounds/${this.$store.state.device.sfxNote}.mp3`);
|
||||
audio.volume = this.$store.state.device.sfxVolume;
|
||||
audio.play();
|
||||
this.$root.sound(note.userId === this.$store.state.i.id ? 'noteMy' : 'note');
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue