Forum BigDB playerObject.save() problem

Discussion and help relating to the PlayerIO database solution, BigDB.

playerObject.save() problem

Postby Niallith » August 4th, 2011, 10:53 am

Hiho!
Excuse my english I'm french :p

First of all, must say playerIO is just wonderful :), it's so ezy to use and bigDB is just WOW. I was using another sockets server (wont say the name ;) ) and I don't regret switching to playerIO.

[Edited]
Ok about my problem :p
I'm having trouble with playerObject on bigDB

What I do :
I created on serverside 2 values on playerObject :
Code: Select all
player.PlayerObject.Set("suffix", "The Rookie");
player.PlayerObject.Set("prefix ", "None");
player.playerObject.Save();


THen on client side :
Code: Select all
playerObject.prefix = "titi";
playerObject.suffix = "toto";
playerObject.save();


When I look on bigDB suffix = toto BUT prefix = None.


I tried to remove the value creation serverside, when I save the object it creates the suffix value but totally ignore the prefix value, like it was not in the object when I saved it.
If I do :

Code: Select all
playerObject.prefix = "titi";
playerObject.suffix = "toto";
trace(playerOjbect.prefix)  // titi
playerObject.save();
trace(playerObject.prefix) // titi


THen I look on bigDB, suffix is created, prefix is not even there. I have no idea of what's happenning :o :shock: . It's just like my value is deleted when I send it to bigBD.
Niallith
 
Posts: 21
Joined: April 23rd, 2011, 12:31 pm

Re: playerObject.save() problem

Postby Niallith » August 4th, 2011, 3:05 pm

I did change the value .prefix by .pfix and it's now working.

Looks like the playerObject.prefix value is stuck to be not editable forever.
Maybe it's a reserverd word or something? Sounds weird though :mrgreen:
Niallith
 
Posts: 21
Joined: April 23rd, 2011, 12:31 pm

Re: playerObject.save() problem

Postby Mrx3D » August 4th, 2011, 8:35 pm

The space in the name could, give you some problems -> player.PlayerObject.Set("prefix ", "None"); ... "prefix " <--
Mrx3D
Paid Member
 
Posts: 31
Joined: February 4th, 2010, 8:32 pm

Re: playerObject.save() problem

Postby Niallith » August 4th, 2011, 8:49 pm

Aww didn't see this space :x
I'll take a look but it's probably that ;)

Thank you!
Niallith
 
Posts: 21
Joined: April 23rd, 2011, 12:31 pm

Re: playerObject.save() problem

Postby Niallith » August 5th, 2011, 2:01 pm

Hum well test with "prefix" didn't work, seems it's a reserved word or the variable is stuck ~~ dunno. I use another variable, working fine.
Niallith
 
Posts: 21
Joined: April 23rd, 2011, 12:31 pm


Return to BigDB



cron