Hi this is Tom, so first time poster please be gentle.
I recently purchased PICO-8 and started going through a cool tutorial on how to use it.
Then I got to a video about sound and tried playing sounds in the engine ( PICO-8 ).
I played them with the laptops sounds muted and the headphones not, and the issue
is that the sounds are played to the Laptop, not to my headphones ( like the video I
was just watching ). So more to the point is this a known issue / is there a workaround?
Loving the system an everything so far just have this one issue, and I don't know
how to solve it.
OK so I figured it out. >_<
Before you run PICO-8 have the headset plugged in and set to default and don't unplug it. Once you do it breaks the connection and PICO-8 defaults to the computer or laptop. So if anyone else has this problem that's the solution.
Yeah, the sound output has always been finicky for me too -- if I put my laptop to sleep and then resume, it doesn't have sound any more, and while it's running (even in that state) it blocks sound from other applications. :/ Kind of a bummer but not hard to work around once you know what's going on. (Except when I don't want to close it because I'll lose my place in a game, haha.)
I ran into this, it was driving me crazy. I even updated PICO (had to update anyway) and I still had no sound. Turns out I had just accidentally muted it some time and not realized, it must live in a very persistent config somewhere.
The hotkey on windows is ctrl+m, probably command+m on osx.
Looks like PICO-8 literally just sets sound_volume to 0 in the config.txt file when you've used ctrl-m to mute it.
Interestingly, sound_volume seems to be an all-or-nothing setting:
If you manually edit it to be 0, volume is muted.
- If you manually edit it to anything other than 0, it's treated like 256, and gets saved as 256 going forward.
The volume setting in config.txt is the actual sound volume control, given this comment in the file:
// :: Audio Settings (use "volume" for PICO-8) sound_volume 256 // 0..256
(That comment should probably say "// 0 or 256".)
I'd guess @zep is just doing something like this pseudocode when reading config.txt:
if read_config("sound_volume") != 0 then mute_mul = 1 else mute_mul = 0 end volume_mul = read_config("volume") / 256
Then this during per-tick sound processing:
final_vol = note_vol * volume_mul * mute_mul
And this when it saves:
write_config("sound_volume", mute_mul * 256) write_config("volume", volume_mul * 256)
So the mute setting isn't a flag, it's actually just another volume control that can only be full or silent.
[Please log in to post a comment]