How do I use 1 object for both selection and spawn in inventory?

0 favourites
  • 2 posts
From the Asset Store
Selection frame like in RTS games, works both on mobile and desktop devices.
  • C3

    I've been at this for 2 days and I'm soooo close.

    I'm using the Persistent Inventory demo

    editor.construct.net

    In the demo they use: StoreItem for the items in the store and InventoryItem for the items seen in the player's inventory.

    The thing is, I have A LOT of images for inventory and ALL the images must be stored in BOTH StoreItem and InventoryItem for that system to work.

    I switched everything over to InventoryItems. I added an object under the Slots (player inventory) to allow drag and drop.

    And I added an object under the Store area (store stock) to disable the drag and drop

    Problem:

    1. Regardless of the category / animation / frame that is tapped in the store stock area, only the first frame from the first animation goes to the player's inventory area.

    2. I can't get the image to spawn in a free slot. They all spawn in the first slot.

    This all did work before I started messing with it, so I can't be too far off.

    This is a copy of what I have thus far.

    drive.google.com/file/d/1MUMNXewy_8jZYvrVjmkutX4dEk6hbEsq/view

    PS: Did a quick reference search and found nothing that read StoreItem - so I deleted StoreItems - no code should have been deleted since nothing was found.

    Thank you.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The addon called Empty Shell may be what you need.

    This is an object that let's you mimic the image of another sprite. Haven't explored it much myself but can imagine it would help with an inventory system like this.

    construct.net/en/make-games/addons/933/empty-shell

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