Ideas for a simple inventar system

This forum is currently in read-only mode.
From the Asset Store
Basic Rounded Vector Geometry Player Design with Glow for 3 player games
  • Hi,

    Currently i'am trying to build a simple and clean inventar system for my game project. The system in Mickey's Adventure tutorial is nice but a bit to complex for my needs. I don't want to read out items from external array data.

    I managed to build a few different systems, but i'am not satisfied with the results(to much events, unclean event sheet, to much time to include new items etc...)

    The goal is simple: on a key pressed a seperate inventar screen will be displayed. On this screen you see graphical represantations or just the name of the items you collected. If the button is pressed again, the screen disapears and you return to your actual game layout.

    Is there possibility to store this informations in simple text files to read them out from hash tables? I would prefer a solution without external tables and files, but i don't know if this is possible.

    Have you guys some ideas or suggestions for such s simple inventar system? I'am not asking for event sheets or codes, just for some creative input and ideas.(Of course any described event is welcome )

  • Hi,

    Here are some ideas:

    You might try an INI file:

    Also, here are several other inventory implementations listed by PixelRebirth:

    Another one (I think modified off the adventure tut):

    Keep in mind that there are pros and cons of using a simple text file to store your inventory. It is easier to work with than arrays but easier for a player to edit. If you make an "array helper" as I did the adventure tutorial then you still can store all of your stats in the text file and then convert to an array before sending out your game. It makes it a little harder for players to "cheat" and it is easier to access items in the array. Without the "array helper" though it would be a pain to populate the array.

    I think arrays are pretty intuitive overall so if you have any questions on them or don't fully understand them then feel free to shoot questions our way!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Actually, I think most of these things are just way too complex, especially for a simple inventory system.

    I've been putting together something simple that I think would suit most games. Kinda works like this:

    On Player pressed Inventory: Set gv 'inventory' to 1, else: Is gv 'inventory' to 0: Make Inventory invisible

    Is gv 'inventory' to 1: Inventory: Make visible, Selection: Make Visible, deactivate Player Controller

    Done. Now you'd only need to define events when inventory is 1 to move the selection around and if the selection is overlapping an item and you press a button, activate it, press the button again, deactivate it.

  • Thanks for the help!

    scidave:

    the links gave me a lot of ideas for the system. I wonder why i wasn't able to find this posts...

    And a txt file is completely fine for me. I think if a player wants to spoil the fun through cheating than he should do this

    I'am sure arrays are very intuitve for people with coding experience. But i have none, so arrays are the same black magic for me like python and c++

    thomasmahler:

    Right now i'am using such a simple system. It works fine, even with mouse interaction and displaying item information on mouseover. But at the moment the event code is unnecessary complex and i have to write events for every single item. In this early stage of the game there are not many of them so now this is no problem, but i guess as the project will grow this system will become more and more complicated and time consuming.

  • I'm pretty sure it should be fine for a game like Zelda, where you mainly have 20 or so items and that's it. For complex RPGs with hundreds of items... yup, it'd suck.

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