Ifpinventory

From EDukeWiki
Revision as of 13:40, 2 December 2012 by Helixhorned (talk | contribs) (ifpinventory is really weird)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

ifpinventory <inventory item> <value> { success_branch... }

For the following <inventory item>s, takes success_branch if the current player 's amount of the inventory item being tested is not equal to <value>:

  • GET_BOOTS
  • GET_FIRSTAID
  • GET_HEATS
  • GET_HOLODUKE
  • GET_JETPACK
  • GET_SCUBA
  • GET_STEROIDS


For access cards (<inventory item> is GET_ACCESS), success_branch is taken whenever the current player has got the respective (determined by the palette of the current actor) access card.
For armor (<inventory item> is GET_SHIELD), success_branch is taken whenever the armor amount is not equal to the maximum armor amount. [Duke3D 1.5: maximum health]
Note that <value> is ignored for the two last cases.

Inventory amounts may also be tested and adjusted using the player member functions.