Secretchronicles/TSC

TSC segfaults when OpenAL not available

Closed this issue · 4 comments

xet7 commented

Hi,
I'm trying to run TSC in a Xen VM on Qubes OS.

When I start TSC, it begins repeating this error:

An internal OpenAL call failed in SoundSource.cpp(196).
Expression:
   alGetSourcei(m_source, AL_SOURCE_STATE, &status)
Error description:
   AL_INVALID_OPERATION
   The specified operation is not allowed in the current state.

After repeating it many times, TSC segfaults:

./run-tsc.sh: line 7: 27432 Segmentation fault      ./bin/tsc

Would it be possible to disable sound, when it's not available? And let me play TSC without sound?

refi is right. There's no way to have SFML handle this, and in general, there's no way to handle this automatically as there exists no API to query for the question: “does the sound driver work properly?”.

What you can try is to edit the file ~/.config/tsc/config.xml. In that file you'll find these two lines:

  <property name="audio_music" value="1"/>
  <property name="audio_sound" value="1"/>

Change the "1" values to "0". This is the same as turning off sound and music in the game's option menu. I don't know if this prevents TSC from ever calling SFML's audio methods, but maybe it does.

I don't think there's anything more that can be done, and I specifically do not think that this is a bug in TSC. It's not TSC's job to fix the PC's audio system.

@xet7 did the XML trick work?

xet7 commented

@Quintus

I did not try XML trick. In other VM type sound did work. Nevermind.