- added a direct native variant for A_PlaySound because this function is relatively easy to test.

This commit is contained in:
Christoph Oelckers 2018-11-25 18:40:26 +01:00
commit 176da5de68
4 changed files with 31 additions and 27 deletions

View file

@ -1253,3 +1253,15 @@ DEFINE_ACTION_FUNCTION_NATIVE(_Secplane, PointToDist, PointToDist)
ACTION_RETURN_FLOAT(self->PointToDist(DVector2(x, y), z));
}
DEFINE_ACTION_FUNCTION_NATIVE(AActor, A_PlaySound, A_PlaySound)
{
PARAM_SELF_PROLOGUE(AActor);
PARAM_SOUND(soundid);
PARAM_INT(channel);
PARAM_FLOAT(volume);
PARAM_BOOL(looping);
PARAM_FLOAT(attenuation);
PARAM_BOOL(local);
A_PlaySound(self, soundid, channel, volume, looping, attenuation, local);
return 0;
}