Please login or register.

Login with username, password and session length
Advanced search  

News:

Latest WME version: WME 1.9.1 (January 1st, 2010) - download

Author Topic: Multiple inventories - how to check whether actor has taken any items at all?  (Read 2766 times)

0 Members and 1 Guest are viewing this topic.

Kaz

  • Arberth Studios
  • Regular poster
  • ***
  • Karma: 1
  • Offline Offline
  • Posts: 228
  • The story is the game
    • View Profile
    • Info on 'Rhiannon' & 'Coven'

Hi all

I have two inventories, one for documents and one for objects, related to two actors, InvDocs and InvObjects (I know, they could just as easliy be entities). I get the whole actor.TakeItem thing but does that also extend to other methods like TotalNumItems, QueryItem and IsItemTaken or are those methods only for the Game object?

I want to switch a menu button on depending on whether there are things in each inventory. How do I check whether the number of items in InvDocs's inventory is > 0? I tried InvDocs.QueryItem and InvDocs.IsItemTaken and got 'call ignored'.

Cheers
 
Logged
\"Fans of popular horror adventures like Scratches and Barrow Hill should start bracing themselves for another haunting experience, as independent developer Arberth Studios has announced production on its debut title Rhiannon - Curse of the Four Branches.\" - AdventureGamers.com

Kaz

  • Arberth Studios
  • Regular poster
  • ***
  • Karma: 1
  • Offline Offline
  • Posts: 228
  • The story is the game
    • View Profile
    • Info on 'Rhiannon' & 'Coven'

Solved - HasItem works with entities, and a QueryItem loop will throw up a null if there's nothing in the entity's inventory. 
Logged
\"Fans of popular horror adventures like Scratches and Barrow Hill should start bracing themselves for another haunting experience, as independent developer Arberth Studios has announced production on its debut title Rhiannon - Curse of the Four Branches.\" - AdventureGamers.com
 

Page created in 0.027 seconds with 18 queries.