top of page
Inventory

Also an important part to a resource management game is the player inventory.

In this game the inventory handles a few things. It can be accessed wit the button tab and it displays the resources you have left, it also handles the tools selection and the items the player collected.

Let's start with the tools first. The player has two tools, the saw tool, the weld tool, and he also has his empty hand. At first this script would just allow the player to switch between the tools using the buttons 1,2,3 but that was changed after the usability testing and now the player can use the mouse scroll wheel to scroll through the tools.

Inventory1.PNG
Capture.PNG

I also had to go to the inputs and create a new input axis called Mouse ScrollWheel.

Also, the weld tool and the saw tool are not always enabled, when they are selected, they can be enabled by holding down the mouse left click button, and a script will activate their respective piece.

SawEnabler.PNG
FixerRay.PNG

Another important part of the inventory is the list of items collected. There is a list controller script that knows whether or not an item was collected and also there are a couple of scripts on each item that would allow it to be collected then added to the earlier list.

ListController.PNG
Obj1.PNG

The objects scripts are the same for Obj1-Obj2-Obj3, the list controller script holds a static list that saves wether or not a player got the objects or not.

bottom of page