From 2ab94c6e84f9616f6cfcd7f40598ef4a3685f045 Mon Sep 17 00:00:00 2001 From: Stephen Simpson Date: Tue, 11 Oct 2011 00:17:40 -0500 Subject: added ability to have sounds play for MountainGecko --- src/bossMegaGoomba.cpp | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/bossMegaGoomba.cpp b/src/bossMegaGoomba.cpp index e6c2b0b..02a7426 100644 --- a/src/bossMegaGoomba.cpp +++ b/src/bossMegaGoomba.cpp @@ -91,6 +91,7 @@ class daMegaGoomba_c : public dEn_c { DECLARE_STATE(Launch); }; +extern "C" void *PlaySound(dStageActor_c *, int soundID); //extern void * HandleXSpeed(daMegaGoomba_c*); //extern void * HandleYSpeed(daMegaGoomba_c*); @@ -501,12 +502,6 @@ void daMegaGoomba_c::executeState_Walk() { if(this->pickedChoice != -1) { Choice = this->pickedChoice; - /* - if(this->playIt = 1) { - playSound(this->toPlay); - this->playIt = 0; - } - */ } else { Choice = GenerateRandomNumber(4); } @@ -520,8 +515,12 @@ void daMegaGoomba_c::executeState_Walk() { case 2: break; //FIXME test case for sound effects - //case 3: - // break; + case 3: + if(this->playIt = 1) { + PlaySound(this->toPlay); + this->playIt = 0; + } + break; default: this->direction = dSprite_c__getXDirectionOfFurthestPlayerRelativeToVEC3(this, pos); this->timer = 0; -- cgit v1.2.3