Resizing And Fullscreen

For questions about using Classic.

Post » Wed Oct 10, 2012 3:18 am

I made some sprites but I didn't make them with any particular resolution in mind (wont do that again) because I thought that I could just change the way or size they are displayed at within the fixed window size.

I was half right and half wrong. I learned that you can set a window size in the application properties and then use the window object to re-size everything to a different reasonable size (640x480, 1280x1024, etc.)

BUT, sometimes the sprites look weird and more importantly when you full-screen a game, it stretches or compresses everything depending on if your working with a wide-screen or standard screen size.

QUESTIONS:

1) Is my solution to the window resizing a good one or will that effect performance or cause other issues?

2) How do I prevent the stretching when entering full-screen

3) every time I try to use change resolution code in the event editor, the game would crash or not run. Is there a fix? Does it have to do with the size of my sprites? Could it be that only works for 3D objects?

Thank you in advanceRandomDood2012-10-10 03:21:44
B
3
Posts: 59
Reputation: 418

Post » Wed Oct 10, 2012 7:48 am

This one is kind of a tricky subject, and tends to vary a bit depending on whether you need scrolling or non-scrolling layers.

There used to be a good tutorial on this that I can't find at the moment, but take a look at Zotged's explanation and .cap in this thread:

http://www.scirra.com/forum/aspect-ratio-in-fullscreen_topic57440.html?KW=fullscreen

Does this help?
B
7
S
2
Posts: 123
Reputation: 1,061

Post » Thu Oct 11, 2012 8:26 pm

Thanks.

Its helps but I'm still left with some questions.

I guess though, that is is better to make the layout/window with the assumption that most monitors that it will be played on will be wide screen and not full wouldn't it?

Edit: having some problems replicating what the cap file is doing. More specifically how it seems to have this infinite Layout that you can scroll through.RandomDood2012-10-12 00:46:43
B
3
Posts: 59
Reputation: 418

Post » Fri Oct 12, 2012 1:17 am

Okay, well it turns out my whole window resizing method ONLY works for window mode and not full screen. (not a great solution)

So if anyone is using this post to help scale down sprites that they possible made to big. I would suggest the obvious solution (which I should have used) and use the System -> Display -> and zoom out (or in).
B
3
Posts: 59
Reputation: 418

Post » Sat Oct 13, 2012 12:30 pm

[QUOTE=RandomDood]I guess though, that is is better to make the layout/window with the assumption that most monitors that it will be played on will be wide screen and not full wouldn't it?[/QUOTE]Well whatever you yourself think is the most reasonable solution. If you want some concrete data on monitor sizes you could refer to, say, Steam Hardware Surveys.

[QUOTE=RandomDood]having some problems replicating what the cap file is doing. More specifically how it seems to have this infinite Layout that you can scroll through.[/QUOTE]Just tick Unbounded scrolling for the Layout.



The thing is that unless you have it ticked the letterboxing in the example doesn't work out at all, since the letterbox is just black sprites it's obvious that they HAVE to go beyond the layout boundaries so that the actual gamespace reaches the layout edge. Otherwise the scrolling would just stop right when the letterbox touches the layout corner, which results in broken display.

So as explained in the cap and the post you'll have to figure out how to deal with the area outside the layout bounds since scrolling makes them accessible.
B
11
S
2
G
3
Posts: 100
Reputation: 2,150

Post » Sat Oct 13, 2012 10:41 pm

Okay. Thanks for your help
B
3
Posts: 59
Reputation: 418

Post » Wed Oct 24, 2012 10:19 pm

Your example gave me a good idea of how to get this to work thanks. But can I ask if you found a solution for objects positions changing slightly when giving the player the options to change resolutions/ enter full screen?

(Different layer scrolling speeds)

Basically I want to do what Konjak(.org) did with his new Iconoclasts demo: http://www.mediafire.com/download.php?xc7vgc2pug4369d

How he gave the option for multiple screen sizes and fullscreen while still keeping everything where its suppose to be.

And yes I am promoting this guy while asking for help.RandomDood2012-10-24 23:13:53
B
3
Posts: 59
Reputation: 418

Post » Wed Oct 24, 2012 11:30 pm

In order to compensate for different resolutions etc, you need initialize your game at the start based on lots of different variables. You can look up information such as screen width, orientation, desktop vs mobile etc and then adjust your artwork at the start of the game so that when it plays it utilizes different scales or speeds or artwork.

So for example, you could change the paralaxing speeds of your backgrounds depending on if you are on mobile or on desktop.

At the beginning of the game check the type of device its running on, then adjust accordingly.

You could have completely different artwork for small screens vs large ones. depends how complicated you want to get. The easiest solution is to design your game with these restraints in mind. Place the information you need on screen in clever places, or take out un nessary things if you are playing on a tiny screen for example.
B
50
S
21
G
8
Posts: 844
Reputation: 10,299

Post » Fri Oct 26, 2012 8:43 pm

All I can say is "Uhhh".

To bad there is no Plug-in, or at the very least a tutorial to make this easier.

I mean I know its possible to do just by changing the resolution. (But I guess you just said that.) One of the things that really screw it a good execution is that scrolling.

So would it work if I had an options screen to change the resolution of the game, and then a function to re-initialize (re-launch) the game if "apply" is selected?RandomDood2012-10-26 20:46:15
B
3
Posts: 59
Reputation: 418


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 6 guests