How do I Correctly set UI size To Window

Get help using Construct 2

Post » Sun Aug 31, 2014 10:22 pm

Hello community,

After read some exemple and Tut's i have no others solutions than ask you if someone can help me ...

This is the problem :

I've create all my game with a Window Size for the project of 900x600 ( This work good )

- One Layer named "UI" with the propriety Scale Rate : 100, Parallax : 100,100 ( In the "UI" layout and ) Scale Rate : 100, Parallax : 0,0 ( In "Game" layout )

- One Layer named "Game" with the propriety Scale Rate : 100, Parallax : 100,100 ( In "UI" and "Game" Layout )

This work perfectly ...

Now i'm trying to give the player the possibility to adapt the Game Window to is own Window, for exemple 1920x1080 ...

So for this i have add : On start of Layout --> Set FullScreen Scaling to low quality/Set canvas size to 1920x1080 ... ( Just for test and after make an option panel ... but when it work hehe ^^ )

And this work BUT change all the Layout size héhé ... So as i say all my game was based on a 900x600 Window Screen and now i see all what is in the margin of "UI" Layout and the layout was in the center of the screen =s ...

So i've try to add Anchor but i can't really add anchor for all my UI because i have a lot of things XD ... Then the Objects in the Margins Are here too, and for finish when i zoom the UI zoom too XD ...

So i hope some one can help me =)

Thank you.
B
21
S
9
G
3
Posts: 70
Reputation: 2,729

Post » Mon Sep 01, 2014 11:47 am

Little Bump.
B
21
S
9
G
3
Posts: 70
Reputation: 2,729

Post » Mon Sep 01, 2014 1:13 pm

I'm not quite sure what you are trying to do and if I do understand I'm wondering why you are doing it this way..
What do you mean by "give the player the possibility to adapt the Game Window to is own Window"?

Have you tried just scaling the game layer down to make the playable area bigger?
Also have you tried setting the UI position relative to viewportLeft, viewportTop,viewportRight and viewportBottom?
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Mon Sep 01, 2014 9:52 pm

Hello Stain, one ofmy best friend hehe ^^' ...

( *Sorry for the time just looking the reply =s ... )

Can you explain me how to set up the Position relative please =s ... ( Don't know how to do it XD )

So when i say "Give the player the possibility to adapt the Game Window to is own Window"?, i mean it :

Create an Option Window where the player can choose some options like Window Size : 800x600, 1280x720, 1600x900, etc ... An other option for set the Window in FullScreen mode etc ...

When i have see your method by using Viewport, i have understand what you explain but don't really know how to perform it hehe ^^' ... But i think this cn be the solution of my problem =)
B
21
S
9
G
3
Posts: 70
Reputation: 2,729


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 6 guests