feat(nds): add audio in all menus

This commit is contained in:
2026-02-25 14:52:48 +01:00
parent 4af6de5329
commit 858082e151
45 changed files with 240 additions and 117 deletions

View File

@@ -68,6 +68,9 @@ export const useSettingsStore = defineStore("settings", {
},
async openSubMenu(submenu: SettingsSubMenu) {
const { assets } = useAssets();
assets.audio.menuOpen.play();
await gsap
.timeline()
.to(this.submenuTransition, {
@@ -99,7 +102,12 @@ export const useSettingsStore = defineStore("settings", {
}
},
async closeSubMenu() {
async closeSubMenu(silent = false) {
if (!silent) {
const { assets } = useAssets();
assets.audio.menuError.play();
}
await gsap
.timeline()
.to(this, {
@@ -148,6 +156,8 @@ export const useSettingsStore = defineStore("settings", {
animateIntro() {
this.isIntro = true;
const { assets } = useAssets();
gsap
.timeline()
// bars
@@ -178,6 +188,7 @@ export const useSettingsStore = defineStore("settings", {
{ 1: 0, duration: 0.1, ease: "none" },
0.2,
)
.call(() => assets.audio.settingsMenuIntro.play(), undefined, 0.2)
.fromTo(
this.menuOffsets,
{ 2: -48 },
@@ -198,8 +209,11 @@ export const useSettingsStore = defineStore("settings", {
animateOutro() {
this.isOutro = true;
const { assets } = useAssets();
gsap
.timeline()
.call(() => assets.audio.settingsMenuOutro.play())
// title notification
.fromTo(
this,