Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / [BUG] AGK Version 2.0.10: SetSpriteDepth seems not to work properly on Android

Author
Message
Multicoder
AGK Developer
10
Years of Service
User Offline
Joined: 25th Oct 2014
Location: Germany
Posted: 7th Dec 2014 18:24 Edited at: 7th Dec 2014 22:22
UPDATE: NO BUG IN AppGameKit! IT WAS A BUG IN ONE OF MY SOURCE-FILES!


Hi there,

I have a sprite that is used as the background in all my menus.
I have another sprite that is used to "frame" the menu elements.

The sprite depth of the background is set in function "show_main_menu" to 50.
The sprite depth of the "frame" is set in function "show_options_menu" to 30.

On PC everything looks fine:


On my Android phone the "frame" appears under the background and therefore is not visible:


I have to call
again in function "show_options_menu" to make the "frame" appear correctly:


Yes, I am aware that I sound like a caveman to native english speakers
Pong Clone 2k14 {Android}
Impetus73
13
Years of Service
User Offline
Joined: 28th Aug 2011
Location: Volda, Norway
Posted: 7th Dec 2014 21:01
Did you update the android player to 2.0.10 ?

We need some code to test the error.

----------------
AGK programmer
Did Amiga / AMOS programming in the 90's.
Multicoder
AGK Developer
10
Years of Service
User Offline
Joined: 25th Oct 2014
Location: Germany
Posted: 7th Dec 2014 22:21 Edited at: 7th Dec 2014 22:23
Yes, I updated the player.
I even had to completely reinstall it because after the update nothing worked anymore^^

I am SO glad you asked for a peace of code...
I tried to put something together, but was unable to reproduce the bug.

Then I made an output every 2 lines in my original code and narrowed the "bug" down to a file 2 layers deeper...

That was the issue:

So no bug, just a very stupid me that sets the depth of a sprite with the id of a text...

Yes, I am aware that I sound like a caveman to native english speakers
Pong Clone 2k14 {Android}
Impetus73
13
Years of Service
User Offline
Joined: 28th Aug 2011
Location: Volda, Norway
Posted: 8th Dec 2014 18:07
ok, glad you found your bug, and even more glad there were no bug in AppGameKit

----------------
AGK programmer
Did Amiga / AMOS programming in the 90's.

Login to post a reply

Server time is: 2024-11-25 13:45:59
Your offset time is: 2024-11-25 13:45:59