UFO: Alien Invasion
|
common object-, inventory-, container- and firemode-related functions headers. More...
Go to the source code of this file.
Data Structures | |
struct | itemEffect_s |
struct | implantDef_s |
struct | fireDef_s |
this is a fire definition for our weapons/ammo More... | |
struct | craftitem_s |
Aircraft items. More... | |
struct | objDef_s |
Defines all attributes of objects used in the inventory. More... | |
struct | invDef_s |
inventory definition for our menus More... | |
class | Item |
item instance data, with linked list capability More... | |
class | Container |
class | Inventory |
inventory definition with all its containers More... | |
struct | equipDef_s |
struct | damageType_s |
Macros | |
#define | DROPSHIP_MAX 8 |
#define | INTERCEPTOR_MAX 12 |
#define | AIRCRAFTTYPE_MAX (DROPSHIP_MAX + INTERCEPTOR_MAX) |
#define | MAX_OBJDEFS 144 |
#define | MAX_IMPLANTS 16 |
#define | MAX_MAPDEFS 256 |
#define | MAX_WEAPONS_PER_OBJDEF 4 |
#define | MAX_AMMOS_PER_OBJDEF 4 |
#define | MAX_FIREDEFS_PER_WEAPON 8 |
#define | WEAPON_BALANCE 0.5f |
#define | SKILL_BALANCE 1.0f |
#define | CID_RIGHT 0 |
#define | CID_LEFT 1 |
#define | CID_IMPLANT 2 |
#define | CID_HEADGEAR 3 |
#define | CID_BACKPACK 4 |
#define | CID_BELT 5 |
#define | CID_HOLSTER 6 |
#define | CID_ARMOUR 7 |
#define | CID_FLOOR 8 |
#define | CID_EQUIP 9 |
#define | CID_MAX 10 |
#define | SHAPE_SMALL_MAX_WIDTH 8 |
The max width and height of an item-shape. More... | |
#define | SHAPE_SMALL_MAX_HEIGHT 4 |
#define | SHAPE_BIG_MAX_HEIGHT 16 |
defines the max height of an inventory container More... | |
#define | SHAPE_BIG_MAX_WIDTH 32 |
32 bit mask More... | |
#define | MAX_DAMAGETYPES 64 |
#define | MAX_INVDEFS 16 |
#define | MAX_CONTAINERS MAX_INVDEFS |
#define | MAX_EQUIPDEFS 64 |
#define | MAX_TEAMS_PER_MISSION MAX_TEAMDEFS |
#define | foreachhand(hand) |
#define | THIS_FIREMODE(fm, HAND, fdIdx) ((fm)->getHand() == (HAND) && (fm)->getFmIdx() == (fdIdx)) |
#define | FIRESH_IsMedikit(firedef) ((firedef)->damage[0] < 0) |
Typedefs | |
typedef short | humanAircraftType_t |
typedef int32_t | containerIndex_t |
typedef int32_t | weaponFireDefIndex_t |
typedef int32_t | fireDefIndex_t |
typedef struct itemEffect_s | itemEffect_t |
typedef struct implantDef_s | implantDef_t |
typedef struct fireDef_s | fireDef_t |
this is a fire definition for our weapons/ammo More... | |
typedef struct craftitem_s | craftItem |
Aircraft items. More... | |
typedef struct objDef_s | objDef_t |
Defines all attributes of objects used in the inventory. More... | |
typedef struct invDef_s | invDef_t |
inventory definition for our menus More... | |
typedef struct equipDef_s | equipDef_t |
typedef struct damageType_s | damageType_t |
Functions | |
bool | isValidContId (const containerIndex_t id) |
void | INVSH_InitCSI (const struct csi_s *import) __attribute__((nonnull)) |
const objDef_t * | INVSH_GetItemByID (const char *id) |
Returns the item that belongs to the given id or nullptr if it wasn't found. More... | |
const objDef_t * | INVSH_GetItemByIDX (int index) |
Returns the item that belongs to the given index or nullptr if the index is invalid. More... | |
const objDef_t * | INVSH_GetItemByIDSilent (const char *id) |
Returns the item that belongs to the given id or nullptr if it wasn't found. More... | |
const implantDef_t * | INVSH_GetImplantForObjDef (const objDef_t *od) |
const implantDef_t * | INVSH_GetImplantByID (const char *id) |
Returns the implant that belongs to the given id or nullptr if it wasn't found. More... | |
const implantDef_t * | INVSH_GetImplantByIDSilent (const char *id) |
Returns the implant that belongs to the given id or nullptr if it wasn't found. More... | |
const invDef_t * | INVSH_GetInventoryDefinitionByID (const char *id) |
const fireDef_t * | FIRESH_GetFiredef (const objDef_t *obj, const weaponFireDefIndex_t weapFdsIdx, const fireDefIndex_t fdIdx) |
Get the fire definitions for a given object. More... | |
void | INVSH_MergeShapes (uint32_t *shape, const uint32_t itemShape, const int x, const int y) |
Will merge the second shape (=itemShape) into the first one (=big container shape) on the position x/y. More... | |
bool | INVSH_CheckShape (const uint32_t *shape, const int x, const int y) |
Checks the shape if there is a 1-bit on the position x/y. More... | |
int | INVSH_ShapeSize (const uint32_t shape) |
Counts the used bits in a shape (item shape). More... | |
common object-, inventory-, container- and firemode-related functions headers.
Definition in file inv_shared.h.
#define AIRCRAFTTYPE_MAX (DROPSHIP_MAX + INTERCEPTOR_MAX) |
Definition at line 34 of file inv_shared.h.
#define CID_ARMOUR 7 |
Definition at line 54 of file inv_shared.h.
Referenced by Com_ParseInventory(), InventoryInterface::EquipActorNormal(), G_InventoryDropToFloorCheck(), G_InventoryToFloor(), Inventory::getArmour(), invDef_s::isArmourDef(), TEST_F(), and UI_ContainerNodeAutoPlaceItem().
#define CID_BACKPACK 4 |
Definition at line 51 of file inv_shared.h.
Referenced by Com_ParseInventory(), InventoryInterface::EquipActorNormal(), InventoryInterface::PackAmmoAndWeapon(), TEST_F(), and UI_ContainerNodeAutoPlaceItem().
#define CID_BELT 5 |
Definition at line 52 of file inv_shared.h.
Referenced by Com_ParseInventory(), InventoryInterface::PackAmmoAndWeapon(), and UI_ContainerNodeAutoPlaceItem().
#define CID_EQUIP 9 |
Definition at line 56 of file inv_shared.h.
Referenced by Com_ParseInventory(), CP_SetEquipContainer(), uiContainerNode::draw(), G_ClientReadInventory(), GAME_ActorSelect_f(), GAME_LoadInventory(), Inventory::getEquipContainer(), Inventory::getNextCont(), invDef_s::isEquipDef(), UI_ContainerNodeAutoPlaceItem(), and UI_ContainerNodeUpdateEquipment().
#define CID_FLOOR 8 |
Definition at line 55 of file inv_shared.h.
Referenced by AI_TryToReloadWeapon(), AIL_findweapons(), CL_EntPerish(), CL_InvAdd(), Com_ParseInventory(), G_AddItemToFloor(), G_InventoryToFloor(), G_MissionThink(), G_MissionTouch(), G_MoralePanic(), G_SpawnItemOnFloor(), Inventory::getFloorContainer(), Inventory::getNextCont(), invDef_s::isFloorDef(), LE_Cleanup(), Inventory::setFloorContainer(), and TEST_F().
#define CID_HEADGEAR 3 |
Definition at line 50 of file inv_shared.h.
Referenced by CL_InvAdd(), CL_InvDel(), Com_ParseInventory(), InventoryInterface::EquipActorNormal(), G_PrepareShot(), Inventory::getHeadgear(), and UI_ContainerNodeAutoPlaceItem().
#define CID_HOLSTER 6 |
Definition at line 53 of file inv_shared.h.
Referenced by Com_ParseInventory(), Inventory::getHolsterContainer(), InventoryInterface::PackAmmoAndWeapon(), and UI_ContainerNodeAutoPlaceItem().
#define CID_IMPLANT 2 |
Definition at line 49 of file inv_shared.h.
Referenced by Com_ParseInventory(), InventoryInterface::EquipActorNormal(), G_InventoryDropToFloorCheck(), G_InventoryToFloor(), Inventory::getImplantContainer(), and UI_ContainerNodeAutoPlaceItem().
#define CID_LEFT 1 |
Definition at line 48 of file inv_shared.h.
Referenced by actorL_throwgrenade(), AI_ActorThink(), AIL_canreload(), AIL_reload(), Inventory::canHoldItem(), CL_ActorReload(), CL_InvAdd(), CL_InvDel(), Com_ParseInventory(), G_ClientCanReload(), G_EventInventoryAmmo(), G_MoralePanic(), G_PrepareShot(), Inventory::getLeftHandContainer(), HUD_DisplayActions(), HUD_ReloadLeft_f(), HUD_UpdateButtons(), invDef_s::isLeftDef(), InventoryInterface::PackAmmoAndWeapon(), and UI_ContainerNodeAutoPlaceItem().
#define CID_MAX 10 |
Definition at line 57 of file inv_shared.h.
Referenced by Inventory::_getNextCont(), actorL_throwgrenade(), CL_ActorGetContainerForReload(), CP_CleanupAircraftTeam(), CP_CleanupTeam(), G_InventoryToFloor(), GAME_LoadItem(), GAME_NetSendInventory(), Inventory::init(), INVSH_GetInventoryDefinitionByID(), and isValidContId().
#define CID_RIGHT 0 |
Definition at line 47 of file inv_shared.h.
Referenced by actorL_throwgrenade(), AI_ActorThink(), AIL_canreload(), AIL_findweapons(), AIL_reload(), Inventory::canHoldItem(), CL_ActorReload(), CL_InvAdd(), CL_InvDel(), Com_ParseInventory(), InventoryInterface::EquipActorMelee(), InventoryInterface::EquipActorRobot(), G_ActorReload(), G_ClientGetWeaponFromInventory(), G_EventInventoryAmmo(), G_MoralePanic(), G_PrepareShot(), Inventory::getRightHandContainer(), HUD_DisplayActions(), HUD_GetLeftHandWeapon(), HUD_ReloadRight_f(), HUD_UpdateActor(), HUD_UpdateButtons(), invDef_s::isRightDef(), InventoryInterface::moveInInventory(), InventoryInterface::PackAmmoAndWeapon(), and UI_ContainerNodeAutoPlaceItem().
#define DROPSHIP_MAX 8 |
Definition at line 32 of file inv_shared.h.
Referenced by Com_ParseAircraftNames().
#define FIRESH_IsMedikit | ( | firedef | ) | ((firedef)->damage[0] < 0) |
Definition at line 661 of file inv_shared.h.
Referenced by CL_GetHitProbability(), G_ClientShoot(), and G_ShootSingle().
#define foreachhand | ( | hand | ) |
Definition at line 634 of file inv_shared.h.
Referenced by HUD_CheckFiremodeReservation(), and HUD_PopupFiremodeReservation().
#define INTERCEPTOR_MAX 12 |
Definition at line 33 of file inv_shared.h.
Referenced by Com_ParseAircraftNames().
#define MAX_AMMOS_PER_OBJDEF 4 |
Definition at line 41 of file inv_shared.h.
Referenced by Com_AddObjectLinks().
#define MAX_CONTAINERS MAX_INVDEFS |
Definition at line 394 of file inv_shared.h.
Referenced by UI_ContainerNodeUpdateEquipment().
#define MAX_DAMAGETYPES 64 |
Definition at line 258 of file inv_shared.h.
Referenced by Com_ParseDamageTypes(), and Com_ValueToStr().
#define MAX_EQUIPDEFS 64 |
Definition at line 603 of file inv_shared.h.
Referenced by Com_ParseEquipment().
#define MAX_FIREDEFS_PER_WEAPON 8 |
Definition at line 42 of file inv_shared.h.
Referenced by CL_ActorGetReactionFireFireDef(), Com_ParseFireDefinition(), FIRESH_GetFiredef(), Item::getSlowestFireDef(), HUD_DisplayActions(), HUD_FireWeapon_f(), HUD_ReactionFireGetTUs(), HUD_SelectReactionFiremode_f(), HUD_UpdateActorLoad_f(), INV_UpdateActorLoad_f(), and FiremodeSettings::isSaneFiremode().
#define MAX_IMPLANTS 16 |
Definition at line 38 of file inv_shared.h.
Referenced by Com_ParseImplant().
#define MAX_INVDEFS 16 |
Definition at line 368 of file inv_shared.h.
Referenced by CL_InvAmmo(), and CL_InvReload().
#define MAX_MAPDEFS 256 |
Definition at line 39 of file inv_shared.h.
#define MAX_OBJDEFS 144 |
Definition at line 37 of file inv_shared.h.
Referenced by Com_ParseItem().
#define MAX_TEAMS_PER_MISSION MAX_TEAMDEFS |
Definition at line 618 of file inv_shared.h.
Referenced by BATTLE_SetVars(), CP_ParseAlienTeam(), and GAME_SK_SetMissionParameters().
#define MAX_WEAPONS_PER_OBJDEF 4 |
Definition at line 40 of file inv_shared.h.
Referenced by Com_ParseFireDefinition(), Com_ParseItem(), FIRESH_GetFiredef(), and RunImplant().
#define SHAPE_BIG_MAX_HEIGHT 16 |
defines the max height of an inventory container
Definition at line 188 of file inv_shared.h.
Referenced by InventoryInterface::addToInventory(), Com_ParseValue(), Com_SetValue(), Inventory::findSpace(), INV_MoveItem(), INVSH_CheckShape(), INVSH_CheckShapeCollision(), INVSH_CheckToInventory_shape(), INVSH_MergeShapes(), uiContainerNode::onDndMove(), uiContainerNode::onLoaded(), and UI_ContainerNodeDrawFreeSpace().
#define SHAPE_BIG_MAX_WIDTH 32 |
32 bit mask
Definition at line 190 of file inv_shared.h.
Referenced by InventoryInterface::addToInventory(), Com_ParseValue(), Inventory::findSpace(), INV_MoveItem(), INVSH_CheckShape(), INVSH_CheckToInventory_shape(), uiContainerNode::onDndMove(), uiContainerNode::onLoaded(), and UI_ContainerNodeDrawFreeSpace().
#define SHAPE_SMALL_MAX_HEIGHT 4 |
Definition at line 177 of file inv_shared.h.
Referenced by Com_ParseItem(), Com_ParseValue(), Com_SetValue(), Item::getFirstShapePosition(), objDef_s::getShapeRotated(), INVSH_CheckShapeCollision(), INVSH_CheckShapeSmall(), INVSH_MergeShapes(), INVSH_ShapeSetBit(), and INVSH_ShapeSize().
#define SHAPE_SMALL_MAX_WIDTH 8 |
The max width and height of an item-shape.
Definition at line 176 of file inv_shared.h.
Referenced by Com_ParseItem(), Com_ParseValue(), objDef_s::getShapeRotated(), INVSH_CheckShapeCollision(), INVSH_CheckShapeSmall(), INVSH_MergeShapes(), INVSH_ShapeSetBit(), and INVSH_ShapeSize().
#define SKILL_BALANCE 1.0f |
Definition at line 44 of file inv_shared.h.
Referenced by CL_GetHitProbability(), and G_CalcEffectiveSpread().
#define THIS_FIREMODE | ( | fm, | |
HAND, | |||
fdIdx | |||
) | ((fm)->getHand() == (HAND) && (fm)->getFmIdx() == (fdIdx)) |
Definition at line 654 of file inv_shared.h.
Referenced by HUD_DisplayFiremodeEntry().
#define WEAPON_BALANCE 0.5f |
Definition at line 43 of file inv_shared.h.
Referenced by CL_GetHitProbability(), and G_CalcEffectiveSpread().
typedef int32_t containerIndex_t |
Definition at line 46 of file inv_shared.h.
typedef struct craftitem_s craftItem |
typedef struct damageType_s damageType_t |
typedef struct equipDef_s equipDef_t |
typedef int32_t fireDefIndex_t |
Definition at line 78 of file inv_shared.h.
typedef short humanAircraftType_t |
Definition at line 28 of file inv_shared.h.
typedef struct implantDef_s implantDef_t |
typedef struct itemEffect_s itemEffect_t |
Defines all attributes of objects used in the inventory.
typedef int32_t weaponFireDefIndex_t |
Definition at line 77 of file inv_shared.h.
anonymous enum |
Return values for canHoldItem.
Enumerator | |
---|---|
INV_DOES_NOT_FIT |
Item does not fit. |
INV_FITS |
The item fits without rotation (only) |
INV_FITS_ONLY_ROTATED |
The item fits only when rotated (90! to the left) |
INV_FITS_BOTH |
The item fits either rotated or not. |
Definition at line 361 of file inv_shared.h.
enum actorHands_t |
Enumerator | |
---|---|
ACTOR_HAND_NOT_SET | |
ACTOR_HAND_RIGHT | |
ACTOR_HAND_LEFT | |
ACTOR_HAND_ENSURE_32BIT |
Definition at line 626 of file inv_shared.h.
enum aircraftItemType_t |
All different types of craft items.
Definition at line 197 of file inv_shared.h.
enum aircraftParams_t |
Aircraft parameters.
Definition at line 225 of file inv_shared.h.
enum effectStages_t |
Enumerator | |
---|---|
EFFECT_ACTIVE | |
EFFECT_INACTIVE | |
EFFECT_OVERDOSE | |
EFFECT_STRENGTHEN | |
EFFECT_MAX |
Definition at line 80 of file inv_shared.h.
enum inventory_action_t |
Possible inventory actions for moving items between containers.
Definition at line 65 of file inv_shared.h.
const fireDef_t* FIRESH_GetFiredef | ( | const objDef_t * | obj, |
const weaponFireDefIndex_t | weapFdsIdx, | ||
const fireDefIndex_t | fdIdx | ||
) |
Get the fire definitions for a given object.
[in] | obj | The object to get the firedef for |
[in] | weapFdsIdx | the weapon index in the fire definition array |
[in] | fdIdx | the fire definition index for the weapon (given by weapFdsIdx ) |
Definition at line 385 of file inv_shared.cpp.
References objDef_s::fd, objDef_s::id, MAX_FIREDEFS_PER_WEAPON, MAX_WEAPONS_PER_OBJDEF, and Sys_Error().
Referenced by CL_ActorDoShoot(), CL_ActorDoShootTime(), CL_ActorDoThrow(), CL_ActorShootHidden(), CL_ActorShootHiddenTime(), and HUD_UpdateActorFireMode().
Checks the shape if there is a 1-bit on the position x/y.
[in] | shape | Pointer to 'uint32_t shape[SHAPE_BIG_MAX_HEIGHT]' |
[in] | x | The x value in the container (1 << x in the shape bitmask) |
[in] | y | The y value in the container (SHAPE_BIG_MAX_HEIGHT is the max) |
Definition at line 414 of file inv_shared.cpp.
References Com_Printf(), f, SHAPE_BIG_MAX_HEIGHT, and SHAPE_BIG_MAX_WIDTH.
Referenced by UI_ContainerNodeDrawFreeSpace().
const implantDef_t* INVSH_GetImplantByID | ( | const char * | id | ) |
Returns the implant that belongs to the given id or nullptr
if it wasn't found.
[in] | id | the implant id in our implant definition array (csi.implants) |
Definition at line 326 of file inv_shared.cpp.
References Com_Printf(), and INVSH_GetImplantByIDSilent().
Referenced by GAME_LoadCharacter().
const implantDef_t* INVSH_GetImplantByIDSilent | ( | const char * | id | ) |
Returns the implant that belongs to the given id or nullptr
if it wasn't found.
[in] | id | the implant id in our implant definition array (csi.implants) |
Definition at line 307 of file inv_shared.cpp.
References i, implantDef_s::id, csi_s::implants, csi_s::numImplants, and Q_streq.
Referenced by INVSH_GetImplantByID().
const implantDef_t* INVSH_GetImplantForObjDef | ( | const objDef_t * | od | ) |
Definition at line 291 of file inv_shared.cpp.
References Com_Printf(), i, objDef_s::id, csi_s::implants, implantDef_s::item, and csi_s::numImplants.
Referenced by HOS_ImplantDetails_f().
const invDef_t* INVSH_GetInventoryDefinitionByID | ( | const char * | id | ) |
Searched an inventory container by a given container id
[in] | id | ID or name of the inventory container to search for |
nullptr
if not found Definition at line 340 of file inv_shared.cpp.
References CID_MAX, i, csi_s::ids, invDef_s::name, and Q_streq.
Referenced by uiBaseInventoryNode::onLoaded(), uiContainerNode::onLoaded(), and TEST_F().
const objDef_t* INVSH_GetItemByID | ( | const char * | id | ) |
Returns the item that belongs to the given id or nullptr
if it wasn't found.
[in] | id | the item id in our object definition array (csi.ods) |
Definition at line 282 of file inv_shared.cpp.
References Com_Printf(), and INVSH_GetItemByIDSilent().
Referenced by AII_AddAmmoToSlot(), AII_AddItemToSlot(), AIM_AircraftEquipAddItem_f(), AIM_AutoEquipAircraft(), AIM_CheckTechnologyIntoSlot(), AIM_CrafttypeFilter(), AIM_SelectableCraftItem(), AIM_UpdateAircraftItemList(), AIR_ParseAircraft(), AIR_Refuel(), AIRFIGHT_LoadXML(), B_AntimatterInBase(), B_LoadStorageXML(), B_UpdateAntimatterCap(), BDEF_AddItem_f(), BS_Buy_f(), BS_BuyUGV(), BS_FillMarket_f(), BS_LoadXML(), BS_SellUGV(), BS_SetAutosell_f(), BS_ShowInfo_f(), Com_AddObjectLinks(), Com_ParseEquipment(), Com_ParseImplant(), Com_ParseTeam(), COMP_ParseComponents(), CP_CleanupAircraftTeam(), CP_CleanupTeam(), GAME_AppendTeamMember(), GAME_LoadItem(), GAME_LoadTeam(), PR_LoadXML(), PR_RequirementsInfo(), RS_AssignTechLinks(), TEST_F(), TR_Add_f(), TR_CargoList(), TR_FillItems(), TR_List_f(), UP_Article(), UP_DrawAssociatedAmmo(), and UP_ResearchedLinkClick_f().
const objDef_t* INVSH_GetItemByIDSilent | ( | const char * | id | ) |
Returns the item that belongs to the given id or nullptr
if it wasn't found.
[in] | id | the item id in our object definition array (csi.ods) |
Definition at line 249 of file inv_shared.cpp.
References i, objDef_s::id, csi_s::numODs, csi_s::ods, and Q_streq.
Referenced by ItemCargo::add(), AIM_UpdateItemDescription(), B_AddAntimatter(), BDEF_SelectItem_f(), Com_ParseImplant(), Com_ParseItem(), COMP_ParseComponents(), CP_AddItemAsCollected_f(), uiItemNode::draw(), G_AddItemToFloor(), INVSH_GetItemByID(), TEST_F(), and UP_TechGetsDisplayed().
Returns the item that belongs to the given index or nullptr
if the index is invalid.
Definition at line 266 of file inv_shared.cpp.
References index, NONE, csi_s::numODs, csi_s::ods, and Sys_Error().
Referenced by AII_GetCraftitemTechsByType(), B_SaveStorageXML(), BS_InitMarket(), BS_SaveXML(), CAP_UpdateStorageCap(), CL_ActorDoShoot(), CL_ActorDoShootTime(), CL_ActorDoThrow(), CL_ActorReactionFireChange(), CL_ActorShootHidden(), CL_ActorShootHiddenTime(), CL_AddActorWeapon(), CL_InvAmmo(), CL_InvReload(), CL_NetReceiveItem(), CL_ViewPrecacheModels(), Com_AddObjectLinks(), CP_AddWeaponAmmo(), CP_CampaignRunMarket(), CP_ItemsSanityCheck(), InventoryInterface::EquipActorNormal(), G_ClientAction(), G_ClientInitActorStates(), GAME_SaveTeam(), HOS_ImplantDetails_f(), HUD_ShotReserve_f(), INV_EquipmentDefSanityCheck(), INV_UpdateObject_f(), LE_GetAnim(), InventoryInterface::PackAmmoAndWeapon(), RS_InitTree(), S_PrecacheSamples(), TEST_F(), TR_FillItems(), UI_BaseInventoryNodeDrawItems(), UI_BaseInventoryNodeGetItem(), UI_ContainerItemIteratorNext(), UI_ContainerNodeUpdateEquipment(), and UP_Article().
Will merge the second shape (=itemShape) into the first one (=big container shape) on the position x/y.
[in] | shape | The shape of the container [SHAPE_BIG_MAX_HEIGHT]' |
[in] | itemShape | The shape of the item [SHAPE_SMALL_MAX_HEIGHT] |
[in] | x | The x value in the container (1 << x in the shape bitmask) |
[in] | y | The y value in the container (SHAPE_BIG_MAX_HEIGHT is the max) |
Definition at line 402 of file inv_shared.cpp.
References i, SHAPE_BIG_MAX_HEIGHT, SHAPE_SMALL_MAX_HEIGHT, and SHAPE_SMALL_MAX_WIDTH.
Referenced by INVSH_CheckToInventory_shape(), and UI_ContainerNodeDrawFreeSpace().
int INVSH_ShapeSize | ( | const uint32_t | shape | ) |
Counts the used bits in a shape (item shape).
[in] | shape | The shape to count the bits in. |
Definition at line 435 of file inv_shared.cpp.
References i, SHAPE_SMALL_MAX_HEIGHT, and SHAPE_SMALL_MAX_WIDTH.
Referenced by LE_BiggestItem().
|
inline |
Definition at line 59 of file inv_shared.h.
References CID_MAX.
Referenced by G_ClientAction(), and G_ReadItem().