question

joeypc6 avatar image
joeypc6 asked

Unity Inventory System

So in the past month i was watching every series on youtube / google on making an inventory system but none of them was good for me

i want inventory minecraftish inventory system and crafting system not like minecraft but somthing like league of legends

can you help or reqmend me a video similur to what i want

thx for reading all this

apissdksPlayer Inventory
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

It's hard to say without drilling down for the details of your requirements. While we're familiar with the systems of both the games you mention, there are inevitably going to be specifics about your game that will "tune" the implementation to your needs.

I'd recommend reading through these tutorials, to start:

https://api.playfab.com/docs/tutorials#landing-commerce

For crafting, you'll currently need to use server-side logic for that, either in a dedicated server (custom game server) or via Cloud Script. But again, it really depends upon the higher level requirements of the inventory system. The key consideration is going to be the rate of change - how often are items added, removed, or modified? From what you've said, it sounds like this will be frequent, which means the actual inventory system in PlayFab may not be right for you. If you making more than a few inventory changes per minute, per player, you'd be better off having that be data which is stored on the client (or a custom game server, if you need server-side authority) and only periodically updated on the backend (PlayFab).

9 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.

joeypc6 avatar image joeypc6 commented ·

So i want resource management game like you get specific amount based at your generators level and oxygen for example i need you to get 100 oxygen per min and use 600 per min so you need to make oxygen or you will die somthing like this but i won't save the oxygen it self on the playfab storge i will save the level of the generators and i want equip function that makes the player's power and health go by amount is that possible ?

sorry for my bad english

and thank you very much for reading my question

0 Likes 0 ·
brendan avatar image brendan ♦♦ joeypc6 commented ·

That would be a perfect example of what I was referring to, in terms of the frequency of updates. For a game such as you describe, you would be frequently updating the resource values of the player - meaning you would either need that to be managed on the client or a custom game server, which then periodically updates the backend. Have a look at this post for a more complete overview: https://community.playfab.com/questions/12094/data-heavy-games-and-rate-limits.html.

0 Likes 0 ·
joeypc6 avatar image joeypc6 commented ·

so is it possible to make the player click on save button to save or somthing like astroneer on login or logout this would can you get me a base script or something like this because i'm pretty much lost

i want inventory to hold 6 items and use them for building from over 100 item

is that possible i made the catalogue and made the catalogue convert into list so i want to convert it into inventory is it possible ?

0 Likes 0 ·
brendan avatar image brendan ♦♦ joeypc6 commented ·

The game interface is entirely up to you - we don't interfere in the display layer of the game in any way. We provide an example Cloud Script in all new titles as revision 1 - have a look at the automation tab to see this. It shows the basics of using Cloud Script, including using Server API calls.

To "convert" items, you would need to have logic that evaluates whether the player has the right items, removes them from inventory (make them stackable, and consume them), and adds the new item. There is no built-in crafting system in the service (yet - that is on our backlog, though we don't have a date for when we'll be working on that, currently).

0 Likes 0 ·
joeypc6 avatar image joeypc6 brendan ♦♦ commented ·

to be honest i can't make an inventory at all can you give me a link the teach me how to do one ?

i will use any type of inventory for now untill i learn how to improve my slef :)

0 Likes 0 ·
joeypc6 avatar image joeypc6 commented ·

how can i sync the inventory with

Photon Unity

??

0 Likes 0 ·
brendan avatar image brendan ♦♦ joeypc6 commented ·

Can you clarify the question? There is no inventory system in Photon, nor does it provide for server-authoritative logic.

0 Likes 0 ·
joeypc6 avatar image joeypc6 brendan ♦♦ commented ·

i was thinking of making the other player see whats inside the players's bag like a sword for an example it would create a prefab and load it on the secene

0 Likes 0 ·
Show more comments

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.

Error rendering WebPanel (widgets/consolidation-widget.ftl): org.hibernate.hql.internal.ast.QuerySyntaxException: AvailableConsolidation is not mapped [from AvailableConsolidation up where up.node = :node]