Touch is triggered multiple time?

Discussion and feedback on Construct 2

Post » Wed Jul 20, 2011 6:32 pm

I'm using AppMobi XDK to convert my C2 game into an iPhone4 app. Problem is, I'm using the "On touched object" and it seems like the conditions is evaluated multiple times every time I touch the screen.

Ok, I didn't really test on an iPhone4 but only in the emulator of AppMobi, I remember doing something similar with an older build and it seemed to work fine.

I also tested it using a Mouse click object to make sure the condition was correct and it works fine too.

I was wondering if any of you had already done something using the On touched object and tested it on iPhone ?

Thanks
B
6
S
2
G
1
Posts: 122
Reputation: 1,194

Post » Wed Jul 20, 2011 8:10 pm

Are you sure the AppMobi XDK doesn't try to be "helpful" and send extra touch events?
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600

Post » Wed Jul 20, 2011 8:46 pm

djordhan,

can you describe what the process has been like to 'convert' your game to appmobi? i'm curiuos, and interested.
B
52
S
17
G
15
Posts: 1,029
Reputation: 26,339

Post » Thu Jul 21, 2011 12:46 am

@Ashley - I don't think so because the actions triggered by the touch condition are only played once. (triggering object is destroyed on touch). But, the bug is only present in the XDK device emulator. Bug is not present on a real iPhone :)

@harrio - You simply have to include the script to support the AppMobi API and event listener. AppMobi even copy what you need in your clipboard when you try to launch your C2 game without the script.

Since AppMobi actually create a .js and a .html before creating the appstore compatible .apk, you can easily replace those files with your C2 export.

Djordhan2011-07-21 00:49:25
B
6
S
2
G
1
Posts: 122
Reputation: 1,194

Post » Thu Jul 21, 2011 1:43 am

djor,

is that a script you have to code yourself, or is it something already in the files that c2 exports?

i'm interested in doing an app with appmobi to submit to the app store, using c2. i guess i should just start reading on their site, instead of bugging you...lol.
B
52
S
17
G
15
Posts: 1,029
Reputation: 26,339

Post » Thu Jul 21, 2011 3:24 am

No it's a script appmobi will give you, you only paste it in your index.html generate by C2 and everything works fine. Haven't tested the whole workflow of releasing an app so it may not work perfectly :P I'll find out soon enough!

Don't hesitate to PM me if you have more questions :P
B
6
S
2
G
1
Posts: 122
Reputation: 1,194

Post » Thu Jul 21, 2011 12:58 pm

will do...thnx
B
52
S
17
G
15
Posts: 1,029
Reputation: 26,339

Post » Fri Jul 27, 2012 8:47 pm

@harrio
Read Ashley's tutorial on appmobi. It got me up and running:

How to export to appMobi with directCanvas
B
29
S
11
G
12
Posts: 281
Reputation: 11,888

Post » Sun Jul 29, 2012 12:02 pm

@kittiewan - just a heads up, this thread is a little over a year old and was posted before that tutorial existed or directCanvas was even released!
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600


Return to Construct 2 General

Who is online

Users browsing this forum: edisone, iyenal222, pablo7 and 12 guests