Inventory items counter

0 favourites
  • 3 posts
From the Asset Store
Inventory Aid
$4.90 USD
Create grid-based game inventories and items easily.
  • <font face="Arial, Helvetica, sans-serif">Hi! I'm finding trouble to do an inventory items counter. I already made my inventory to, when the character collide with an object, alloc into an empty slot if he doesn't have one yet. The problem is that when I create one single time the texts objects to display items quantity, I don't know how to set the value of each one in each text quantity. So I decided to create objects in every loop but the system doesn't overwtrite the quantity of the previus loop and then it ends like this:

    photobucket.com

    <img src="http://s1297.photobucket.com/user/ekeas/media/inv_zpsb1ad870e.pngl" border="0" />

    Here's my capx file:

    dropbox.com/s/ccns0uu7x24oc2r/Inventory.capx

    I would be very happy if anyone could answer my question, I belive it should be bery simple to solve. Thanks and sorry for my bad english. </font>

  • I fixed your .capx, now it is working perfectly. You were doing things in a bit complicated way, I crossed off pretty much everything you do not need. With the for each loops you were overlaying the previous text and the sprite too, although it was not visible in the game. I made so that the fruits and fruit count is created to the slots on start of layout. To count the number of fruits captured I gave the text an instance variable and it shows which fruit counter is chosen and then +1 is added to it.

    Here is the .capx:

    http://www.upload.ee/files/3448711/Inventory.capx.html

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • <font face="Arial, Helvetica, sans-serif">@trollface Thanks man. Pick all was what i was looking for.</font>

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)