diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index a76ab1f2c..c2241e6c1 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -431,6 +431,7 @@ volume: "音量" _sfx: note: "ノート" + noteMy: "ノート(自分)" notification: "通知" chat: "チャット" chatBg: "チャット(バックグラウンド)" diff --git a/src/client/assets/sounds/syuilo/down.mp3 b/src/client/assets/sounds/syuilo/down.mp3 new file mode 100644 index 000000000..4cd421139 Binary files /dev/null and b/src/client/assets/sounds/syuilo/down.mp3 differ diff --git a/src/client/assets/sounds/syuilo/pope1.mp3 b/src/client/assets/sounds/syuilo/pope1.mp3 index 585bb0407..d6f53cfac 100644 Binary files a/src/client/assets/sounds/syuilo/pope1.mp3 and b/src/client/assets/sounds/syuilo/pope1.mp3 differ diff --git a/src/client/assets/sounds/syuilo/pope2.mp3 b/src/client/assets/sounds/syuilo/pope2.mp3 index 83865b989..fe5d95e29 100644 Binary files a/src/client/assets/sounds/syuilo/pope2.mp3 and b/src/client/assets/sounds/syuilo/pope2.mp3 differ diff --git a/src/client/assets/sounds/syuilo/up.mp3 b/src/client/assets/sounds/syuilo/up.mp3 new file mode 100644 index 000000000..3f3086776 Binary files /dev/null and b/src/client/assets/sounds/syuilo/up.mp3 differ diff --git a/src/client/assets/sounds/syuilo/waon.mp3 b/src/client/assets/sounds/syuilo/waon.mp3 index c5797f066..a4af47386 100644 Binary files a/src/client/assets/sounds/syuilo/waon.mp3 and b/src/client/assets/sounds/syuilo/waon.mp3 differ diff --git a/src/client/components/timeline.vue b/src/client/components/timeline.vue index ba367bf23..6befd7c2a 100644 --- a/src/client/components/timeline.vue +++ b/src/client/components/timeline.vue @@ -53,7 +53,9 @@ export default Vue.extend({ (this.$refs.tl as any).prepend(note); if (this.sound) { - const audio = new Audio(`/assets/sounds/${this.$store.state.device.sfxNote}.mp3`); + 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(); } diff --git a/src/client/pages/preferences/index.vue b/src/client/pages/preferences/index.vue index 419395918..9d57ddad5 100644 --- a/src/client/pages/preferences/index.vue +++ b/src/client/pages/preferences/index.vue @@ -17,6 +17,11 @@ + + + + + @@ -87,6 +92,8 @@ import { langs } from '../../config'; const sounds = [ null, + 'syuilo/up', + 'syuilo/down', 'syuilo/pope1', 'syuilo/pope2', 'syuilo/waon', @@ -170,6 +177,11 @@ export default Vue.extend({ set(value) { this.$store.commit('device/set', { key: 'sfxNote', value }); } }, + sfxNoteMy: { + get() { return this.$store.state.device.sfxNoteMy; }, + set(value) { this.$store.commit('device/set', { key: 'sfxNoteMy', value }); } + }, + sfxNotification: { get() { return this.$store.state.device.sfxNotification; }, set(value) { this.$store.commit('device/set', { key: 'sfxNotification', value }); } diff --git a/src/client/store.ts b/src/client/store.ts index 4a329a0eb..1a26bc82d 100644 --- a/src/client/store.ts +++ b/src/client/store.ts @@ -42,10 +42,11 @@ const defaultDeviceSettings = { showFixedPostForm: false, useNotificationsPopup: true, sfxVolume: 0.3, - sfxNote: 'syuilo/pope1', + sfxNote: 'syuilo/down', + sfxNoteMy: 'syuilo/up', sfxNotification: 'syuilo/pope2', - sfxChat: 'syuilo/waon', - sfxChatBg: null, + sfxChat: 'syuilo/pope1', + sfxChatBg: 'syuilo/waon', userData: {}, };