Forum Discussion

stealthbazatlantika's avatar
7 months ago

Inventory Questions: Trading and Items with State

I have been learning about the World Inventory but I am in particular wondering about 2 features to see if they exist already.

1) is there a built in trading interface that can handle trading inventory items between players?

2) Am I correct that the World Inventory doesn't support items that themselves retain a state.  (For example, if a sword had durability, and it was 50% used up.. but one player was to trade it to another player and have it retain the 50% durability.)


I have already read this:
https://developers.meta.com/horizon-worlds/learn/documentation/typescript/local-scripting/maintaining-local-state-on-ownership-change
But that seems to be more about entity state, vs say persisted inventory state.  
I also have done some experimenting with persistent player variables, and while I could probably gin up something there.. it would make more sense if there was a built in inventory system that allows for local item state to be persisted. (and transferred during a trading operation).

Anyhow.. if anyone has any thoughts on where I should learn more, I'd be happy to hear them!

Thanks!