Thank you for visiting the BlackBerry Support Community Forums.
BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)
BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.
"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."
- Kevin Michaluk, Founder, CrackBerry.com
Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.
04-18-2012 01:42 PM
I am setting up my own online high score board for one of my games.
I want to make it so the user doesn't have to sign up or create an account, just click submit high score and it will do it whether they fill out the "name" field or not. So I need to default the name to something. I was thinking the pin number you get from DeviceInfo.getDeviceId() as I was already using it to keep entries unique (but not showing it on the board) but I think I need to obfuscate it or something.
Any easy ways to do that or another identifier I could use that is safer for the user?
Solved! Go to Solution.
04-18-2012 07:15 PM
The only issue I have with using device ID, is that users will loose this when they change phones. Our experience is that users can change phone every 6 months, whether because of breakage or upgrade is hard to say. But in an effort to make this process as simple as possible, we try to license by email account because people generally take that with them. They also take their phone number.
But to be honest, using the device's PIN is probably OK, if you don't think people will be too upset that they loose their high score when they change phone.
You should not publish the PIN number in any way as that can be used for things like BBM invites and PIN mails.
04-18-2012 08:21 PM - edited 04-18-2012 08:22 PM
Thanks, I think I will use it then. It's a simple game so I think the switching device thing isn't too big of a deal.
Now I just need to figure out how to generate a default unique name. I'd make it required but I don't even want to require unique names (thinking like old school arcade game) and I feel like once I require a name be entered I need to keep the names unique.
04-18-2012 11:26 PM
I have a suggestion.
Instead of making the user input his/her name for a high score, you can programatically do it by using UserProfile.getPPID(). In this way, the BBM Social Platform generates a unique string for the person's BBID. It will be the same if the user decides to switch devices. Since his device will always be associated with a BBID, and getPPID is dependant on BBID, no changes are required and the user will always preserve his high score.
There are however two caveats.
1) UserProfile.getPPID() API is dependant on using the BBM Social Platform which is available for all devices that are using OS 5.0+.
2) UserProfile.getPPID() is application specific. For my Bold 9900, I am going to have "ABCDE1234" as my PPID for foursquare, but the PPID for NobexRadio will be "1234A5123". It will only vary from BBM instance to instance, but the value will be the same within the same application.
Let me know if you have any questions and I will be more than happy to answer them for you.