would this work? Yes, No or Maybe?

Get help using Construct 2

Post » Fri Apr 29, 2016 5:21 am

Hello everybody,

I probably already know the answer to my question.

on start of layout compare windowsize
if window size > 16:9 goto layout small
if window size = 16:9 goto layout normal
if window size < 16:9 goto layout tablet

does this work? has anybody tried this? In theory it sounds solid.

What is your take on creating multiple screen sizes without making 20 of the exact same app?

Thanks in advanced for any input on this subject matter. Jeremy C.

Update:
Image
and the answer is yes it works. I have not tested on mobile device as of yet.

The code shown was for demo testing. So setting a

16:9, as in 1280x720px
16:10, as in 1680x1050px
5:3, as in 1280x768px
3:2, as in 960x640 (This screen ratio is also used on iDevices.)
4:3, as in 1024x768

ratio in a mobile app is possible without to much extra effort. Basically clone layout re-size to ratio and leave event sheet the same.

update 2:
so this should work with screen orientation also if you have to adjust for landscape/portrait.
on device landscape/portrait. goto layout or switch between active layers.
B
29
S
13
G
10
Posts: 355
Reputation: 8,327

Post » Fri Apr 29, 2016 7:25 am

I've done something like this for different interfaces when in landscape/mode by comparing to see if height is greater than width, so I'm pretty sure it would work to target different aspect ratios and resolutions. Although it seems like a lot of extra work, when I (and other big budget games I've noticed) can just use scale outer and pin ui elements to viewport edges or center to target all possible aspect ratios at once.

In case you haven't seen it before, this tutorial covers a lot regarding aspect ratios. https://www.scirra.com/tutorials/73/sup ... zes/page-2
Mistakes were made.
B
53
S
27
G
114
Posts: 1,698
Reputation: 64,444

Post » Fri Apr 29, 2016 7:41 am

oosyrag wrote:I've done something like this for different interfaces when in landscape/mode by comparing to see if height is greater than width, so I'm pretty sure it would work to target different aspect ratios and resolutions. Although it seems like a lot of extra work, when I (and other big budget games I've noticed) can just use scale outer and pin ui elements to viewport edges or center to target all possible aspect ratios at once.

In case you haven't seen it before, this tutorial covers a lot regarding aspect ratios. https://www.scirra.com/tutorials/73/sup ... zes/page-2


yes! I have seen that. but Understanding how it would work best for multiple screen sizes is a little hard.

as paralax sets 0,0 = same size as layer if layer = bigger/smaller HI moves or is off screen.
I could design center of layout but that would look off depending on the game/app I wish to create.
B
29
S
13
G
10
Posts: 355
Reputation: 8,327

Post » Fri Apr 29, 2016 3:50 pm

https://www.ravenheart.ca/home
I don't check the forums much anymore, but I will receive an email for PMs.

"Someone once told me I bite off more than I can chew...

I told them I would rather choke on greatness than nibble on mediocrity."
B
23
S
6
G
1
Posts: 1,419
Reputation: 4,857


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 19 guests