Forum Mobile Do any of the services work on android?

Everything mobile goes here.

Do any of the services work on android?

Postby WindieGames » March 25th, 2011, 5:07 am

Hello,

Sorry if I misunderstood the other posts in this forum section, but is it possible to use any of the playerIO services on an android device when deployed with AIR?
WindieGames
 
Posts: 37
Joined: January 30th, 2011, 1:36 am

Re: Do any of the services work on android?

Postby Benjaminsen » March 25th, 2011, 8:37 am

Yep, deploying with AIR you should be able to use all of the Player.IO Api's
Have more questions? Join us at #player.io on the freenode irc network. Making something cool with Player.IO? I would love to talk! My Skype handle is q-rious
User avatar
Benjaminsen
.IO
 
Posts: 808
Joined: January 12th, 2010, 11:54 am
Location: Denmark

Re: Do any of the services work on android?

Postby wbsaputra » September 9th, 2011, 11:16 am

Hi Ben, where i can get any info/document/sample code about deploying with AIR?
I really interested to develop for android.
wbsaputra
Paid Member
 
Posts: 116
Joined: June 29th, 2010, 4:38 pm

Re: Do any of the services work on android?

Postby GrafixGames » September 25th, 2011, 7:35 pm

I am having a problem in developing a game in AIR for android it shows

SecurityError: Error #3226: Cannot import a SWF file when LoaderContext.allowCodeImport is false.

while connecting to the server.
GrafixGames
 
Posts: 4
Joined: September 20th, 2011, 5:30 pm

Re: Do any of the services work on android?

Postby Chris018 » September 27th, 2011, 3:18 am

I found a fix for that problem.

In Playerio.as, you need to do a small edit.

Add this on top of playerio.as below "private static var wo:Object = { };"
Code: Select all
private static var lc:LoaderContext = new LoaderContext(false, ApplicationDomain.currentDomain);


Then look into your loadAPI() method and you will see this loader.addEventListener, what i did was let lc allow code imports which fixes the error you are having.

Code: Select all
      loader.addEventListener(Event.COMPLETE, function(e:Event):void{
            wrapper.contentLoaderInfo.addEventListener(Event.COMPLETE, emptyQueue);
            wrapper.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, handleLoadError);
            wrapper.contentLoaderInfo.addEventListener(SecurityErrorEvent.SECURITY_ERROR, handleLoadError);
            lc.allowCodeImport = true;
            wrapper.loadBytes(loader.data,lc);
            
            wo.wrapper = wrapper
         })


Hope that helps :)
Chris018
 
Posts: 10
Joined: April 6th, 2010, 5:36 pm

Re: Do any of the services work on android?

Postby GrafixGames » September 27th, 2011, 4:08 am

That code solves the problem thanks a lot
GrafixGames
 
Posts: 4
Joined: September 20th, 2011, 5:30 pm

Re: Do any of the services work on android?

Postby UnknownGuardian » November 30th, 2011, 5:41 am

I was able to connect with playerio without publishing to AIR. A mobile ready browser hosted chat worked just fine in case anyone ever wonders.
UnknownGuardian
 
Posts: 93
Joined: May 25th, 2010, 5:11 am

Re: Do any of the services work on android?

Postby Turrican » February 14th, 2012, 3:14 am

Didn't work for me. :(
No connection, no error.
:(
Turrican
 
Posts: 16
Joined: August 11th, 2011, 11:50 pm


Return to Mobile



cron