[PLUGIN] appMobi Plugin Updates

Post your completed addons to share with the community

Post » Fri Aug 24, 2012 2:36 pm

Well, after the real-world test I need to tell that Cocoonjs also have bugs with audio. My narrations were not played in ful lenght, and the BG music sometimes stops. :(

So I'll go and test the AppMobi plugin and try to use Music for BG music and Sound for Narrations. Will post the results! :)
B
19
S
5
G
4
Posts: 109
Reputation: 4,195

Post » Fri Aug 24, 2012 3:17 pm

Tap, Thanks for the reply. What I am trying to do is use Construct to control external devices through various native SDKs. As a first step I would like to control a Sphero robotic ball. Using the Sphero native SDK someone has created a Phonegap plugin that I would like to access using Construct. https://github.com/orbotix/Sphero-Phonegap-SDK
How might we get this working in Appmobi using Construct?
B
6
S
2
Posts: 18
Reputation: 790

Post » Fri Aug 24, 2012 4:59 pm

@tap I've done the test modification with the new AppMobi plugin.

IfAppmobi - Play BG Music by - AppMobiPlugin/PlayAudio
IfAppmobi - Play narration by - AppMobiPlugin/PlaySound(by name)

The C2's default audio actions were placed in an Else of the IfAppMobi condition to avoid double play.

In the emulator(XDK)
---------------------
It starts to play Music, but do not plays narration, and I get tons of 404s in Chrome dev tools:
"GET http://localhost:58888/eventlight.alpinecrocostory/3.4.0/media/Story1Page2.m4a 404 (Not Found) "

Checked the file were here but with lower case characters (story1rage2.m4a), and as I renamed it to uppercase it started to play correctly.

In the Test anywhere(Android 2.3.6):
Loads the game, what is super fast (paging, story loading), but the narration not works, and the bug music not started for about 2 minutes. After that - when my phone gone to sleep - it suddenly started the bg music, but as soon as I get out from sleep, it stopped again.

I trought to use the debug from AppHub, added the debug script into the index.html, reloaded in XDK, pushed into the cloud, received an update in my phone...
The debug window now shows 1 client, but not any console log is here. :(

What can I test or how can I capture more debug info now? Do you have any documentation about the debug feature? Am I doing something wrong?Epox2012-08-24 17:40:12
B
19
S
5
G
4
Posts: 109
Reputation: 4,195

Post » Fri Aug 24, 2012 6:21 pm

Thanks for the feedback Epox. No worries about being offensive. Honest feedback is a good thing. :) I'm going to outline the answers below.

Q: I wounder if you can tell me how can I publish now, when the Ads plugin is not ready for include in my app....

A: The same way you would if they were ready. Except you won't have ad's (you wont get billed or anything)

If you are using our XDK for testing you can upload the app from there via the build for app store feature. If you do not want to use the XDK, you can just login to appHub and upload a zip file then build. We have a pdf that walks through appHub's features and shows you how to build: http://www.appmobi.com/amdocs/lib/Article-appHub.pdf?r=127 If that does not help or you still have questions just let me know.   

Q: ... do you plan to switch to support C2's standard audio actions somewhere in the future?
A: Probably not. With the way our api/build system works I do not see this happening. If you want have the same C2 game/app on the web and mobile device, you can still use the appMobi audio api. When you build for Chrome, Facebook or Web we include some JS in our appmobi.js file that makes that possible.

Q:What can I test or how can I capture more debug info now? Do you have any documentation about the debug feature?
A: The Debug in appHub uses weinre, and operates very much like the Chrome developer console.

Thanks for the further details on what you are trying to accomplish. I think I have a clear understanding of what you want to do. I will contact you via PM/email and lets one on one see if we can find a solution that accomplishes what you need.tap2012-08-24 18:34:52
B
19
S
4
G
5
Posts: 116
Reputation: 4,369

Post » Mon Aug 27, 2012 3:45 pm

Thank you @tap! I'll do some preloading tests with the narration and get back with the results.

Unfortunately I have some trouble with the AppMobiXDK Chrome plugin nowdays. On my home laptop it were about 30 minutes to start it (I used to restart Chrome, restart computer, and finally the uninstall/reinstall the plugin solved).

Now I doing the same in my day-time working machine, but with no success. The net work, uninstalled/reinstalled, restarted chrome, restarted the PC, but nothing... :(

I'll try to simplay upload the app as a zip to the build.
B
19
S
5
G
4
Posts: 109
Reputation: 4,195

Post » Mon Aug 27, 2012 7:50 pm

Epox, Sorry to hear. I will ask our XDK team about this. Can you either post or PM me your OS, Java version and version of the XDK you are using (if you can get it to load it's in the upper left.)

As funny as it may sound. I know when another dev was having issues, they were told to clear the Java cache on their system. Just google "clear java cahce" for instruction on how to clear it on your system. But I will check internally as well.
B
19
S
4
G
5
Posts: 116
Reputation: 4,369

Post » Mon Aug 27, 2012 8:24 pm

Hey ctceismc,

Sounds very cool. I would say the first step is to familiarize yourself with our plugin system. The documentation with examples is at http://www.appmobi.com/documentation/nativeplugins/index.html.

In the docs there are examples on how to call your plugins functions via javascript as well. Basically MyPlugin.dosomething();

Once you have the plugin working, creating the C2 plugin will be pretty easy as it will be like any other plugin. You will just be calling the functions you created. So to recap:

1.) Familiarize yourself with our plugin system
2.) Port the code
3.) Test to make sure you can call what you need from javascript in an index.html file.
4.) Once tested, just create a C2 plugin that calls your methods. Scirra has some very good documentation on how to write a plugin.

I hope that helped.
Let me know if you need anything else.
Good luck

B
19
S
4
G
5
Posts: 116
Reputation: 4,369

Post » Mon Aug 27, 2012 8:52 pm

Update #2: Push Notifications and SMS Support

You can now send and receive push messages from your C2 games. Use push messages to send text / rich media alerts and messages, deliver data bundles to your game, send friends a message and even trigger in game events to occur.

You can send Push messages from your XDK, apphub or even from your own server.

appMobi Push Message Documentation
http://www.appmobi.com/documentation/jsAPI/notification/index.html

Available Plugin Actions
  • Add Push User
  • Set User Attributes
  • Find User
  • Delete Push User
  • Send Push Notification
  • Send SMS
  • Show Rich Message
  • Alert
  • Beep
  • Vibrate


Available Plugin Expressions
  • Friend User Id
  • New Message Queue Count
  • Push Message Type
  • Push Message Text
  • Push Message Data


Plugin: https://www.dropbox.com/s/nxjzux44sjrrozt/appmobi.ziptap2012-08-27 20:53:12
B
19
S
4
G
5
Posts: 116
Reputation: 4,369

Post » Tue Aug 28, 2012 5:03 am

Hey, which should we use, the PlayMobi plugin or the AppMobi plugin? They seem to have somewhat overlapping functions.
B
55
S
12
G
8
Posts: 339
Reputation: 9,314

Post » Tue Aug 28, 2012 2:11 pm

Hey cow_trix, I'm not sure what you mean. While they are both offered by appMobi, the two plugins have different feature sets.

playMobi offers leaderboards, badges, cloud data,user authentication, etc... for your games. These work across platform and device. Where as the appMobi plugin allows you to access device features (audio, device info, notification, geolocation, etc..) in your C2 game via the appMobi api.

So you could use either or both depending on the requirements of your game.

I hope that helps.
B
19
S
4
G
5
Posts: 116
Reputation: 4,369

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: No registered users and 0 guests