question

nofmxc avatar image
nofmxc asked

How can I view Shared Group Data from the web portal?

I've successfully saved and retreived Shared Group Data in my Unity game using CreateSharedGroup, AddSharedGroupMembers, UpdateSharedGroupData, and GetSharedGroupData.

Is there any way to view this data on the web portal? It would be nice for debugging and learning to not have to query by ID in the code just to view test data.

Shared Group Data
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
brendan avatar image
brendan answered

Not currently, no. Shared Group Data is something where you'll need to use a known schema for the IDs that you create, so that you can make sure to keep track of them, as there isn't an "all SGD" query (since a title could have millions of players, and each player could have several SGDs). We'll be providing more ways to work with SGDs in future updates, though.

6 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

cipriantk avatar image cipriantk commented ·

ok, is there any way to know?(from the cloud script) if a new group is created? and is there any place to store the name of this groups ?

0 Likes 0 ·
brendan avatar image brendan cipriantk commented ·

In Cloud Script, you could query the Shared Group Data's ID to see if it exists. The design intent is that titles would be using well-defined patterns for how they build the ID, making it easy to check for a given player.

Similarly, there isn't a store for all Shared Group Data IDs. The thing to understand is that SGD was designed for a fairly limited use case in which the title keeps track of SGDs created, or uses a specific naming pattern. You could potentially use a custom PlayStream event, along with PlayStream webhooks or the event archive to track on all SGDs created, but if you feel that's the model you want to use, we should probably discuss the specifics of the use case. SGD was designed to allow a small number of players to share data that isn't specific to any one player - anything that goes beyond that is likely not supported.

0 Likes 0 ·
cipriantk avatar image cipriantk commented ·

that is exactly what i want , i am making a pokemonGo like game and i need multiple persons to connect to a gym, and i wanted to use a SGD for this

0 Likes 0 ·
brendan avatar image brendan cipriantk commented ·

If you literally mean the same as the way gyms work in PokemonGo, then again, this is not going to work for you. In that design, the number of players who could be attempting to read/write from/to the SGD is not limited in any way. SGD is designed for a very limited use case, in which you are sharing a small amount of data between a small number of players. It was basically built for support of non-player-specific data storage for asynchronous games.

0 Likes 0 ·
cipriantk avatar image cipriantk commented ·

oke, then what do you recommend i use in that case ? i need a lot of players to write to the same place

0 Likes 0 ·
brendan avatar image brendan cipriantk commented ·

Systems that allow for all players to write to and read from a consistent data store are normally custom-built for the specific requirements of the feature, as a generic data store you could use for any purpose that has those capabilities would be extremely expensive to operate.

For now, I would have to recommend that you use an external data system to support this feature. You can make queries to any data system that has a Web API interface from Cloud Script via the http.request() method, so you could use AWS DynamoDB, Azure Table Storage, or a MongoDB from mLab, for example.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.