Android Back button

Previous topic - Next topic

MrPlow

Hi Guys

My old AE used to allow me to use backbutton to exit and pause my apps

New version just exits if enabled and allows code to fire if false.

but not the older method which was best method.

Any one fix this?
Comp:
Speccy-48k, Speccy-128k, Amigas, PCs

spacefractal

#1
This is by design to workaround limits and bugs on Android/glbasic (not sure why, but its out of my hand here).

Im cant really do anything like anymore and im wont look on this issue anymore, so its is are its are now. Android is a quite very pity hell on this issue and have fighted throught a long time with it (if its not a bug in glbasic eventuelly). So this is what you see and that it. Im wont do anything more about this issue.

Im remember the main reason im did this limits is simply glbasic dosent resume correctly and often crash out when back was used. This is why its best to disable it and doing that by code intead. If you enable it, your game will quit (which is more safe than getting those resume trouble).
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

MrPlow

#2
No probs! Thanks SF

I 'm such a numpty! there is a pause method using the menu button...! As back button should be for quitting anyway...

The only issue i have is the buttons hiding - I need them to show themselves on PAUSE mode so user can press up main menu and game pauses...
Is that passible with code?


Comp:
Speccy-48k, Speccy-128k, Amigas, PCs

spacefractal

in Karma Miwa Im uses this for back button when you are in game play:

First press activate the pause menu,
second press quit the pause menu and is now in the menu,
third back will now quit the game.

you can do similar like those with the backbutton. The backbutton when used with GameControllers("Menu")>600 OR GameControllers("Pause")>600 or something like that.

Property the can been bug in KEY(1) which is still holding down when touched it. Its should not do that. This is a bug im can fix to the next version.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

MrPlow

I can work around the key(1) bug with a gettimerall() value so that the key(1) event expires after 100ms or so.
:)
Comp:
Speccy-48k, Speccy-128k, Amigas, PCs

spacefractal

Or just ADD a another variable so KEY(1) only invoke if that variable is false.... It's not really a bug, but no reason it's hold it.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/