Implement F12 game reset (MRI only)

Can be disabled with "enableReset=false".

While at it, also replace the flakey volatile bool flags
with proper atomics.
This commit is contained in:
Jonas Kulla 2014-08-24 07:36:19 +02:00
parent 3a2e560139
commit d223d83cbf
23 changed files with 343 additions and 60 deletions

View file

@ -97,6 +97,15 @@ DEF_FADE( me )
DEF_PLAY_STOP( se )
RB_METHOD(audioReset)
{
RB_UNUSED_PARAM;
shState->audio().reset();
return Qnil;
}
#define BIND_PLAY_STOP(entity) \
_rb_define_module_function(module, #entity "_play", audio_##entity##Play); \
@ -129,4 +138,6 @@ audioBindingInit()
}
BIND_PLAY_STOP( se )
_rb_define_module_function(module, "__reset__", audioReset);
}