Find what objects a player has

Started by tiagocorreia, Fri 28/04/2006 16:56:32

Previous topic - Next topic

tiagocorreia

I've read the manual looking for a solution, but i didn't.

I would like to know if it is possible to know what inventory objects a character carry.
I don't find any property or function to do it.

I know I can do it programming, but I tought it, might be an easier way.

strazer

There is the Character.InventoryQuantity property you can use to check if a character has a specific inventory item:

Code: ags

  if (cGeorge.InventoryQuantity[iBall.ID] > 0) {
    Display("George has the ball.");
  }


If you tell us what you want to do exactly, we might be able to help you further.

tiagocorreia

Thank you. That was just what I needed.

I thought the InventoryQuantity would say, how many objects in the inventory the character has.

I didn't read the manula correctly. Thanks.

SMF spam blocked by CleanTalk