Tap events not working on iOS (landscape mode)

I am integrating CoronaCards into an existing iOS app.
CoronaCards versions: Solar2D 2020.3611
I followed all the instructions as mentioned here: http://docs.coronalabs.com/coronacards/ios/setup.html

And I copied over starter Ballon project, to run through the integration.
But none of the tap events are working.
I see the game screen being launched correctly, but no clicks are being registered.

Any ideas what can be missing. I see similar with other games as well, somehow no tap events work?

Are you absolutely certain that you are tapping? In Solar2D, a tap is an event where the finger lands and lifts off from the same pixel. If, for instance, you were to touch {100,100} and move your finger to {101,100} before lifting off (or while lifting off), it’d register as a touch event instead of a tap event.

Touch events are generally much easier and more reliable to handle. If that’s not the issue, then you’d need to share your code as to how you are handling tap events.

I am just using the starter Balloon project

Here is the code for main.lua

local tapCount = 0

local background = display.newImageRect( "background.png", 360, 570 )

background.x = display.contentCenterX

background.y = display.contentCenterY

local tapText = display.newText( tapCount, display.contentCenterX, 20, native.systemFont, 40 )

tapText:setFillColor( 0, 0, 0 )

local platform = display.newImageRect( "platform.png", 300, 50 )

platform.x = display.contentCenterX

platform.y = display.contentHeight-25

local balloon = display.newImageRect( "balloon.png", 112, 112 )

balloon.x = display.contentCenterX

balloon.y = display.contentCenterY

balloon.alpha = 0.8

local physics = require( "physics" )


physics.addBody( platform, "static" )

physics.addBody( balloon, "dynamic", { radius=50, bounce=0.3 } )

local function pushBalloon()

balloon:applyLinearImpulse( 0, -0.75, balloon.x, balloon.y )

tapCount = tapCount + 1

tapText.text = tapCount


balloon:addEventListener( "tap", pushBalloon )

Also same code works fine with CoronaCards on Android and normal simulator.

@XeduR I take it back, seems tap only dont work if I use the app in landscape mode ?

If I change orientation the taps get registered, but not in landscape mode.

That may be an issue with how your app and/or CoronaCards handles content area and/or changes in orientation. I’ve never used CoronaCards and I really have no idea.

Hmm, this is what I see when in landscape mode

So content area seems to be fine, I have no clue why only tap events dont work.
Using this repo to try this out. So I dont make any mistakes using my code.

Here is the exact same behavior which I am seeing :cry:

If this is still a bug, I cannot use CoronaCards for my game, as its always in landscape mode.

Any ideas on this ? I can’t move any further until I can figure out a workaround. This seems a basic setup, have Corona cards always broken for landscape games on iOS ?

I’d see about trying the fixes in that other thread, but other than that I have no idea. Is there some specific reason as to why you want to work with CoronaCards instead of Solar2D directly?

Thanks @XeduR, yes I did try to follow the fixes from other thread, but still no luck. And it seems to reproducible for any game in landscape mode.

For using CoronaCards, yes we can existing Android & iOS app, and the game would be a part of one of the sub views used for a special purpose. Hence we cant use Solar2D directly.

I am kind of desperately looking for a fix, otherwise our whole plan to use CoronaCards would just need to be dropped, at it cannot be supported in landscape mode in iOS (which just seems very weird).

I have just started getting weird behaviour with screens on iPad with projects that worked perfectly fine with projects a few months ago. I recently update Xcode and Corona to Solar and some strange things are happening.
One os this screen issue. BUT it goes back to how it should be after cleaning build on Xcode.
If I build again, it. breaks the display. I have to clean every time.
I tried changing the bundle displa name in the plist via Solar build settings and it also works only after a clean build. The next build it used Xcode’s version.
SO… it. looks like Solar2D build settings ARE NOT overwriting or being added to Xcode’s plist the second time.
This could be to do with new build by Xcode ignoring scripts, or the derived data etc.