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 / Screen pos not the same

Author
Message
Game_Code_here
4
Years of Service
User Offline
Joined: 2nd Jun 2020
Location:
Posted: 27th Nov 2022 22:12 Edited at: 27th Nov 2022 22:14
Screen pos is not the same no matter what in different phones, with virtual resolution.

It is read that when you use virtual resolution then every device will be stretched to fit that screen.

Well I tested this and it is not true.

I tested this on 4 different phones all different sizes, and in each something is off, either text or a sprite or my grid.

Only the phone that the app was built for that it loads and looks right.

Now I will say that most all the levels look ok and are just about right, but you can tell on the bigger devices text moved way down to the bottom of the screen and sprites not stretched at all.

I am using

GetScreenBoundsTop()
GetScreenBoundsLeft()
GetScreenBoundsBottom()
GetScreenBoundsRight()

And all my text and sprites are using a 100 to 100 percentage pos.

So My question is.

What is the best size to build your apps , so it loads just as you want for bigger devices?

I am not talking about computer games, I am only talking about phones or iPads.

Thanks.
Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 27th Nov 2022 22:34
Quote: "using a 100 to 100 percentage pos."

i never use it but have you read THIS?
Game_Code_here
4
Years of Service
User Offline
Joined: 2nd Jun 2020
Location:
Posted: 27th Nov 2022 22:51
Hi Virtual Nomad

I have read that thanks, it is based only for computers and not phones so it does me no good.

At the very end it states

Next time we'll look at having different displays for different devices and orientations.

So I am lost and frustrated.

There are millions of different sized devices and we are to pick just one to develop our apps for, So I am finding out now.
Game_Code_here
4
Years of Service
User Offline
Joined: 2nd Jun 2020
Location:
Posted: 28th Nov 2022 02:42
Ok I have figured this out somewhat.

If I size my background sprites - there size then pos them not all phones = that size but if I size my background sprites with a fixed value They all pos correctly.

Also I found if you have a resolution of 100,100.

The Y value is 200, so I had to resize all my sprites to 200.

Login to post a reply

Server time is: 2024-11-21 12:56:48
Your offset time is: 2024-11-21 12:56:48