[Suggestion] Vertically centered fullscreen mode

  • Would it possible to add an option to center the layout vertically and/or horizontally in the window, when exporting as 'fullscreen in browser'?

    ie. If I use a layout with a 16x9 aspect ratio, and export as fullscreen in scale mode that is centered horizontally, and then run the game on a 4x3 monitor in fullscreen... I could quite easily add black bars onto a non-scrolling layer to retain the 16x9 aspect ratio quite well... or just leave out the black bars, allowing fullscreen on any ratio monitor, but with the main area sensibly placed in the center of the screen rather than sitting at the top with a whole lot of extra space underneath.

    Does that make sense?

  • If I understood this properly, it's already there:

    <img src="http://images.devs-on.net/Image/SKtGd6Cm3B9YCV4-Construct2Layout.png" border="0" />

    Set the Unbounded Scrolling to YES when using Full Screen and it's centered.

  • Thanks for the suggestion, but maybe I didn't explain myself as well as I thought. I tried to say that I basically want control over the shape of the viewable area, while allowing for browser resizing and fullscreen mode.

    I want it to be letterbox on monitors that aren't as wide as the layout, and pillarbox on monitors that are wider than the layout... and in doing this the viewable area would, of course, need to be centered vertically and horizontally.

    I don't really understand how unbounded scrolling is related to this, and I would prefer to not have to sacrifice this option in order to get it working the way I want... hence the 'suggestion' for it to be built into C2 as a feature.

    In any case, in fiddling with this, I've just realised that I can't get any HUD type object to scale properly when exporting as fullscreen in browser... but I'm far too tired to work it out now.

  • Have you checked this tutorial ?

    I haven't messed with resolutions yet but I'm pretty sure all the answers lie here.

    At least, the part about HUD is covered.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • At first the example file used in the tutorial works great... that is until I want to scroll around and then the letterbox/pillarbox effect disappears, presumably because it wasn't a real letterbox, just a case of the layout being exactly the right shape and revealing black bars *behind* the rest of the layout. I want the bars to be there no matter what I happen to do with my game... as it stands, this only works well if the layout is exactly the same size as the output window.

    Also, as soon as I want the HUD to scale with the window like everything else... it gets totally lost.

    Darn. I was under the impression that C2 would handle the various requirements of differing aspect ratios better than CC. I have to stand by my original suggestion... it needs to be built into C2 properly.

    Thanks for the help guys.

  • I was going to add "black bars" as another fullscreen mode (scale + bars) so hopefully that would fix it.

    As for HUDs not scaling, that's kind of a bug, I made the HUD not scale at all in the tutorial because it's not really supported. I'll see if I can fix that for a future build.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)