A brand new game
for Windows, HTML5, iPhone, Android TV and more,
That Darned Mouse!
Mouse, and of course, touchscreen.
They both took a bit of a tumble, last night.
The overscan seemed to be working, but I was only testing it with controllers, since the overscan is typically only used on Android TV versions of the games.
Yesterday, however, I chose to reuse the overscan functions on iOS.
It won't be a traditional full overscan situation, but I've opted to "bump" the screen a little, so that on iPhoneX, the game can avoid having to deal with the dreaded Bumper.
Essentially, the code continues to run as it did, but the game limits things to 32 pixels below the top of the screen, so that the very top goes unused.
Since I've been dealing with Overscan since 2013, I've gotten used to drawing elements slightly beyond the screen's limits, so that when you switch on Overscan, they don't seem to disappear suddenly once outside the screen. As such, although important elements won't be drawn up at the top of the screen, things like backgrounds and large objects will still show up there.
IMO, this is a nice middleground, which lets me pretty much ignore the stupid bumper thing, and just keep on coding!
.. But of course, that's when I noticed the co-ordinate issues.
When the overscan functions kick in, they only do-so for the graphics, not the rest of the engine.
Today, I need to spend some time working out how to mathematically figure out where the mouse/touch is relative to the position/scaling of the screen's co-ordinates. And I'm REALLY not looking forward to doing that!!