24 #include "../../cl_shared.h"
122 return cap->
max - cap->
cur;
133 while ((base =
B_GetNext(base)) !=
nullptr) {
141 switch (capacityType) {
160 cgi->Cmd_ExecuteString(
"ui_push popup_cap_overload %d \"%s\" \"%s\" %d %d",
int B_ItemInBase(const objDef_t *item, const base_t *base)
Check if the item has been collected (i.e it is in the storage) in the given base.
A building with all it's data.
void CAP_AddCurrent(base_t *base, baseCapacities_t capacity, int value)
Changes the current (used) capacity on a base.
const building_t * B_GetBuildingTemplateByType(buildingType_t type)
Returns the building template in the global building-types list for a buildingType.
#define CAP_Get(base, capacity)
Capacity macros.
capacities_t capacities[MAX_CAP]
buildingType_t
All different building types.
void RS_RemoveScientistsExceedingCapacity(base_t *base)
Remove all exceeding scientist.
Defines all attributes of objects used in the inventory.
void CP_GameTimeStop(void)
Stop game time speed.
#define CAP_GetCurrent(base, capacity)
int E_CountHired(const base_t *const base, employeeType_t type)
Counts hired employees of a given type in a given base.
A base with all it's data.
int CAP_GetFreeCapacity(const base_t *base, baseCapacities_t capacityType)
Returns the free capacity of a type.
void CAP_AddMax(base_t *base, baseCapacities_t capacity, int value)
Changes the maximal capacity on a base.
void CAP_RemoveAntimatterExceedingCapacity(base_t *base)
Remove exceeding antimatter if an antimatter tank has been destroyed.
Campaign missions headers.
base_t * B_GetNext(base_t *lastBase)
Iterates through founded bases.
const cgame_import_t * cgi
Campaign geoscape time header.
void CAP_CheckOverflow(void)
Checks capacity overflows on bases.
Header for Geoscape management.
#define CAP_GetMax(base, capacity)
baseCapacities_t
All possible capacities in base.
void CAP_UpdateStorageCap(base_t *base)
Update Storage Capacity.
Header file for aircraft stuff.
void CAP_SetCurrent(base_t *base, baseCapacities_t capacity, int value)
Sets the current (used) capacity on a base.
int B_AddAntimatter(base_t *base, int amount)
Manages antimatter (adding, removing) through Antimatter Storage Facility.
Header file for single player campaign control.
const objDef_t * INVSH_GetItemByIDX(int index)
Returns the item that belongs to the given index or nullptr if the index is invalid.
Store capacities in base.
void CAP_SetMax(base_t *base, baseCapacities_t capacity, int value)
Sets the maximal capacity on a base.
void PR_UpdateProductionCap(base_t *base, int workerChange)
Update the current capacity of Workshop.
buildingType_t B_GetBuildingTypeByCapacity(baseCapacities_t cap)
Get building type by base capacity.
bool B_ItemIsStoredInBaseStorage(const objDef_t *obj)
Check if an item is stored in storage.