Welcome!

Welcome to the Official BlackBerry Support Community Forums. This is your resource to discuss support topics with your peers, and learn from each other. New to the forum? Please visit the ‘Getting Started’ link below.
inside custom component

Cascades Development

Reply
Developer
jaiaca
Posts: 90
Registered: ‎10-06-2012
My Carrier: Rogers

BBM game data for real-time or turn based game?

Hello,

 

I was wondering if anyone knows if it's possible to pass around game data via BBM?

 

So for example, a game would serialize a class or an array (or even just a json/xml file) and send it to one of your BBM friends. I know you can use invocation framework to pass an image around - http://devblog.blackberry.com/2012/11/bbm-invocation-framework/?CPID=E10C020 but what about game objects?

 

Basically, is it possible to use BBM for real-time or turn base games.

 

Thanks for any info.

Jason

Jason I. Carter
Follow me @jasonicarter
Built For BlackBerry - WordsPlus | word search has never had it so good
www.twocasualcoders.com | never casual on quality
Please use plain text.
Developer
zezke
Posts: 834
Registered: ‎12-12-2010
My Carrier: Mobile Vikings

Re: BBM game data for real-time or turn based game?

Not possible, you probably use your own server for your game data.
-------------------------------------------
Your like is much appreciated!
Samples: Park in Ghent
Feeling generous? Nominate me for BB Elite member!
Please use plain text.
Developer
Zmey
Posts: 919
Registered: ‎12-18-2012

Re: BBM game data for real-time or turn based game?

[ Edited ]

For turn-based games (VGA Planets comes to mind) you might want to consider using email instead - there's an API to create a message and attach a file to it. I'm not sure, but there might be a way to access incoming emails too.

Please use plain text.
Developer
javoid
Posts: 174
Registered: ‎11-24-2012
My Carrier: NA

Re: BBM game data for real-time or turn based game?

[ Edited ]
Not possible, you probably use your own server for your game data.

 

Then why does this page

https://developer.blackberry.com/develop/bbm_connected/development.html

 

Say the following:

 

BBM Platform APIs

Developers can use a variety of APIs to give their apps access to BBM contact lists, user profiles, while enabling users of their apps to chat and share files such as pictures, voice notes, videos and music. Available for BlackBerry 10 ( core NativeCascades and WebWorks) and BlackBerry 6 or later (Java and WebWorks).

 

  • BBM contact list, user profiles, and invitations
  • Application box in user profiles
  • Content/chat from application to BBM
  • Content/chat from application to application
  • Streaming data between applications
    • Stream data between users of your applications for real-time activities such as communication, gaming, and location tracking.

     

     

    The last line is obviously the most important one.

     

Please use plain text.
Developer
jaiaca
Posts: 90
Registered: ‎10-06-2012
My Carrier: Rogers

Re: BBM game data for real-time or turn based game?

Thanks for the link @javoid.

So now that I know it's possible, is there any actual code examples or documentation? I was looking around on that link and in github but couldn't find anything about streaming data on bbm
Jason I. Carter
Follow me @jasonicarter
Built For BlackBerry - WordsPlus | word search has never had it so good
www.twocasualcoders.com | never casual on quality
Please use plain text.
Developer
Ebscer
Posts: 730
Registered: ‎08-31-2009
My Carrier: Verizon

Re: BBM game data for real-time or turn based game?

This can not be done through BBM on BB10 at this time. The api's for channels & sessions are currently only for Java.


Read my thoughts on BlackBerry Development at news.ebscer.com
Please use plain text.
Developer
javoid
Posts: 174
Registered: ‎11-24-2012
My Carrier: NA

Re: BBM game data for real-time or turn based game?

This can not be done through BBM on BB10 at this time.

 

Where was this mentioned?  Did they say it will be integrated post-launch?

Please use plain text.
Administrator
MSohm
Posts: 12,957
Registered: ‎07-09-2008
My Carrier: Bell

Re: BBM game data for real-time or turn based game?

Correct, streaming data from one application to another using BBM APIs is available for BBM on BlackBerry OS 5-7, but is not currently available on BlackBerry 10.  It's something we're looking into post launch.

 

But you could accomplish this using the invocation framework for turn based games.  You could create an InvokeActionItem that send a file with a custom extension/mime time over a BBM chat session in your app like this:

 

InvokeActionItem {
    title: "Share Image Over BBM"
    query {
        invokeTargetId: "sys.bbm.sharehandler"
        invokeActionId: "bb.action.SHARE"
        uri: "file:///accounts/1000/shared/misc/file.tbg"
    }
}

 Your application would also need to register with the invocation framework as a handler for this extension/mime type.  Then when the user receives the file, they could click on it to open it in your game.

 

Not as seamless as streaming directly from one application to another, but it could be easier for now than buliding your own server infrastructure.

 

 

 

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Found a bug? Report it using the Issue Tracker
Please use plain text.