I'm building a game where players use different cards that they unlock throughout the game.
All cards exist in a catalog as well as different chests/card packs they can acquire. All this works well and I can easily access the cards a player is in possession of.
Each player has the option to create decks and fill them with the cards from their inventory. Say a player has two decks filled with cards they own. One card can be in multiple decks at once.
What would be a good approach to store and handle this data? As Entity Objects? can they then be manipulated through CloudScripts? (if a player destroys a card, it needs to be removed from the decks as well)
I hope this isn't too confusing of a post
,I'm building a game where players use different cards that they unlock through different rewards.
All cards exist in a catalog as well as different chests/card packs they can acquire. All this works well and I can easily access the cards a player is in possession of.
Each player has the option to create decks and fill them with the cards from their inventory. Say a player has two decks filled with cards they own. One card can be in multiple decks at once.
What would be a good approach to store and handle this data? As Entity Objects? can they then be manipulated through CloudScripts? (if a player destroys a card, it needs to be removed from the decks as well)
I hope this isn't too confusing of a post
Answer by Rick Chen · Sep 14, 2021 at 09:21 AM
You could make a deck by storing the reference of the card items, for example the item instance id, in Player data, Entity files or Entity Objects. They can be manipulated through CloudScripts. When the player chooses to destroy a card, your CloudScript can remove the corresponding item instance and update the decks to remove the reference. But please note that there are limits for those data storing service. You could check the limits in [Your Game Manager]->[Title Settings]->[Limits] page. Normally, for entity objects, the max Number of objects stored for the title player account entity is 5 and the Maximum size of each object stored on the title player account entity is 20 bytes.