I'm prototyping this kind of visual novel. I wanted that in some part of the game, there were option of picking up itens in text format like "take sword [1]","take salt [10]", "take piece of bread [3]. And when the text objct was clicked, it would subtract the quantity of the "item", and when it was 0, the text object would disappear.
I'm ok with adding the item to the inventory which is an array
but I don't know how I would quantify the itens around the game. Let me explain
For performance reasons, I've only created 4 text objetcts that could be clicked as a item. And I would like that this text object would "carry the Id" and quantity of every item in every part of the game (without me coming back to the place, and the item was back there)
I tought about using array to carry the itens quantity of each scene. But I would have to set a xy value for each item in every scene. So I was wondering if any of you guys have a better way to do this.
I'm not the best at using construct, so I'm just searching for a superficial explanation of how I would have to do this if is too complex. Don't mind me if I don't understand your answer. I know an inventory system and item system can be very complex, but I'm trying to make one as simple as possible for learning purposes.