iAds-Ejecta-Pause Game when iAd banner is touched / tapped

Get help using Construct 2

Post » Sat Jun 14, 2014 9:01 pm

Hi Community,
I am trying to trigger a pause when the iAd banner is touched. Basically I cannot figure out how to trigger an event when the banner is touched (and a full page ad is displayed). I did create a touch area the size of the banner, however this would not work since the touch area (an probably everything) is below the ad banner (on webview).
My intention is to pause the game when displaying the full page banner. Currently I am only testing with Apple's test ads.
I have also enabled the "Pause on unfocus" property, but this, I believe only works on browsers.
Thank you!
B
10
S
4
G
1
Posts: 20
Reputation: 1,354

Post » Sun Jun 15, 2014 7:54 am

Im looking for this answer too!
I am sure a Construct 2 guru will give us a solution soon... :)
B
26
S
6
G
2
Posts: 85
Reputation: 2,638

Post » Sun Jun 15, 2014 10:13 am

I think the answer will come as JS or objective-c... I cannot see this being solve with any C2 setting or event, although it would be nice!
I know it can be coded:
https://developer.apple.com/library/ios ... Views.html
but then you cannot create an event!
Somewhat puzzled here!
B
10
S
4
G
1
Posts: 20
Reputation: 1,354

Post » Tue Jun 17, 2014 11:34 pm

Getting desperate! I am wondering, Using the code mentioned above, the objective-c code, is there a way to write some variable that can later be accesses from C2. I am thinking that once the ad is triggered, the code above can actually set a variable ("adActive" to true) which I could potentially read from C2 in an event as a condition??
B
10
S
4
G
1
Posts: 20
Reputation: 1,354

Post » Wed Jun 18, 2014 1:06 am

Is the game running inside Ejecta or Webkit ?
For ejecta you would have to first bridge Obj-C with Javascript: http://impactjs.com/ejecta/extending-ejecta
Then you need a bridge from Javascript to C2 objects. One solution would be creating a custom plugin:
https://www.scirra.com/manual/15/sdk
B
12
S
3
G
3
Posts: 73
Reputation: 2,647

Post » Wed Jun 18, 2014 1:31 am

Cross_,
Thank you for your answer.
I need to try this now! I am using Ejecta.
I am somewhat surprise that the functionality I describe is not part of the Ejecta/iAds. I would think it would be something everyone who had iAds would want...
I will let you know if it works.
Thank again!
B
10
S
4
G
1
Posts: 20
Reputation: 1,354


Return to How do I....?

Who is online

Users browsing this forum: Yahoo [Bot] and 11 guests