Forum QuickConnect Error when using SimpleUsers

Discussion and help relating to PlayerIO's QuickConnect feature, including Facebook Connect and Kongregate Connect.

Error when using SimpleUsers

Postby QiX » September 2nd, 2010, 7:41 pm

hey guys.

I'm trying to setup the most basic quickConnect registration for SimpleUsers.
I get this error:
Error: There was an error with the registration fields, see the specific errors for details.
at <anonymous>()
at <anonymous>()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/onComplete()

when i'm trying to use the method simpleRegister()
here's the code:
Code: Select all
      public function registerNewUser():void{
         trace("Registring new User");
         PlayerIO.quickConnect.simpleRegister(
            stage,
            gameID,
            username,
            pw,
            email,
            null, // captcha value, if captcha is used
            null, // any additional data you want
            function(client:Client):void{
               trace("Registered", client);   
connectToServer();   
            },
            handleError
         );
QiX
QiX
 
Posts: 34
Joined: July 22nd, 2010, 4:41 pm

Re: Error when using SimpleUsers

Postby nirza » September 3rd, 2010, 8:01 am

I think you are missing the extraData argument after the captcha nulls, you can see documentation here
http://playerio.com/documentation/refer ... ickconnect

add another null if you don't use extraData.
nirza
 
Posts: 39
Joined: April 10th, 2010, 11:50 am

Re: Error when using SimpleUsers

Postby Benjaminsen » September 3rd, 2010, 8:39 am

Registration errors returns errors of the special type PlayerIORegistrationError. This type of error has several error modes more than the basic PlayerIOError. If you make your callback handler look like below, you should be told why the registration is failing.

Code: Select all
function(e:PlayerIORegistrationError){
   trace("Got Error", e)
   trace(e.usernameError)
   trace(e.passwordError)
   trace(e.emailError)
   trace(e.captchaError)
}
Benjaminsen
.IO
 
Posts: 1444
Joined: January 12th, 2010, 11:54 am
Location: Denmark


Return to QuickConnect



cron