Weird problem with tables / persistent values? - Any advice please guys? :)

I've finally got my trial version of Catflap! out on the Android GP store, but having a REALLY strange problem with sound settings.

I've managed to secure permission to include some fantastic chiptune music from the very generous Frantisek Fuka (Fuxoft), so I now have a sound setting menu, and in it, once you adjust the sound settings, it changes it immediately - 1 slider for sound, 1 for music, and saves it in a table for when next loaded.

In the Creator, this works PERFECTLY in every way, debug shows the correct settings and values at all points (setting, saving, loading), and restarting the app retains and loads the settings as expected?

My problem is that once published and on devices, it DOESN'T retain the volume settings between launches - I'm suspecting it's something to do with having an Ad-hoc version on the device, so removed it, and tried again - this didn't fix the issue initially, but seems okay on my device now that I've removed ALL test / live versions of Catflap from it...

My question is - is anyone here aware of any issues with GS storing table data, when installing live over ad-hoc versions on a device - just want to make sure that if I'm doing something stupid, or there's an issue with what I'm doing, I'm nudged in the right direction?

I'd also be interested to hear if it works as expected for anyone willing to download and test it for me please?:-

https://play.google.com/store/apps/details?id=com.japsters.cavern.catflap

PS - One thing I can't seem to get my head around is that there is a DEVICE audio volume for both music and sound, but wherea sound commands have their own volume settings (which is great for my purposes), MUSIC only seems to have the device audio setting as a modifier, and no other control to affect volume WITHOUT manipulating that system attribute?

ie. I'd rather not set the actual device levels of volume to achieve a different volume level, but rather play sounds and music at X% of the CURRENT system volume setting... So if a user had selected say, externally, 25% volume for their phone, and my game's volume is set at full, it would be 25% of the devices maximum possible volume - ie. match user expectations!...

PS - I'm finally hoping to finish development on Catflap very soon, and although the logic's a bit hairy/mucky in places, I'm hoping to be able to take some of my more useful routines out and make them available for other users, once things have quietened down for me!

Cheers all!

Den.

Comments

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922

    You have to measure your sound based on device volume and then adjust sounds based on your music volume. So since you can't modify music then it becomes your benchmark.

  • JapsterJapster Member Posts: 672
    edited September 2015

    @Lost_Oasis_Games Wow! - that was a fast helpful response! - Cheers, will try to re-work based on that...

    So, basically, just allow sound volume to be set, and have my sounds become x% of that music level setting, based on my sounds slider setting?

    Cheers again, really appreciated mate...

  • JapsterJapster Member Posts: 672
    edited September 2015

    PS - one thing I find very strange is that even though I can load up and reset the game again in Creator, and sound levels are fine (perfect even, ie. as expected), once I load my game again on various phones, sometimes it restores the volume correctly, and on others it absolutely blasts out, even though on the phone, the levels settings are shown correctly by my debug actors?

    Very strange - even going into my sound settings screen shows that the values ARE correct for where I left them, and the sliders are also in the correct position, but for some reason the device audio (music) setting seems to be at max.... argh....

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    edited September 2015

    Are you testing Android? I though I might have read some issues with tables and android. Try using the save/load behaviors and see if that changes things.

Sign In or Register to comment.