forked from bartvdbraak/blender
Fix for #30336: Couldn't playback from Python without having played back via logic bricks once.
Thanks Colin Nickerson for reporting.
This commit is contained in:
parent
2377bfe32f
commit
697b494a30
@ -325,18 +325,15 @@ KX_PYMETHODDEF_DOC_NOARGS(KX_SoundActuator, startSound,
|
|||||||
"startSound()\n"
|
"startSound()\n"
|
||||||
"\tStarts the sound.\n")
|
"\tStarts the sound.\n")
|
||||||
{
|
{
|
||||||
if(!m_handle.isNull())
|
switch(m_handle.isNull() ? AUD_STATUS_INVALID : m_handle->getStatus())
|
||||||
{
|
{
|
||||||
switch(m_handle->getStatus())
|
case AUD_STATUS_PLAYING:
|
||||||
{
|
break;
|
||||||
case AUD_STATUS_PLAYING:
|
case AUD_STATUS_PAUSED:
|
||||||
break;
|
m_handle->resume();
|
||||||
case AUD_STATUS_PAUSED:
|
break;
|
||||||
m_handle->resume();
|
default:
|
||||||
break;
|
play();
|
||||||
default:
|
|
||||||
play();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
Py_RETURN_NONE;
|
Py_RETURN_NONE;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user