Game Development Community

Player Inventory list

by Ryan Edmar · in Technical Issues · 03/20/2007 (12:51 am) · 0 replies

Hi all!

Got a quick question. Is there a way to find out what objects a player is carrying? To be more specific, how would I go about telling torque to give me a list of a players inventory items? I am trying to create an inventory gui that simply displays what items the player currently has in inventory. This is just a base for a more complex gui that will follow but I thought I should start with the basics. I know how to find out how many objects by using the getInventory method, but to use that I need to know what item I want. All I need is a place to start and I should be able to do the rest.

So, the question is; when the game starts the player is hold 1 crossbow and 10 crossbow ammo, how would I display that using script?

edit:

I moved this to the torque public forum due to the fact that it deals with the scripting engine mainly.

It can be found Here.