mentuat Posted May 25, 2013 Share Posted May 25, 2013 In a scenario where you have a mobile game designed for landscape but the user is holding the phone in portrait (or vice versa), i'd be interested in opinions on whether it's preferable to...A) pause/hide the game and display a message requesting user rotate device to correct orientation resize + reposition game regardless of orientation (allowing game to appear pretty tiny in the wrong orientation)C) something else (rotate all game assets 90 degrees to fake an orientation lock?) jogutierrez 1 Quote Link to comment Share on other sites More sharing options...
Lowren Posted May 25, 2013 Share Posted May 25, 2013 I use the first one. The others solutions you mention sound not very good for me, because the game experience is altered. A clear orientation instruction is better than letting the player trying to play a game who looks buggy. Quote Link to comment Share on other sites More sharing options...
fatalfluff Posted May 25, 2013 Share Posted May 25, 2013 I enforce A) too, but I only test once at the very beginning, if the user is holding his device correctly. Quote Link to comment Share on other sites More sharing options...
rich Posted May 26, 2013 Share Posted May 26, 2013 I always go for option 1 and will pause/display regardless of when they rotate the phone. I.e. on start-up, mid play, etc. Quote Link to comment Share on other sites More sharing options...
sbat Posted May 27, 2013 Share Posted May 27, 2013 For my first HTML5 game I am going with A so far. I would love to make the following check though:if <playing on huge phone/tablet> {allowUserToPlayInWrongOrientation();} Anyone knows solid library that can make this type of check for most common tablets and phablets? Even more ideally though I like what Candy Crash Saga is doing: smartly reposition all game elements to suite the orientation. In certain types of games it works really well and looks very polished. Quote Link to comment Share on other sites More sharing options...
mentuat Posted May 27, 2013 Author Share Posted May 27, 2013 thanks for the input, I have option A in at the moment as it seemed the best balance between presenting the game in good a way and being clear to the user, glad it is pretty much the standard I would love to make the following check though:if <playing on huge phone/tablet> {allowUserToPlayInWrongOrientation();}ha yeah I agree! I guess using a tedious combinaton of userAgent checking and assumptions on browser width/height it's conceivable to cover the majority of current devices to perform this check to a fairly accurate degree - but the sheer amount of devices being released regularly and ever changing pixel counts would make it pain to support in the future Quote Link to comment Share on other sites More sharing options...
rich Posted May 27, 2013 Share Posted May 27, 2013 I don't think it's that complicated honestly. The device/browser is nearly always irrelevant, all that matters is how many pixels you've got to play with. If it's enough for an 'HD' version of the game, then run in that mode, otherwise low res. That's the only rule I use. jogutierrez 1 Quote Link to comment Share on other sites More sharing options...
sbat Posted May 28, 2013 Share Posted May 28, 2013 I don't think it's that complicated honestly. The device/browser is nearly always irrelevant, all that matters is how many pixels you've got to play with. If it's enough for an 'HD' version of the game, then run in that mode, otherwise low res. That's the only rule I use. My original concern was HD devices with smaller screens (like retina iphones and some new HD Androids). But I realized that many of these devices in fact report "logical" pixels in browsers to be compatible with "pixel hardcoded" websites. For example, retina iPad reports half of its resolution in Safari container sizes it seems. So if (width > 640 pixels && height > 640 pixels) {allowPlayingMyVerticalGameInHorizontalOrientation();} is probably pretty good heuristics! Ideally I don't want to force people to rotate ipads. Quote Link to comment Share on other sites More sharing options...
rich Posted May 28, 2013 Share Posted May 28, 2013 Yeah I just go on the values reported by window. Whatever that says goes for me. Only the truly insane render at retina resolutions Or maybe if you're doing a matching pairs game. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.