MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / hasInventory

Method hasInventory

src/Savegame/BattleUnit.cpp:2652–2655  ·  view source on GitHub ↗

* Checks if this unit has an inventory. Large units and/or * terror units don't have inventories. * @return True if an inventory is available, false otherwise. */

Source from the content-addressed store, hash-verified

2650 * @return True if an inventory is available, false otherwise.
2651 */
2652bool BattleUnit::hasInventory() const
2653{
2654 return (_armor->getSize() == 1 && _rank != "STR_LIVE_TERRORIST");
2655}
2656
2657}

Callers 3

deployXCOMMethod · 0.80
addItemMethod · 0.80
initMethod · 0.80

Calls 1

getSizeMethod · 0.45

Tested by

no test coverage detected