From 0597ee6860601d90802ddab7972713bc6a4c1d18 Mon Sep 17 00:00:00 2001 From: Kistaro Windrider Date: Sat, 17 Feb 2024 23:30:45 -0800 Subject: [PATCH] psound -- priority-aware channel-3-only sfx playback --- vacation.p8 | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/vacation.p8 b/vacation.p8 index 522a796..1707bb0 100644 --- a/vacation.p8 +++ b/vacation.p8 @@ -275,6 +275,13 @@ function font_special() poke(0x5f58, 0x81) end +-- play sound n on channel 3 iff +-- 3 doesn't already have a +-- greater index sound going +function psound(n, off, len) + if (stat(49) < n) sfx(n, 3, off, len) +end + -->8 -- text rendering