I am trying to change the behavior of my thermal detonator prop.
I added these in my saber_base.h:
/* Detonator effects */ \
DEFINE_EFFECT(BGNARM) \
DEFINE_EFFECT(ENDARM) \
Because they are used to trigger some .bmp in my DetonatorDisplayController to play on OLED.
I start the lockup with:
SaberBase::SetLockup(SaberBase::LOCKUP_ARMED);
SaberBase::DoBeginLockup();
SaberBase::DoEffect(EFFECT_BGNARM, 0);
If I understand hybrid_font.h, this should play bgnarm.wav once followed by armhum.wav looped ?
To stop it, I would like to do one of two things:
- either I want to play endarm.wav once and I do:
SaberBase::DoEndLockup();
SaberBase::SetLockup(SaberBase::LOCKUP_NONE);
SaberBase::DoEffect(EFFECT_ENDARM, 0);
- or I want to play boom.wav (but not hear endarm.wav)
can I do:
SaberBase::DoEffect(EFFECT_BOOM, 0);
SaberBase::SetLockup(SaberBase::LOCKUP_NONE); // I don't want to "end the lockup", I just want to stop it.
Off(OFF_BLAST);
Thanks for any help.