Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

A Few Adventure Game Item Questions

Okay, I'm trying to make an Adventure game. You know, the classic "rub items to on the world until you get more items to rub on the world" genre. I need some basic help with using items.

A couple of things I'm not sure how to go about:

I need to be able to combine items with other items. (Flashlight + Batteries = Working Flashlight) I could include a blueprint item, and using that could subtract the necessary items from my inventory and replace them with the created item. (Use Working Flashlight Blueprint. -1 Flashlight, -1 Batteries, +1 Working Flashlight) but needing to find blueprints sounds like a pain, especially if I need a blueprint for even the simplest items. Another way would to just be able to use items on other items, but I don't know how I would go about doing that. (in Inventory, choose Flashlight, use Flashlight on Batteries in Inventory, Flashlight and Batteries disappear, get Working Flashlight.) Or, I could have occasional "building hot-spots", which would provide you with a list of items you can build, and then you would choose one, and if you had the materials for it, it would build it. (Go to hot-spot, choose to build Working Flashlight, -1 Flashlight, -1 Batteries, +1 Working Flashlight)

Another problem is using stuff on the world. (Hammer on glass window, breaks window) I could either have prompt the player to use an item when examining intractable objects. (Action button in front of window: It's a glass window. Use an item? Select Hammer. Hammer breaks through Window) I would need help figuring out how to bring up a list of all of the items in the player's inventory though. Alternatively, I could allow you to select items from your inventory, and have them interact with whatever the player is standing in front of, if applicable. (Stand in front of window. Select Hammer from Inventory. Select use. Break window)

So that's basically it. I'm still trying to figure out what other things I'll have problems with, so expect more questions. Thanks in advance.
 
You won't be able to use item on another item without a script. Showing a list of items will be tricky too, as you can only show 4 options at a time.

If I were you, I would make a common event that brings up the item menu. It's simple, select a script command, and enter
Code:
$scene = Scene_Item.new
You need to know what item was selected, and save its number in a variable. Go to Scene_Item, line 91, and insert the lines:
Code:
$game_variables[1] = @item.id

$scene = Scene_Map.new if @item.scope == 0
Now you can use an item with scope "none", and the item window will close after you select it.
Then you can make the map event, the Glass, check if the item used is the hammer:
items1-1.jpg
items2.jpg
 
Wow, that works great. Thanks! It took a little bit of fiddling, but it's working out great right now!

I still need help with merging items together though.

Another question. Is there anyway to turn the Menu in to just a big screen of all of the character's on hand items, plus save and quit options, and a money amount? Something along the lines of

SAVE | ITEM ITEM
QUIT | ITEM ITEM
$XXX | ITEM ITEM
Play Time:| ITEM ITEM
00:00:00 | ITEM ITEM
ITEM | ITEM ITEM
DESC.| ITEM ITEM
GOES| ITEM ITEM
HERE | ITEM ITEM

With only items and the two SAVE and QUIT options selectable? (Certain items will be use-able from the menu.

Alternatively, would it be possible to create shortcut keys to bring up Game Info (Money, Play time, etc.), Bag (Items, and Item descriptions), and Options (Save, Quit)?
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top