awesome123
Aspiring developer
Profile
Posts: 132
Reg: Dec 27, 2011
location unknow...
2,320
02/04/13 08:05 AM (12 years ago)

Found a bug - Quiz plugin

hey guys a found a bug in the quiz plugin the audio doesn't stop playing when press the back button. yes i have already set it up in buzztouch. i even copied the latest configuration data and refreshed a bunch of times. the weird thing is the option 'Audio Stops with "Back Button"' comes back to its default option. i've tried saved it a bunch of times already anybody experienced this too? btw, the quiz plugin version is v1.3
 
GilbertAZ
Aspiring developer
Profile
Posts: 37
Reg: Jul 16, 2012
Arizona
2,820
like
02/04/13 09:11 AM (12 years ago)
I've come across this issue too, not with the quiz, but just the audio option in general. A few suggestions on how I got this to work to shut off audio when user clicks back or on any exit from screen. 1) add "audioStopsOnScreenExit":"1" to your quiz section on your BT_config.txt file. The option in the control panel totally ignores this when you set this to true. This is a manual way and not great when you make a bunch of updates to your app, you'd have to do this every time. Which goes to the next solution. 2) This solution forces the audio to stop at the code level, you force the Audio Stop. In Xcode, locate the BT_viewControllerManager.m file in the BT_Layout folder. On line 208 comment out the IF condition looking for the "audioStopsOnExit", mine looks like this: /* COMMENT OUT THIS IF if([[BT_strings getJsonPropertyValue:parentScreenData.jsonVars:@"audioStopsOnScreenExit":@""] isEqualToString:@"1"]) { */ [BT_debugger showIt:self:[NSString stringWithFormat:@"stopping audio on screen exit for screen with itemId:%@", [parentScreenData itemId]]]; if(appDelegate.audioPlayer != nil){ [appDelegate.audioPlayer stopAudio]; } // COMMENT OUT CURLY } The other is on line 568 of the same file, looks like this: /* COMMENT OUT THIS IF if([[BT_strings getJsonPropertyValue:parentScreenData.jsonVars:@"audioStopsOnScreenExit":@""] isEqualToString:@"1"]){ */ [BT_debugger showIt:self:[NSString stringWithFormat:@"stopping audio on screen exit for screen with itemId:%@", [parentScreenData itemId]]]; if(appDelegate.audioPlayer != nil){ [appDelegate.audioPlayer stopAudio]; } // COMMENT OUT CURLY } Sorry, I assume you're using XCode, but you can look for this in Eclipse if you're doing Android. Good luck!
 
mrDavid
BTMods.com
Profile
Posts: 3936
Reg: May 21, 2011
San Diego, CA
51,910
like
02/04/13 09:40 AM (12 years ago)
@Alzooka awesome post mate! David https://buzztouchmods.com
 
Suvinay pawa
buzztouch Evangelist
Profile
Posts: 599
Reg: Aug 01, 2012
location unknow...
9,890
like
02/04/13 10:06 AM (12 years ago)
my audio doesnt even play:x
 
awesome123
Aspiring developer
Profile
Posts: 132
Reg: Dec 27, 2011
location unknow...
2,320
like
02/04/13 05:18 PM (12 years ago)
wow thanks for the detailed post Alzooka! I will try this out in a moment
 
awesome123
Aspiring developer
Profile
Posts: 132
Reg: Dec 27, 2011
location unknow...
2,320
like
02/04/13 08:41 PM (12 years ago)
you are a genius! it totally worked! i hope there's a thanks or rep button in this forum so i could give you some. thanks Alzooka!
 
GilbertAZ
Aspiring developer
Profile
Posts: 37
Reg: Jul 16, 2012
Arizona
2,820
like
02/04/13 09:46 PM (12 years ago)
Awesome! Glad I could be some help! :-)
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.