DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Файл FireplaceBase.c

См. исходные тексты.

Перечисления

enum  FireplaceFireState {
  NO_FIRE = 1 , START_FIRE = 2 , SMALL_FIRE = 3 , NORMAL_FIRE = 4 ,
  END_FIRE = 5 , EXTINGUISHING_FIRE = 6 , EXTINGUISHED_FIRE = 7 , REIGNITED_FIRE = 8 ,
  COUNT = 9
}
 

Функции

void FireplaceBase ()
 
void ~FireplaceBase ()
 
override void EEInit ()
 
override void EEItemAttached (EntityAI item, string slot_name)
 
override void OnItemLocationChanged (EntityAI old_owner, EntityAI new_owner)
 
override void OnAttachmentRuined (EntityAI attachment)
 
override void EEDelete (EntityAI parent)
 
override void OnStoreSave (ParamsWriteContext ctx)
 
override bool OnStoreLoad (ParamsReadContext ctx, int version)
 
override void AfterStoreLoad ()
 
void Synchronize ()
 
override void OnVariablesSynchronized ()
 
override bool IsFireplace ()
 
bool IsBaseFireplace ()
 
bool IsBarrelWithHoles ()
 
bool IsFireplaceIndoor ()
 
bool IsIndoorOven ()
 
override bool CanHaveWetness ()
 
override bool CanHaveTemperature ()
 
override bool IsSelfAdjustingTemperature ()
 
void InitializeTemperatureSources ()
 
ItemBase GetCookingEquipment ()
 
void SetCookingEquipment (ItemBase equipment)
 
void ClearCookingEquipment (ItemBase pItem)
 
void ClearCookingEquipment ()
 DEPRECATED.
 
bool DirectCookingSlotsInUse ()
 
bool SmokingSlotsInUse ()
 
void DestroyFireplace ()
 [DEPRECATED]
 
override bool IsPrepareToDelete ()
 
override void EECargoOut (EntityAI item)
 
void RefreshFireplaceVisuals ()
 
void SetBurntFirewood ()
 DEPRECATED.
 
void RefreshFireplacePhysics ()
 
void RefreshFireParticlesAndSounds (bool force_refresh)
 
void StopAllParticlesAndSounds ()
 
bool CanShowSmoke ()
 
void RefreshFireState ()
 
bool PlayParticle (out Particle particle, int particle_type, vector pos, bool worldpos=false)
 
bool StopParticle (out Particle particle)
 
void ParticleFireStartStart ()
 
void ParticleFireStartStop ()
 
void ParticleSmallFireStart ()
 
void ParticleSmallFireStop ()
 
void ParticleNormalFireStart ()
 
void ParticleNormalFireStop ()
 
void ParticleSmallSmokeStart ()
 
void ParticleSmallSmokeStop ()
 
void ParticleNormalSmokeStart ()
 
void ParticleNormalSmokeStop ()
 
void ParticleFireEndStart ()
 
void ParticleFireEndStop ()
 
void ParticleFireWindyNoIgniteStart ()
 
void ParticleSteamExtinguishingStart ()
 
void ParticleSteamExtinguishingStop ()
 
void ParticleSteamEndStart ()
 
void ParticleSteamEndStop ()
 
void ParticleWetNoIgniteStart ()
 
void ParticleWetNoIgniteStop ()
 
bool GetCeilingHeight (out float actual_height)
 
float GetAirResistanceForSmokeParticles (float actual_height)
 
vector GetFireEffectPosition ()
 
vector GetSmokeEffectPosition ()
 
void SoundFireLightStart ()
 
void SoundFireHeavyStart ()
 
void SoundFireNoFireStart ()
 
void SoundFireExtinguishedStart ()
 
void SoundFireWetNoIgniteStart ()
 
void SoundFireExtinguishingStart ()
 
void SoundFireWindyNoIgniteStart ()
 
void SoundFireStop ()
 
void AddToFireConsumables (ItemBase item)
 
float GetFireConsumableTypeEnergy (ItemBase item)
 
void RemoveFromFireConsumables (FireConsumable fire_consumable)
 
FireConsumable GetFireConsumableByItem (ItemBase item)
 
FireConsumable SetItemToConsume ()
 
FireConsumable GetItemToConsume ()
 
void SpendFireConsumable (float amount)
 
int GetKindlingCount ()
 Returns count of all kindling type items (define in 'm_KindlingTypes') attached to fireplace.
 
int GetFuelCount ()
 Returns count of all fuel type items (define in 'm_FuelTypes') attached to fireplace.
 
bool IsKindling (ItemBase item)
 Returns if item attached to fireplace is kindling.
 
bool IsFuel (ItemBase item)
 Returns if item attached to fireplace is fuel.
 
bool IsItemTypeAttached (typename item_type)
 
bool IsItemAttachedQuantity (typename item_type, float quantity)
 
bool HasLastAttachment ()
 
bool HasLastFuelKindlingAttached ()
 
bool IsBurning ()
 
void SetBurningState (bool is_burning)
 
bool HasAshes ()
 
void SetAshesState (bool has_ashes)
 
bool IsOven ()
 
bool HasStoneCircle ()
 
bool HasStones ()
 
int GetAttachedStonesCount ()
 
void SetOvenState (bool is_oven)
 
void SetStoneCircleState (bool has_stonecircle)
 
float GetFuelBurnRateMP ()
 
void SetFuelBurnRateMP (float value)
 
int GetFireState ()
 
void SetFireState (FireplaceFireState state)
 
void SetExtinguishingState ()
 
void StartFire (bool force_start=false)
 
void StartHeating ()
 
void Heating ()
 
void StopFire (FireplaceFireState fire_state=FireplaceFireState.END_FIRE)
 
void StopHeating ()
 
void StartCooling ()
 
void Cooling ()
 
void StopCooling ()
 
void CookWithEquipment ()
 
Cooking GetCookingProcess ()
 
void CookOnDirectSlot (ItemBase slot_item, float temp_equip, float temp_ext)
 
void SmokeOnSmokingSlot (ItemBase slot_item, float temp_equip, float temp_ext)
 
void BurnItemsInFireplace ()
 
void AddTemperatureToItemByFire (ItemBase item)
 
void AddTemperatureToFireplace (float amount)
 DEPRECATED.
 
void AddDamageToItemByFireEx (ItemBase item, bool can_be_ruined, bool pAttachment)
 
void AddWetnessToItem (ItemBase item, float amount)
 
void AddWetnessToFireplace (float amount)
 
void TransferHeatToNearPlayers ()
 DEPRECATED.
 
void CreateAreaDamage ()
 
void DestroyAreaDamage ()
 
bool IsFacingFireplace (PlayerBase player)
 DEPRECATED.
 
bool HasAnyKindling ()
 
static bool IsWindy ()
 
bool GetIgniteFailure ()
 
void SetIgniteFailure (bool failure)
 
static bool IsEntityWet (notnull EntityAI entity_ai)
 
bool IsWet ()
 
override bool IsOpen ()
 
bool IsCeilingHighEnoughForSmoke ()
 
static bool IsRainingAboveEntity (notnull EntityAI entity_ai)
 
bool IsRainingAbove ()
 
static bool IsEntityOnWaterSurface (notnull EntityAI entity_ai)
 
float GetSurfaceWetnessOnHeatModifier (notnull EntityAI entity)
 
bool IsOnWaterSurface ()
 
static bool IsEntityOnInteriorSurface (notnull EntityAI entity_ai)
 
bool IsOnInteriorSurface ()
 
override bool IsEmpty ()
 
bool IsCargoEmpty ()
 
bool HasCookingStand ()
 
bool IsInAnimPhase (string anim_phase)
 
bool IsSpaceFor (vector size)
 
override bool CanSwapEntities (EntityAI otherItem, InventoryLocation otherDestination, InventoryLocation destination)
 
bool CanBuildOven ()
 
bool IsSpaceForOven ()
 
bool CanBuildStoneCircle ()
 
bool IsSpaceForCircle ()
 
bool CanDismantleOven ()
 
bool CanDismantleStoneCircle ()
 
bool CanCookOnStick ()
 
bool CanExtinguishFire ()
 
FireplaceLight GetLightEntity ()
 
void SetLightEntity (FireplaceLight light)
 
override void OnPlacementComplete (Man player, vector position="0 0 0", vector orientation="0 0 0")
 
override string GetPlaceSoundset ()
 
void CalcAndSetTotalEnergy ()
 
void CalcAndSetQuantity ()
 
override void OnAttachmentQuantityChanged (ItemBase item)
 
override bool CanReleaseAttachment (EntityAI attachment)
 
void LockOvenAttachments (bool lock)
 
override bool DisassembleOnLastDetach ()
 
override void OnRPC (PlayerIdentity sender, int rpc_type, ParamsReadContext ctx)
 
override void OnDebugSpawn ()
 
override void GetDebugActions (out TSelectableActionInfoArrayEx outputList)
 
override bool OnAction (int action_id, Man player, ParamsReadContext ctx)
 
float GetTemperatureLossMP ()
 determines how fast will the fireplace loose its temperature when cooling (lower is better)
 
void SetTemperatureLossMP (float value)
 
void AddDamageToItemByFire (ItemBase item, bool can_be_ruined)
 

Переменные

enum FireplaceFireState WIND = 0
 
enum FireplaceFireState WET = 1
 
enum FireplaceFireState m_IsBurning = false
 
bool m_HasAshes = false
 
bool m_IsOven = false
 
bool m_HasStoneCircle = false
 
bool m_NoIgnite = false
 
int m_OvenAttachmentsLockState = -1
 
FireplaceFireState m_FireState = FireplaceFireState.NO_FIRE
 
FireplaceFireState m_LastFireState = FireplaceFireState.NO_FIRE
 
vector m_HalfExtents
 
float m_FuelBurnRateMP = 1.0
 
ref Cooking m_CookingProcess
 determines how fast will the fuel item burn before spending (lower is better)
 
const float PARAM_SMALL_FIRE_TEMPERATURE = 150
 
const float PARAM_NORMAL_FIRE_TEMPERATURE = 1000
 maximum fireplace temperature of a small fire (degree Celsius)
 
const float PARAM_OUTDOOR_FIRE_TEMPERATURE = 500
 maximum fireplace temperature of a normal fire (degree Celsius)
 
const float PARAM_MIN_FIRE_TEMPERATURE = 30
 maximum fireplace temperature of an outdoor fire (degree Celsius)
 
const float PARAM_TEMPERATURE_INCREASE = 10
 minimum fireplace temperature under which the fireplace is inactive (degree Celsius)
 
const float PARAM_TEMPERATURE_DECREASE = 10
 how much will temperature increase when fireplace is burning (degree Celsius per second)
 
const float PARAM_MAX_WET_TO_IGNITE = 0.2
 how much will temperature decrease when fireplace is cooling (degree Celsius per second)
 
const float PARAM_MIN_TEMP_TO_REIGNITE = 30
 maximum wetness value when the fireplace can be ignited
 
const float PARAM_IGNITE_RAIN_THRESHOLD = 0.1
 minimum fireplace temperature under which the fireplace can be reignited using air only (degree Celsius)
 
const float PARAM_BURN_WET_THRESHOLD = 0.40
 maximum rain value when the fireplace can be ignited
 
const float PARAM_WET_HEATING_DECREASE_COEF = 0.01
 maximum wetness value when the fireplace is able to burn
 
const float PARAM_WET_COOLING_DECREASE_COEF = 0.002
 value for calculating wetness loss during heating process
 
const float PARAM_FIRE_CONSUM_RATE_AMOUNT = 0.5
 value for calculating wetness loss during cooling process
 
const float PARAM_BURN_DAMAGE_COEF = 5.0
 base value of fire consumption rate (how many base energy will be spent on each update)
 
const float PARAM_FULL_HEAT_RADIUS = 2.0
 value for calculating damage on items located in fireplace cargo
 
const float PARAM_HEAT_RADIUS = 4.0
 radius in which objects are fully heated by fire
 
const float PARAM_MAX_TRANSFERED_TEMPERATURE = 20
 radius in which objects are heated by fire
 
const int MIN_STONES_TO_BUILD_CIRCLE = 8
 maximum value for temperature that will be transfered to player (environment)
 
const int MIN_STONES_TO_BUILD_OVEN = 16
 minimum amount of stones for circle
 
const int MAX_TEMPERATURE_TO_DISMANTLE_OVEN = 40
 minimum amount of stones for oven
 
const float MIN_CEILING_HEIGHT = 5
 maximum temperature for dismantling oven
 
const float FUEL_BURN_RATE_DEFAULT = 1.0
 min height of ceiling for fire to be ignited
 
const float FUEL_BURN_RATE_STONES = 0.92
 
const float FUEL_BURN_RATE_OVEN = 0.85
 
const float PARAM_COOKING_TEMP_THRESHOLD = 100
 cooking
 
const int TIMER_HEATING_UPDATE_INTERVAL = 3
 timer constants
 
const int TIMER_COOLING_UPDATE_INTERVAL = 3
 update interval duration of heating process (seconds)
 
const int DIRECT_COOKING_SLOT_COUNT = 3
 direct cooking slots
 
const int SMOKING_SLOT_COUNT = 4
 
const float SMOKING_SPEED = 1
 
const int LIFETIME_FIREPLACE_STONE_CIRCLE = 172800
 
const int LIFETIME_FIREPLACE_STONE_OVEN = 604800
 
const float IGNITE_WIND_THRESHOLD = 0.8
 
const float RAIN_EFFECT_LIMIT = 0.4
 
const float SNOWFALL_EFFECT_LIMIT = 1.3
 rain level that triggers fireplace to start soaking
 
const float RAIN_WETNESS_INCREASE = 0.02
 snowfall level that triggers fireplace to start soaking
 
const float SNOWFALL_WETNESS_INCREASE = 0.01
 value for calculating of wetness that fireplace gain when raining
 
ref Timer m_HeatingTimer
 value for calculating of wetness that fireplace gain when raining
 
ref Timer m_CoolingTimer
 
FireplaceLight m_Light
 
float m_LightDistance = 2000
 
ItemBase m_CookingEquipment
 
ItemBase m_DirectCookingSlots [DIRECT_COOKING_SLOT_COUNT]
 
ItemBase m_SmokingSlots [SMOKING_SLOT_COUNT]
 
ref FireConsumable m_ItemToConsume
 
int PARTICLE_FIRE_START = ParticleList.CAMP_FIRE_START
 
int PARTICLE_OVEN_FIRE_START = ParticleList.CAMP_STOVE_FIRE_START
 
int PARTICLE_SMALL_FIRE = ParticleList.CAMP_SMALL_FIRE
 
int PARTICLE_NORMAL_FIRE = ParticleList.CAMP_NORMAL_FIRE
 
int PARTICLE_OVEN_FIRE = ParticleList.CAMP_STOVE_FIRE
 
int PARTICLE_SMALL_SMOKE = ParticleList.CAMP_SMALL_SMOKE
 
int PARTICLE_NORMAL_SMOKE = ParticleList.CAMP_NORMAL_SMOKE
 
int PARTICLE_FIRE_END = ParticleList.CAMP_FIRE_END
 
int PARTICLE_OVEN_FIRE_END = ParticleList.CAMP_STOVE_FIRE_END
 
int PARTICLE_STEAM_END = ParticleList.CAMP_STEAM_2END
 
int PARTICLE_STEAM_EXTINGUISHING = ParticleList.CAMP_STEAM_EXTINGUISH_START
 
int PARTICLE_NO_IGNITE_WIND = ParticleList.CAMP_NO_IGNITE_WIND
 
Particle m_ParticleFireStart
 
Particle m_ParticleSmallFire
 
Particle m_ParticleNormalFire
 
Particle m_ParticleSmallSmoke
 
Particle m_ParticleNormalSmoke
 
Particle m_ParticleFireEnd
 
Particle m_ParticleSteamEnd
 
Particle m_ParticleSteamExtinguishing
 
const string SOUND_FIRE_HEAVY = "HeavyFire_SoundSet"
 
const string SOUND_FIRE_LIGHT = "LightFire_SoundSet"
 
const string SOUND_FIRE_NO_FIRE = "NoFuelFire_SoundSet"
 
const string SOUND_FIRE_EXTINGUISHING = "ExtinguishByWater_SoundSet"
 
const string SOUND_FIRE_EXTINGUISHED = "ExtinguishByWaterEnd_SoundSet"
 
EffectSound m_SoundFireLoop
 
EffectSound m_SoundFire
 
static ref map< typename, ref FireConsumableTypem_FireConsumableTypes
 
ref map< ItemBase, ref FireConsumablem_FireConsumables
 
const string MESSAGE_IGNITE_IGNIT_ITEM_DAMAGED = "You cannot start fire. Fireplace is ruined."
 
const string MESSAGE_IGNITE_NO_KINDLING = "There needs to be some kindling to start a fire."
 
const string MESSAGE_IGNITE_TOO_WET = "The fireplace is too wet to be ignited."
 
const string MESSAGE_IGNITE_RAIN = "The fire went out because of the rain."
 
const string MESSAGE_IGNITE_WIND = "The fire went out because of the wind."
 
const string MESSAGE_IGNITE_IN_WATER = "I cannot ignite the fireplace in the water."
 
const string MESSAGE_IGNITE_UNDER_LOW_ROOF = "I cannot ignite the fireplace here, the is not enough room."
 
const string MESSAGE_REIGNITE_NO_KINDLING = "There needs to be some kindling to start a fire."
 
const string MESSAGE_REIGNITE_RAIN = "Cannot reignite fireplace in rain."
 
const string MESSAGE_REIGNITE_TOO_WET = "The fireplace is too wet to be reignited."
 
const string MESSAGE_BURY_ASHES_FAILED_NOT_EMPTY = "Cannot bury ashes. There are sill items in it."
 
const string MESSAGE_BURY_ASHES_FAILED_SURFACE = "Cannot bury ashes on hard surface."
 
const string MESSAGE_BURY_ASHES_FAILED_BURNING = "Cannot bury ashes, the fireplace is still burning."
 
const string MESSAGE_BURY_ASHES_FAILED_TOO_HOT = "Cannot bury ashes, the fireplace is too hot."
 
const string MESSAGE_CANNOT_BUILD_OVEN = "Cannot build oven."
 
const string MESSAGE_CANNOT_DISMANTLE_OVEN = "Cannot dismantle oven."
 
const string ANIMATION_ASHES = "Ashes"
 
const string ANIMATION_KINDLING = "Kindling"
 
const string ANIMATION_STICKS = "Sticks"
 
const string ANIMATION_WOOD = "Wood"
 
const string ANIMATION_BURNT_WOOD = "BurntWood"
 
const string ANIMATION_STONE = "Stone"
 
const string ANIMATION_STONES = "StonesCircle"
 
const string ANIMATION_TRIPOD = "Tripod"
 
const string ANIMATION_OVEN = "Oven"
 
const string ANIMATION_INVENTORY = "Inventory"
 
const string ANIMATION_COOKWARE_HANDLE = "handleRotate"
 
const string ANIMATION_CAULDRON_HANDLE = "handle1Rotate"
 
const string MATERIAL_FIREPLACE_GLOW = "dz\\gear\\cooking\\data\\stoneground.rvmat"
 
const string MATERIAL_FIREPLACE_NOGLOW = "dz\\gear\\cooking\\data\\stonegroundnoemit.rvmat"
 
 ATTACHMENT_STICKS = WoodenStick
 
 ATTACHMENT_FIREWOOD = Firewood
 
 ATTACHMENT_RAGS = Rag
 
 ATTACHMENT_BANDAGE = BandageDressing
 
 ATTACHMENT_BOOK = ItemBook
 
 ATTACHMENT_BARK_OAK = Bark_Oak
 
 ATTACHMENT_BARK_BIRCH = Bark_Birch
 
 ATTACHMENT_PAPER = Paper
 
 ATTACHMENT_GIFTWRAP = GiftWrapPaper
 
 ATTACHMENT_PUNCHEDCARD = PunchedCard
 
 ATTACHMENT_EYEMASK_COLORBASE = EyeMask_ColorBase
 
 ATTACHMENT_TRIPOD = Tripod
 
 ATTACHMENT_COOKINGSTAND = CookingStand
 
 ATTACHMENT_STONES = Stone
 
 ATTACHMENT_COOKING_POT = Pot
 
 ATTACHMENT_FRYING_PAN = FryingPan
 
 ATTACHMENT_CAULDRON = Cauldron
 
const string OBJECT_CLUTTER_CUTTER = "ClutterCutterFireplace"
 
Object m_ClutterCutter
 
ref AreaDamageManager m_AreaDamage
 
float m_TotalEnergy
 
ref NoiseParams m_NoisePar
 
bool m_CanNoise = true
 
ref UniversalTemperatureSource m_UTSource
 
ref UniversalTemperatureSourceSettings m_UTSSettings
 
ref UniversalTemperatureSourceLambdaFireplace m_UTSLFireplace
 
const float WET_SURFACE_INCREMENT = 0.06
 
bool m_ThawnSurfaceUnderSupport
 size of wetness increment (per FP heating tick) added to overall FP wetness when ignited on wet surface
 
ref UnderObjectDecalSpawnSettings m_UnderObjectDecalSpawnSettings
 
ref UnderObjectDecalSpawnComponent m_UnderObjectDecalSpawnComponent
 
const float PARAM_ITEM_HEAT_MIN_TEMP = 40
 
const float PARAM_ITEM_HEAT_TEMP_INCREASE_COEF = 10
 DEPRECATED.
 
const float PARAM_ITEM_HEAT_TEMP_HEATING_COEF = 1.0
 value for calculating temperature increase on each heat update interval (degree Celsius)
 
const float PARAM_MAX_ITEM_HEAT_TEMP_INCREASE = 200
 multiplies temperature change on heating
 
const float PARAM_HEAT_THROUGH_AIR_COEF = 0.1
 maximum value of temperature of items in fireplace when heating (degree Celsius)
 
const float TEMPERATURE_LOSS_MP_DEFAULT = 1.0
 DEPRECATED value for calculation of heat transfered from fireplace through air to player (environment)
 
const float TEMPERATURE_LOSS_MP_STONES = 0.90
 
const float TEMPERATURE_LOSS_MP_OVEN = 0.75
 
const float PARAM_COOKING_EQUIP_MAX_TEMP = 250
 
const float PARAM_COOKING_EQUIP_TEMP_INCREASE = 10
 maximum temperature of attached cooking equipment (degree Celsius)
 
const float DIRECT_COOKING_SPEED = 1.5
 how much will temperature increase when attached on burning fireplace (degree Celsius)
 
const float PARAM_WET_INCREASE_COEF = 0.02
 
float m_TemperatureLossMP = 1.0
 value for calculating of wetness that fireplace gain when raining
 

Перечисления

◆ FireplaceFireState

Элементы перечислений
NO_FIRE 
START_FIRE 
SMALL_FIRE 
NORMAL_FIRE 
END_FIRE 
EXTINGUISHING_FIRE 
EXTINGUISHED_FIRE 
REIGNITED_FIRE 
COUNT 
2{
3 NO_FIRE = 1,
4 START_FIRE = 2,
5 SMALL_FIRE = 3,
6 NORMAL_FIRE = 4,
7 END_FIRE = 5,
11
12 COUNT = 9 //for net sync purposes
13}
@ NO_FIRE
Definition FireplaceBase.c:3
@ SMALL_FIRE
Definition FireplaceBase.c:5
@ EXTINGUISHED_FIRE
Definition FireplaceBase.c:9
@ COUNT
Definition FireplaceBase.c:12
@ EXTINGUISHING_FIRE
Definition FireplaceBase.c:8
@ REIGNITED_FIRE
Definition FireplaceBase.c:10
@ END_FIRE
Definition FireplaceBase.c:7
@ NORMAL_FIRE
Definition FireplaceBase.c:6
@ START_FIRE
Definition FireplaceBase.c:4

Функции

◆ AddDamageToItemByFire()

void AddDamageToItemByFire ( ItemBase item,
bool can_be_ruined )
protected
2801 {
2803 }
void AddDamageToItemByFireEx(ItemBase item, bool can_be_ruined, bool pAttachment)
Definition FireplaceBase.c:2205
Definition EntityAI.c:95

Перекрестные ссылки AddDamageToItemByFireEx().

◆ AddDamageToItemByFireEx()

void AddDamageToItemByFireEx ( ItemBase item,
bool can_be_ruined,
bool pAttachment )
protected

fireplace cargo only (recursive)

cargo item attachments

fuel & kindling

2206 {
2207 if (!item)
2208 return;
2209
2211 if (!pAttachment)
2212 {
2214 GameInventory itemInventory = item.GetInventory();
2215 if (itemInventory)
2216 {
2218 itemInventory.EnumerateInventory(InventoryTraversalType.INORDER, entities);
2219 foreach (EntityAI ent : entities)
2220 {
2221 if (ent != this)
2222 {
2223 ent.DecreaseHealth(PARAM_BURN_DAMAGE_COEF,!ent.IsKindOf("Grenade_Base"));
2224 }
2225 }
2226 }
2227 }
2228 else //direct attachments
2229 {
2230 float timerCoef = 1.0;
2231 if (m_HeatingTimer && m_HeatingTimer.IsRunning())
2233 else if (m_CoolingTimer && m_CoolingTimer.IsRunning())
2235
2236 switch (item.Type())
2237 {
2238 case ATTACHMENT_TRIPOD:
2244 break;
2245 }
2246
2248 if (IsFuel(item) || IsKindling(item))
2249 {
2250 if (item.GetHealthLevel() < GameConstants.STATE_BADLY_DAMAGED)
2251 item.DecreaseHealth(PARAM_BURN_DAMAGE_COEF, false);
2252 }
2253 }
2254 }
const int TIMER_HEATING_UPDATE_INTERVAL
timer constants
Definition FireplaceBase.c:73
ATTACHMENT_FRYING_PAN
Definition FireplaceBase.c:201
const int TIMER_COOLING_UPDATE_INTERVAL
update interval duration of heating process (seconds)
Definition FireplaceBase.c:74
ATTACHMENT_CAULDRON
Definition FireplaceBase.c:202
const float PARAM_BURN_DAMAGE_COEF
base value of fire consumption rate (how many base energy will be spent on each update)
Definition FireplaceBase.c:54
ref Timer m_CoolingTimer
Definition FireplaceBase.c:93
bool IsFuel(ItemBase item)
Returns if item attached to fireplace is fuel.
Definition FireplaceBase.c:1575
ATTACHMENT_COOKING_POT
Definition FireplaceBase.c:200
ATTACHMENT_TRIPOD
Definition FireplaceBase.c:197
ref Timer m_HeatingTimer
value for calculating of wetness that fireplace gain when raining
Definition FireplaceBase.c:92
ATTACHMENT_COOKINGSTAND
Definition FireplaceBase.c:198
bool IsKindling(ItemBase item)
Returns if item attached to fireplace is kindling.
Definition FireplaceBase.c:1557
Definition Building.c:6
Definition constants.c:638
script counterpart to engine's class Inventory
Definition Inventory.c:79
InventoryTraversalType
tree traversal type, for more see http://en.wikipedia.org/wiki/Tree_traversal
Definition gameplay.c:6
const float FIRE_ATTACHMENT_DAMAGE_PER_SECOND
various damage per second constants
Definition constants.c:770
const int STATE_BADLY_DAMAGED
Definition constants.c:808

Перекрестные ссылки ATTACHMENT_CAULDRON, ATTACHMENT_COOKING_POT, ATTACHMENT_COOKINGSTAND, ATTACHMENT_FRYING_PAN, ATTACHMENT_TRIPOD, GameConstants::FIRE_ATTACHMENT_DAMAGE_PER_SECOND, IsFuel(), IsKindling(), m_CoolingTimer, m_HeatingTimer, PARAM_BURN_DAMAGE_COEF, GameConstants::STATE_BADLY_DAMAGED, TIMER_COOLING_UPDATE_INTERVAL и TIMER_HEATING_UPDATE_INTERVAL.

Используется в AddDamageToItemByFire() и BurnItemsInFireplace().

◆ AddTemperatureToFireplace()

void AddTemperatureToFireplace ( float amount)
protected

DEPRECATED.

2202{};

◆ AddTemperatureToItemByFire()

void AddTemperatureToItemByFire ( ItemBase item)
protected
2182 {
2183 if (item.CanHaveTemperature())
2184 {
2185 float fireplaceTemp = GetTemperature();
2186 float itemTemp = item.GetTemperature();
2187 float heatPermCoef = item.GetHeatPermeabilityCoef();
2188 float tempCoef;
2189
2190 if (m_HeatingTimer && m_HeatingTimer.IsRunning())
2192 else if (m_CoolingTimer && m_CoolingTimer.IsRunning())
2194 else
2195 return;
2196
2198 }
2199 }
ETemperatureAccessTypes
Definition TemperatureAccessConstants.c:2
const float TEMP_COEF_FIREPLACE_HEATING
Definition constants.c:903
const float TEMP_COEF_FIREPLACE_COOLING
Definition constants.c:902

Перекрестные ссылки m_CoolingTimer, m_HeatingTimer, GameConstants::TEMP_COEF_FIREPLACE_COOLING, GameConstants::TEMP_COEF_FIREPLACE_HEATING и TIMER_COOLING_UPDATE_INTERVAL.

Используется в BurnItemsInFireplace().

◆ AddToFireConsumables()

void AddToFireConsumables ( ItemBase item)
protected
1385 {
1388 }
void CalcAndSetQuantity()
Definition FireplaceBase.c:2601
float GetFireConsumableTypeEnergy(ItemBase item)
Definition FireplaceBase.c:1390
ref map< ItemBase, ref FireConsumable > m_FireConsumables
Definition FireplaceBase.c:143
Definition FireConsumable.c:2

Перекрестные ссылки CalcAndSetQuantity(), GetFireConsumableTypeEnergy() и m_FireConsumables.

Используется в FireplaceBase::EEItemAttached().

◆ AddWetnessToFireplace()

void AddWetnessToFireplace ( float amount)
protected
2267 {
2268 //add wetness
2269 float wetness = GetWet();
2270 wetness = wetness + amount;
2271 wetness = Math.Clamp(wetness, 0, 1); //wetness <0-1>
2272 SetWet(wetness);
2273
2274 //decrease temperature
2275 if (amount > 0)
2276 {
2277 float temperature = GetTemperature();
2278 temperature = temperature * (1 - (wetness * 0.5));
2280 // temperature via UniversalTemperatureSource
2281 m_UTSLFireplace.SetFuelCount(GetFuelCount());
2282 m_UTSLFireplace.SetCurrentTemperature(temperature);
2283 }
2284 }
const float PARAM_NORMAL_FIRE_TEMPERATURE
maximum fireplace temperature of a small fire (degree Celsius)
Definition FireplaceBase.c:42
const float PARAM_MIN_FIRE_TEMPERATURE
maximum fireplace temperature of an outdoor fire (degree Celsius)
Definition FireplaceBase.c:44
ref UniversalTemperatureSourceLambdaFireplace m_UTSLFireplace
Definition FireplaceBase.c:220
int GetFuelCount()
Returns count of all fuel type items (define in 'm_FuelTypes') attached to fireplace.
Definition FireplaceBase.c:1541
override void SetWet(float value, bool allow_client=false)
Definition ItemBase.c:8320
override float GetWet()
Definition ItemBase.c:8349
Definition EnMath.c:7
static proto float Clamp(float value, float min, float max)
Clamps 'value' to 'min' if it is lower than 'min', or to 'max' if it is higher than 'max'.

Перекрестные ссылки Math::Clamp(), GetFuelCount(), GetWet(), m_UTSLFireplace, PARAM_MIN_FIRE_TEMPERATURE, PARAM_NORMAL_FIRE_TEMPERATURE и SetWet().

Используется в Cooling() и Heating().

◆ AddWetnessToItem()

void AddWetnessToItem ( ItemBase item,
float amount )
protected
2258 {
2259 float wetness = item.GetWet();
2260 wetness = wetness + amount;
2261 wetness = Math.Clamp(wetness, 0, 1); //wetness <0-1>
2262 item.SetWet(wetness);
2263 }

Перекрестные ссылки Math::Clamp().

Используется в BurnItemsInFireplace().

◆ AfterStoreLoad()

override void AfterStoreLoad ( )
protected
479 {
480 super.AfterStoreLoad();
481
482 Synchronize();
483
484 //start fire
485 if (IsBurning())
486 {
487 if (GetGame() && GetGame().IsServer())
488 {
489 StartFire(true); //will be auto-synchronized when starting fire
490 }
491 }
492 }
bool IsBurning()
Definition FireplaceBase.c:1623
void StartFire(bool force_start=false)
Definition FireplaceBase.c:1738
void Synchronize()
Definition FireplaceBase.c:497
proto native CGame GetGame()

Перекрестные ссылки GetGame(), IsBurning(), StartFire() и Synchronize().

◆ BurnItemsInFireplace()

void BurnItemsInFireplace ( )
protected

cargo

attachments

2147 {
2149 CargoBase cargo = GetInventory().GetCargo();
2150 for (int i = 0; i < cargo.GetItemCount(); i++)
2151 {
2152 ItemBase item = ItemBase.Cast(cargo.GetItem(i));
2153
2154 //add temperature
2156
2157 //set damage
2158 AddDamageToItemByFireEx(item, false, false);
2159
2160 //remove wetness
2162 }
2163
2165 for (int j = 0; j < GetInventory().AttachmentCount(); ++j)
2166 {
2167 ItemBase attachment = ItemBase.Cast(GetInventory().GetAttachmentFromIndex(j));
2168
2169 //add temperature
2171
2172 //set damage
2173 AddDamageToItemByFireEx(attachment, false, true);
2174
2175 //remove wetness
2177 }
2178 }
void AddTemperatureToItemByFire(ItemBase item)
Definition FireplaceBase.c:2181
const float PARAM_WET_HEATING_DECREASE_COEF
maximum wetness value when the fireplace is able to burn
Definition FireplaceBase.c:51
void AddWetnessToItem(ItemBase item, float amount)
Definition FireplaceBase.c:2257
represents base for cargo storage for entities
Definition Cargo.c:7
Definition InventoryItem.c:731

Перекрестные ссылки AddDamageToItemByFireEx(), AddTemperatureToItemByFire(), AddWetnessToItem() и PARAM_WET_HEATING_DECREASE_COEF.

Используется в Cooling() и Heating().

◆ CalcAndSetQuantity()

void CalcAndSetQuantity ( )
protected
2602 {
2603 if (GetGame() && GetGame().IsServer())
2604 {
2605 float remainingEnergy;
2606
2608 {
2609 float quantity = fireConsumable.GetItem().GetQuantity();
2610 if (quantity > 0)
2611 {
2612 remainingEnergy += ((quantity - 1) * fireConsumable.GetEnergy()) + fireConsumable.GetRemainingEnergy();
2613 //Print(fireConsumable.GetItem().GetType() + " remaining energy = " + (((quantity - 1) * fire_consumable.GetEnergy()) + fire_consumable.GetRemainingEnergy()).ToString());
2614 }
2615 else
2616 {
2617 remainingEnergy += fireConsumable.GetRemainingEnergy();
2618 //Print(fireConsumable.GetItem().GetType() + " remaining energy = " + (fireConsumable.GetRemainingEnergy().ToString()));
2619 }
2620 }
2621
2623 }
2624 }
float m_TotalEnergy
Definition FireplaceBase.c:211
override bool SetQuantity(float value, bool destroy_config=true, bool destroy_forced=false, bool allow_client=false, bool clamp_to_stack_max=true)
Set item quantity[related to varQuantity... config entry], destroy_config = true > if the quantity re...
Definition ItemBase.c:7981
override int GetQuantityMax()
Definition ItemBase.c:8081

Перекрестные ссылки GetGame(), GetQuantityMax(), m_FireConsumables, m_TotalEnergy и SetQuantity().

Используется в AddToFireConsumables(), CAContinuousEmpty::Cancel(), CAContinuousEmptyMagazine::Cancel(), CAContinuousFill::Cancel(), CAContinuousFillBrakes::Cancel(), CAContinuousFillCoolant::Cancel(), CAContinuousFillFuel::Cancel(), CAContinuousFillOil::Cancel(), CAContinuousQuantity::Cancel(), CAContinuousQuantityLiquidTransfer::Cancel(), CAContinuousTransferQuantity::Cancel(), CAContinuousDisinfectPlant::Execute(), CAContinuousEmpty::Execute(), CAContinuousEmptyMagazine::Execute(), CAContinuousFertilizeGardenSlot::Execute(), CAContinuousFill::Execute(), CAContinuousFillBrakes::Execute(), CAContinuousFillCoolant::Execute(), CAContinuousFillFuel::Execute(), CAContinuousFillOil::Execute(), CAContinuousFillPowerGenerator::Execute(), CAContinuousQuantity::Execute(), CAContinuousQuantityLiquidTransfer::Execute(), CAContinuousQuantityRepeat::Execute(), CAContinuousTransferQuantity::Execute(), CAContinuousWaterPlant::Execute(), CAContinuousWaterSlot::Execute(), CASingleUseQuantity::Execute(), OnAttachmentQuantityChanged(), RemoveFromFireConsumables() и SpendFireConsumable().

◆ CalcAndSetTotalEnergy()

void CalcAndSetTotalEnergy ( )
protected
2563 {
2564 if (GetGame() && GetGame().IsServer())
2565 {
2566 m_TotalEnergy = 0;
2567
2569 {
2570 string quantityConfigPath = string.Format("CfgVehicles %1 varQuantityMax", fireConsumableType.GetItemType().ToString());
2571 string stackMaxConfigPath = string.Format("CfgSlots Slot_%1 stackMax", fireConsumableType.GetAttSlot());
2572 if (GetGame().ConfigIsExisting(quantityConfigPath))
2573 {
2574 float quantityMax = GetGame().ConfigGetFloat(quantityConfigPath);
2575 }
2576
2577 if (GetGame().ConfigIsExisting(stackMaxConfigPath))
2578 {
2579 float stackMax = GetGame().ConfigGetFloat(stackMaxConfigPath);
2580 }
2581
2582 //debug
2583 //Print(fireConsumableType.GetItemType().ToString() + " quantityMax = " + quantityMax.ToString() + " [" + (quantity_max*fire_consumable_type.GetEnergy()).ToString() + "] | stack_max = " + stack_max.ToString() + " [" + (stack_max*fire_consumable_type.GetEnergy()).ToString() + "]");
2584
2585 if (stackMax > 0)
2586 {
2587 m_TotalEnergy += stackMax * fireConsumableType.GetEnergy();
2588 }
2589 else
2590 {
2592 }
2593 }
2594
2595 //debug
2596 //Print("Total energy = " + m_TotalEnergy.ToString());
2597 }
2598 }
float quantityMax
Definition CfgPlayerSpawnDataJson.c:209
static ref map< typename, ref FireConsumableType > m_FireConsumableTypes
Definition FireplaceBase.c:142
Definition FireConsumableType.c:2

Перекрестные ссылки GetGame(), m_FireConsumableTypes, m_TotalEnergy и quantityMax.

Используется в FireplaceBase().

◆ CanBuildOven()

bool CanBuildOven ( )
protected
2481 {
2482 return !IsOven() && !IsBurning() && (GetAttachedStonesCount() >= MIN_STONES_TO_BUILD_OVEN) && !FindAttachmentBySlotName("CookingTripod") && !HasStoneCircle() && IsSpaceForOven();
2483 }
bool IsSpaceForOven()
Definition FireplaceBase.c:2485
const int MIN_STONES_TO_BUILD_OVEN
minimum amount of stones for circle
Definition FireplaceBase.c:61
bool HasStoneCircle()
Definition FireplaceBase.c:1651
int GetAttachedStonesCount()
Definition FireplaceBase.c:1663
bool IsOven()
Definition FireplaceBase.c:1647

Перекрестные ссылки GetAttachedStonesCount(), HasStoneCircle(), IsBurning(), IsOven(), IsSpaceForOven() и MIN_STONES_TO_BUILD_OVEN.

◆ CanBuildStoneCircle()

bool CanBuildStoneCircle ( )
protected
2493 {
2495 }
bool IsSpaceForCircle()
Definition FireplaceBase.c:2497
const int MIN_STONES_TO_BUILD_CIRCLE
maximum value for temperature that will be transfered to player (environment)
Definition FireplaceBase.c:60

Перекрестные ссылки GetAttachedStonesCount(), HasStoneCircle(), IsBurning(), IsOven(), IsSpaceForCircle() и MIN_STONES_TO_BUILD_CIRCLE.

◆ CanCookOnStick()

bool CanCookOnStick ( )
protected
2514 {
2515 return (GetTemperature() >= PARAM_COOKING_TEMP_THRESHOLD);
2516 }
const float PARAM_COOKING_TEMP_THRESHOLD
cooking
Definition FireplaceBase.c:71

Перекрестные ссылки PARAM_COOKING_TEMP_THRESHOLD.

◆ CanDismantleOven()

bool CanDismantleOven ( )
protected
2504 {
2505 return (IsOven() && !IsBurning() && !DirectCookingSlotsInUse() && !SmokingSlotsInUse() && GetTemperature() <= MAX_TEMPERATURE_TO_DISMANTLE_OVEN);
2506 }
const int MAX_TEMPERATURE_TO_DISMANTLE_OVEN
minimum amount of stones for oven
Definition FireplaceBase.c:62
bool SmokingSlotsInUse()
Definition FireplaceBase.c:633
bool DirectCookingSlotsInUse()
Definition FireplaceBase.c:621

Перекрестные ссылки DirectCookingSlotsInUse(), IsBurning(), IsOven(), MAX_TEMPERATURE_TO_DISMANTLE_OVEN и SmokingSlotsInUse().

◆ CanDismantleStoneCircle()

bool CanDismantleStoneCircle ( )
protected
2509 {
2510 return (HasStoneCircle() && !IsOven() && !IsBurning());
2511 }

Перекрестные ссылки HasStoneCircle(), IsBurning() и IsOven().

◆ CanExtinguishFire()

bool CanExtinguishFire ( )
protected
2520 {
2521 return IsBurning();
2522 }

Перекрестные ссылки IsBurning().

◆ CanHaveTemperature()

◆ CanHaveWetness()

override bool CanHaveWetness ( )
protected
571 {
572 return true;
573 }

◆ CanReleaseAttachment()

override bool CanReleaseAttachment ( EntityAI attachment)
protected
2634 {
2635 if (!super.CanReleaseAttachment(attachment))
2636 return false;
2637
2639 if (IsKindling(item) || IsFuel(item))
2640 {
2641 return !IsBurning();
2642 }
2643
2644 return true;
2645 }

Перекрестные ссылки IsBurning(), IsFuel() и IsKindling().

◆ CanShowSmoke()

bool CanShowSmoke ( )
protected
1051 {
1052 return true;
1053 }

◆ CanSwapEntities()

override bool CanSwapEntities ( EntityAI otherItem,
InventoryLocation otherDestination,
InventoryLocation destination )
protected
2471 {
2472 if (!otherDestination || otherDestination.GetParent() == this)
2473 {
2474 return false;
2475 }
2476 return true;
2477 }

◆ ClearCookingEquipment() [1/2]

void ClearCookingEquipment ( )
protected

DEPRECATED.

617 {
619 }
void SetCookingEquipment(ItemBase equipment)
Definition FireplaceBase.c:600

Перекрестные ссылки FireplaceBase::SetCookingEquipment().

Используется в FireplaceBase::EEItemDetached() и ItemBase::EEItemDetached().

◆ ClearCookingEquipment() [2/2]

void ClearCookingEquipment ( ItemBase pItem)
protected
606 {
608 {
609 m_CookingProcess.TerminateCookingSounds(pItem);
610 }
611
613 }
ref Cooking m_CookingProcess
determines how fast will the fuel item burn before spending (lower is better)
Definition FireplaceBase.c:38

Перекрестные ссылки m_CookingProcess и FireplaceBase::SetCookingEquipment().

◆ CookOnDirectSlot()

void CookOnDirectSlot ( ItemBase slot_item,
float temp_equip,
float temp_ext )
protected
2124 {
2125 if (m_CookingProcess == null)
2126 m_CookingProcess = new Cooking();
2127
2128 m_CookingProcess.CookWithEquipment(slot_item);
2129 }

Перекрестные ссылки m_CookingProcess.

Используется в Cooling() и Heating().

◆ CookWithEquipment()

void CookWithEquipment ( )
protected
2108 {
2109 if (m_CookingProcess == null)
2110 m_CookingProcess = new Cooking();
2111
2112 m_CookingProcess.CookWithEquipment(m_CookingEquipment);
2113 }
ItemBase m_CookingEquipment
Definition FireplaceBase.c:100

Перекрестные ссылки m_CookingEquipment и m_CookingProcess.

Используется в Cooling(), Heating() и ItemBase::OnWork().

◆ Cooling()

void Cooling ( )
protected
1971 {
1972 float wetness = GetWet();
1973 float temperature = GetTemperature();
1974 float temperatureModifier = 0;
1975
1976 if (IsOpen() && !IsOven())
1978
1979 if (!IsBurning() && temperature >= 10)
1980 {
1981 //set wetness and alter temperature modifier (which will lower temperature increase because of soaking)
1982 float rain = GetGame().GetWeather().GetRain().GetActual();
1983 float combinedWindAndSnowfall = MiscGameplayFunctions.GetCombinedSnowfallWindValue();
1984
1985 if ((rain >= RAIN_EFFECT_LIMIT || combinedWindAndSnowfall >= SNOWFALL_EFFECT_LIMIT) && !IsRoofAbove() && IsOpen() && !IsOven())
1986 {
1988 {
1991 }
1992 else
1993 {
1996 }
1997 }
1998 else //subtract wetness
1999 {
2001 }
2002
2003 //calculate already obtained wetness (e.g. extinguished by water)
2005
2006 // temperature via UniversalTemperatureSource
2007 m_UTSLFireplace.SetFuelCount(GetFuelCount());
2009 m_UTSLFireplace.SetCurrentTemperature(temperature);
2011
2012 //damage cargo items
2014
2015 //cook with equipment if temperature of equipment is still high
2017 {
2018 float cookEquipTemp = m_CookingEquipment.GetTemperature();
2019
2021 {
2022 //cook
2024 }
2025 }
2026
2028 int i;
2029
2030 // manage cooking on direct cooking slots
2032 {
2033 for (i = 0; i < DIRECT_COOKING_SLOT_COUNT; i++)
2034 {
2037 }
2038 }
2039
2040 // manage smoking slots
2041 if (SmokingSlotsInUse())
2042 {
2043 for (i = 0; i < SMOKING_SLOT_COUNT; i++)
2044 {
2045 if (m_SmokingSlots[i])
2047 }
2048 }
2049 }
2050 else
2051 {
2052 //stop cooling
2053 if (Math.AbsFloat(temperature) < 10)
2054 {
2055 StopCooling();
2056 m_UTSource.SetActive(false);
2057 }
2058 }
2059 }
override bool IsOpen()
Definition FireplaceBase.c:2364
ref UniversalTemperatureSourceSettings m_UTSSettings
Definition FireplaceBase.c:219
const int DIRECT_COOKING_SLOT_COUNT
direct cooking slots
Definition FireplaceBase.c:76
const float PARAM_TEMPERATURE_DECREASE
how much will temperature increase when fireplace is burning (degree Celsius per second)
Definition FireplaceBase.c:46
void StopCooling()
Definition FireplaceBase.c:2061
void BurnItemsInFireplace()
Definition FireplaceBase.c:2146
void CookOnDirectSlot(ItemBase slot_item, float temp_equip, float temp_ext)
Definition FireplaceBase.c:2123
void CookWithEquipment()
Definition FireplaceBase.c:2107
const float SNOWFALL_EFFECT_LIMIT
rain level that triggers fireplace to start soaking
Definition FireplaceBase.c:87
const float PARAM_WET_COOLING_DECREASE_COEF
value for calculating wetness loss during heating process
Definition FireplaceBase.c:52
const int SMOKING_SLOT_COUNT
Definition FireplaceBase.c:77
void SmokeOnSmokingSlot(ItemBase slot_item, float temp_equip, float temp_ext)
Definition FireplaceBase.c:2131
const float SNOWFALL_WETNESS_INCREASE
value for calculating of wetness that fireplace gain when raining
Definition FireplaceBase.c:89
ItemBase m_DirectCookingSlots[DIRECT_COOKING_SLOT_COUNT]
Definition FireplaceBase.c:101
ref UniversalTemperatureSource m_UTSource
Definition FireplaceBase.c:218
ItemBase m_SmokingSlots[SMOKING_SLOT_COUNT]
Definition FireplaceBase.c:102
const float RAIN_WETNESS_INCREASE
snowfall level that triggers fireplace to start soaking
Definition FireplaceBase.c:88
const float RAIN_EFFECT_LIMIT
Definition FireplaceBase.c:86
void AddWetnessToFireplace(float amount)
Definition FireplaceBase.c:2266
override void CheckForRoofLimited(float timeTresholdMS=3000)
Roof check for entity, limited by time (anti-spam solution)
Definition ItemBase.c:8707
static proto float AbsFloat(float f)
Returns absolute value.

Перекрестные ссылки Math::AbsFloat(), AddWetnessToFireplace(), BurnItemsInFireplace(), CheckForRoofLimited(), CookOnDirectSlot(), CookWithEquipment(), DIRECT_COOKING_SLOT_COUNT, DirectCookingSlotsInUse(), GetFuelCount(), GetGame(), GetWet(), IsBurning(), FireplaceBase::IsOpen(), IsOven(), m_CookingEquipment, m_DirectCookingSlots, m_SmokingSlots, m_UTSLFireplace, m_UTSource, m_UTSSettings, PARAM_COOKING_TEMP_THRESHOLD, PARAM_TEMPERATURE_DECREASE, PARAM_WET_COOLING_DECREASE_COEF, RAIN_EFFECT_LIMIT, RAIN_WETNESS_INCREASE, SmokeOnSmokingSlot(), SMOKING_SLOT_COUNT, SmokingSlotsInUse(), SNOWFALL_EFFECT_LIMIT, SNOWFALL_WETNESS_INCREASE, StopCooling(), TIMER_COOLING_UPDATE_INTERVAL и TIMER_HEATING_UPDATE_INTERVAL.

◆ CreateAreaDamage()

void CreateAreaDamage ( )
protected
2291 {
2292 //destroy area damage if some already exists
2294
2295 //create new area damage
2297 m_AreaDamage.SetDamageComponentType(AreaDamageComponentTypes.HITZONE);
2298 m_AreaDamage.SetExtents("-0.30 0 -0.30", "0.30 0.75 0.30");
2299 m_AreaDamage.SetLoopInterval(0.5);
2300 m_AreaDamage.SetDeferDuration(0.5);
2301 m_AreaDamage.SetHitZones({ "Head","Torso","LeftHand","LeftLeg","LeftFoot","RightHand","RightLeg","RightFoot" });
2302 m_AreaDamage.SetAmmoName("FireDamage");
2303 m_AreaDamage.Spawn();
2304 }
ref AreaDamageManager m_AreaDamage
Definition FireplaceBase.c:208
void DestroyAreaDamage()
Definition FireplaceBase.c:2306
Definition AreaDamageManager.c:2
const int HITZONE
Definition AreaDamageManager.c:4
Deferred version of AreaDamageLooped.
Definition AreaDamageLoopedDeferred.c:3

Перекрестные ссылки DestroyAreaDamage(), AreaDamageComponentTypes::HITZONE и m_AreaDamage.

Используется в ItemBase::UpdateAttachmentVisuals().

◆ DestroyAreaDamage()

void DestroyAreaDamage ( )
protected

◆ DestroyFireplace()

void DestroyFireplace ( )
protected

[DEPRECATED]

647 {
648 DeleteSafe();
649 }

◆ DirectCookingSlotsInUse()

bool DirectCookingSlotsInUse ( )
protected
622 {
623 for (int i = 0; i < DIRECT_COOKING_SLOT_COUNT; i++)
624 {
626 {
627 return true;
628 }
629 }
630 return false;
631 }

Перекрестные ссылки DIRECT_COOKING_SLOT_COUNT и m_DirectCookingSlots.

Используется в CanDismantleOven(), FireplaceBase::CanPutInCargo(), FireplaceBase::CanPutIntoHands(), Cooling(), Heating() и StopCooling().

◆ DisassembleOnLastDetach()

override bool DisassembleOnLastDetach ( )
protected
2681 {
2682 return true;
2683 }

◆ EECargoOut()

override void EECargoOut ( EntityAI item)
protected
657 {
658 super.EECargoOut(item);
659
660 CheckForDestroy();
661 }

◆ EEDelete()

override void EEDelete ( EntityAI parent)
protected
414 {
415 super.EEDelete(parent);
416
418
419 // cleanup particles (for cases of leaving burning fplace and going back outside of network bubble)
420 #ifndef SERVER
422 #endif
423 }
void SetFireState(FireplaceFireState state)
Definition FireplaceBase.c:1715
void StopAllParticlesAndSounds()
Definition FireplaceBase.c:1023
FireplaceFireState
Definition FireplaceBase.c:2

Перекрестные ссылки SetFireState() и StopAllParticlesAndSounds().

◆ EEInit()

override void EEInit ( )
protected
310 {
311 super.EEInit();
312
313 //refresh visual on init
315 if (m_CookingProcess == null)
317
318 if (GetGame().IsServer() || !GetGame().IsMultiplayer())
319 {
321 }
322
324 {
327 }
328 }
void RefreshFireplaceVisuals()
Definition FireplaceBase.c:667
ref UnderObjectDecalSpawnSettings m_UnderObjectDecalSpawnSettings
Definition FireplaceBase.c:227
ref UnderObjectDecalSpawnComponent m_UnderObjectDecalSpawnComponent
Definition FireplaceBase.c:228
bool m_ThawnSurfaceUnderSupport
size of wetness increment (per FP heating tick) added to overall FP wetness when ignited on wet surfa...
Definition FireplaceBase.c:226
void InitializeTemperatureSources()
Definition FireplaceBase.c:585
void UnderObjectDecalSpawnComponent(notnull UnderObjectDecalSpawnSettings pSettings, notnull Object pParent)
Definition UnderObjectDecalSpawnComponent.c:22

Перекрестные ссылки GetGame(), FireplaceBase::InitializeTemperatureSources(), m_CookingProcess, m_ThawnSurfaceUnderSupport, m_UnderObjectDecalSpawnComponent, m_UnderObjectDecalSpawnSettings, RefreshFireplaceVisuals() и UnderObjectDecalSpawnComponent().

◆ EEItemAttached()

override void EEItemAttached ( EntityAI item,
string slot_name )
protected
331 {
332 super.EEItemAttached(item, slot_name);
333
334 //cookware
335 switch (item.Type())
336 {
341 break;
342 }
343 }

Перекрестные ссылки ATTACHMENT_CAULDRON, ATTACHMENT_COOKING_POT, ATTACHMENT_FRYING_PAN и FireplaceBase::SetCookingEquipment().

◆ FireplaceBase()

void FireplaceBase ( )
protected
235 {
236 //STATIC: define kindling types
238 {
241 m_FireConsumableTypes.Insert(ATTACHMENT_BANDAGE, new FireConsumableType(ATTACHMENT_BANDAGE, 14, true, "MedicalBandage"));
249
250 //define fuel types
251 m_FireConsumableTypes.Insert(ATTACHMENT_STICKS, new FireConsumableType(ATTACHMENT_STICKS, 40, false, "WoodenStick"));
253 }
254
255 //calculate total energy
257
258 //define fuel / kindling items (fire consumables)
260
261 //default burning parameters
263
264 //synchronized variables
265 RegisterNetSyncVariableBool("m_IsBurning");
266 RegisterNetSyncVariableBool("m_HasAshes");
267 RegisterNetSyncVariableBool("m_IsOven");
268 RegisterNetSyncVariableBool("m_HasStoneCircle");
269 RegisterNetSyncVariableBool("m_RoofAbove");
270 RegisterNetSyncVariableInt("m_FireState", FireplaceFireState.NO_FIRE, FireplaceFireState.COUNT);
271 RegisterNetSyncVariableBool("m_IsSoundSynchRemote");
272 RegisterNetSyncVariableBool("m_IsPlaceSound");
273 RegisterNetSyncVariableBool("m_NoIgnite");
274
276
278
280 m_UTSSettings.m_AffectStat = true;
281 m_UTSSettings.m_ManualUpdate = true;
282 m_UTSSettings.m_TemperatureMin = 0;
287 m_UTSSettings.m_RangeMax = PARAM_HEAT_RADIUS;
288
290 m_UnderObjectDecalSpawnSettings.m_RandomizeRotation = true;
291 m_UnderObjectDecalSpawnSettings.m_PositionOffset = "0 0.05 0";
292 m_UnderObjectDecalSpawnSettings.m_ScaleMax = 1.0;
293 }
ATTACHMENT_FIREWOOD
Definition FireplaceBase.c:185
ATTACHMENT_BARK_OAK
Definition FireplaceBase.c:190
ATTACHMENT_STICKS
Definition FireplaceBase.c:184
ATTACHMENT_PUNCHEDCARD
Definition FireplaceBase.c:194
void SetFuelBurnRateMP(float value)
Definition FireplaceBase.c:1703
ATTACHMENT_EYEMASK_COLORBASE
Definition FireplaceBase.c:195
ATTACHMENT_BANDAGE
Definition FireplaceBase.c:188
ATTACHMENT_BOOK
Definition FireplaceBase.c:189
ATTACHMENT_GIFTWRAP
Definition FireplaceBase.c:193
ATTACHMENT_RAGS
Definition FireplaceBase.c:187
const float PARAM_MAX_TRANSFERED_TEMPERATURE
radius in which objects are heated by fire
Definition FireplaceBase.c:57
const float PARAM_HEAT_RADIUS
radius in which objects are fully heated by fire
Definition FireplaceBase.c:56
ATTACHMENT_PAPER
Definition FireplaceBase.c:192
const float FUEL_BURN_RATE_DEFAULT
min height of ceiling for fire to be ignited
Definition FireplaceBase.c:66
ATTACHMENT_BARK_BIRCH
Definition FireplaceBase.c:191
vector m_HalfExtents
Definition FireplaceBase.c:32
void CalcAndSetTotalEnergy()
Definition FireplaceBase.c:2562
const float PARAM_FULL_HEAT_RADIUS
value for calculating damage on items located in fireplace cargo
Definition FireplaceBase.c:55
Definition UnderObjectDecalSpawnComponent.c:2
Definition UniversalTemperatureSource.c:2
Definition EnConvert.c:106
static const vector Zero
Definition EnConvert.c:110
static const float ITEM_TEMPERATURE_NEUTRAL_ZONE_MIDDLE
Definition constants.c:777

Перекрестные ссылки ATTACHMENT_BANDAGE, ATTACHMENT_BARK_BIRCH, ATTACHMENT_BARK_OAK, ATTACHMENT_BOOK, ATTACHMENT_EYEMASK_COLORBASE, ATTACHMENT_FIREWOOD, ATTACHMENT_GIFTWRAP, ATTACHMENT_PAPER, ATTACHMENT_PUNCHEDCARD, ATTACHMENT_RAGS, ATTACHMENT_STICKS, CalcAndSetTotalEnergy(), FUEL_BURN_RATE_DEFAULT, GameConstants::ITEM_TEMPERATURE_NEUTRAL_ZONE_MIDDLE, m_FireConsumables, m_FireConsumableTypes, m_HalfExtents, m_UnderObjectDecalSpawnSettings, m_UTSSettings, PARAM_FULL_HEAT_RADIUS, PARAM_HEAT_RADIUS, PARAM_MAX_TRANSFERED_TEMPERATURE, PARAM_NORMAL_FIRE_TEMPERATURE, SetFuelBurnRateMP() и vector::Zero.

◆ GetAirResistanceForSmokeParticles()

float GetAirResistanceForSmokeParticles ( float actual_height)
protected
1312 {
1313 float air_res;
1315
1316 air_res = (6 - actual_height) * 0.33;
1317 air_res = Math.Clamp(air_res, 0, 2);
1318
1319 return air_res;
1320 }

Перекрестные ссылки Math::Clamp().

Используется в ParticleNormalSmokeStart() и ParticleSmallSmokeStart().

◆ GetAttachedStonesCount()

int GetAttachedStonesCount ( )
protected
1664 {
1665 if (HasStones())
1666 {
1667 return GetAttachmentByType(ATTACHMENT_STONES).GetQuantity();
1668 }
1669
1670 return 0;
1671 }
bool HasStones()
Definition FireplaceBase.c:1656
ATTACHMENT_STONES
Definition FireplaceBase.c:199

Перекрестные ссылки ATTACHMENT_STONES и HasStones().

Используется в CanBuildOven() и CanBuildStoneCircle().

◆ GetCeilingHeight()

bool GetCeilingHeight ( out float actual_height)
protected
1296 {
1297 vector from = this.GetPosition();
1298 vector to = this.GetPosition();
1299 from[1] = from[1] + 1.0;
1300 to[1] = to[1] + MIN_CEILING_HEIGHT;
1303 int contactComponent;
1304
1307
1308 return hit;
1309 }
const float MIN_CEILING_HEIGHT
maximum temperature for dismantling oven
Definition FireplaceBase.c:63
class JsonUndergroundAreaTriggerData GetPosition
Definition UndergroundAreaLoader.c:9
Definition DayZPhysics.c:124
static proto bool RaycastRV(vector begPos, vector endPos, out vector contactPos, out vector contactDir, out int contactComponent, set< Object > results=NULL, Object with=NULL, Object ignore=NULL, bool sorted=false, bool ground_only=false, int iType=ObjIntersectView, float radius=0.0, CollisionFlags flags=CollisionFlags.NEARESTCONTACT)
Raycasts world by given parameters.
static proto native float Distance(vector v1, vector v2)
Returns the distance between tips of two 3D vectors.

Перекрестные ссылки vector::Distance(), GetPosition, MIN_CEILING_HEIGHT и DayZPhysics::RaycastRV().

Используется в ParticleNormalSmokeStart() и ParticleSmallSmokeStart().

◆ GetCookingEquipment()

ItemBase GetCookingEquipment ( )
protected

◆ GetCookingProcess()

Cooking GetCookingProcess ( )
protected
2116 {
2117 if (m_CookingProcess == null)
2118 m_CookingProcess = new Cooking();
2119
2120 return m_CookingProcess;
2121 }

Перекрестные ссылки m_CookingProcess.

◆ GetDebugActions()

override void GetDebugActions ( out TSelectableActionInfoArrayEx outputList)
protected
2744 {
2745 outputList.Insert(new TSelectableActionInfoWithColor(SAT_DEBUG_ACTION, EActions.ACTIVATE_ENTITY, "Ignite", FadeColors.LIGHT_GREY));
2746 outputList.Insert(new TSelectableActionInfoWithColor(SAT_DEBUG_ACTION, EActions.DEACTIVATE_ENTITY, "Extinguish", FadeColors.LIGHT_GREY));
2747 outputList.Insert(new TSelectableActionInfoWithColor(SAT_DEBUG_ACTION, EActions.SEPARATOR, "___________________________", FadeColors.LIGHT_GREY));
2748
2749 super.GetDebugActions(outputList);
2750 }
Param4< int, int, string, int > TSelectableActionInfoWithColor
Definition EntityAI.c:97
EActions
Definition EActions.c:2
const int SAT_DEBUG_ACTION
Definition constants.c:431

Перекрестные ссылки SAT_DEBUG_ACTION.

◆ GetFireConsumableByItem()

FireConsumable GetFireConsumableByItem ( ItemBase item)
protected
1423 {
1424 return m_FireConsumables.Get(item);
1425 }

Перекрестные ссылки m_FireConsumables.

Используется в FireplaceBase::EEItemDetached().

◆ GetFireConsumableTypeEnergy()

float GetFireConsumableTypeEnergy ( ItemBase item)
protected

support for inherited classes; second pass of lookup inside FireConsumableType

1391 {
1393 if (!fireConsumableType)
1394 {
1396 int count = m_FireConsumableTypes.Count();
1397 for (int i = 0; i < count; ++i)
1398 {
1399 if (item.IsInherited(m_FireConsumableTypes.GetKey(i)))
1401 }
1402 }
1403
1405 return fireConsumableType.GetEnergy();
1406
1407 return 0;
1408 }

Перекрестные ссылки m_FireConsumableTypes.

Используется в AddToFireConsumables().

◆ GetFireEffectPosition()

vector GetFireEffectPosition ( )
protected
1325 {
1326 return Vector(0, 0.05, 0);
1327 }
proto native vector Vector(float x, float y, float z)
Vector constructor from components.

Перекрестные ссылки Vector().

Используется в ParticleFireEndStart(), ParticleFireStartStart(), ParticleFireWindyNoIgniteStart(), ParticleNormalFireStart(), ParticleSmallFireStart(), ParticleSteamEndStart(), ParticleSteamExtinguishingStart() и ParticleWetNoIgniteStart().

◆ GetFireState()

int GetFireState ( )
protected
1710 {
1711 return m_FireState;
1712 }
FireplaceFireState m_FireState
Definition FireplaceBase.c:30

Перекрестные ссылки m_FireState.

Используется в Heating(), RefreshFireParticlesAndSounds() и RefreshFireState().

◆ GetFuelBurnRateMP()

float GetFuelBurnRateMP ( )
protected
1699 {
1700 return m_FuelBurnRateMP;
1701 }
float m_FuelBurnRateMP
Definition FireplaceBase.c:35

Перекрестные ссылки m_FuelBurnRateMP.

Используется в Heating().

◆ GetFuelCount()

int GetFuelCount ( )
protected

Returns count of all fuel type items (define in 'm_FuelTypes') attached to fireplace.

1542 {
1543 int attachmentsCount = GetInventory().AttachmentCount();
1544 int fuelCount = 0;
1545
1546 for (int i = 0; i < attachmentsCount; ++i)
1547 {
1548 ItemBase item = ItemBase.Cast(GetInventory().GetAttachmentFromIndex(i));
1549 if (IsFuel(item))
1550 fuelCount++;
1551 }
1552
1553 return fuelCount;
1554 }

Перекрестные ссылки IsFuel().

Используется в AddWetnessToFireplace(), Cooling(), HasLastFuelKindlingAttached() и Heating().

◆ GetIgniteFailure()

bool GetIgniteFailure ( )
protected
2343 {
2344 return m_NoIgnite;
2345 }
bool m_NoIgnite
Definition FireplaceBase.c:28

Перекрестные ссылки m_NoIgnite.

Используется в FireplaceBase::IsThisIgnitionSuccessful().

◆ GetItemToConsume()

FireConsumable GetItemToConsume ( )
protected
1464 {
1465 return m_ItemToConsume;
1466 }
ref FireConsumable m_ItemToConsume
Definition FireplaceBase.c:103

Перекрестные ссылки m_ItemToConsume.

Используется в SpendFireConsumable().

◆ GetKindlingCount()

int GetKindlingCount ( )
protected

Returns count of all kindling type items (define in 'm_KindlingTypes') attached to fireplace.

1525 {
1526 int attachmentsCount = GetInventory().AttachmentCount();
1527 int kindlingCount = 0;
1528
1529 for (int i = 0; i < attachmentsCount; ++i)
1530 {
1531 ItemBase item = ItemBase.Cast(GetInventory().GetAttachmentFromIndex(i));
1532
1533 if (IsKindling(item))
1534 kindlingCount++;
1535 }
1536
1537 return kindlingCount;
1538 }

Перекрестные ссылки IsKindling().

Используется в HasAnyKindling(), HasLastFuelKindlingAttached() и RefreshFireplaceVisuals().

◆ GetLightEntity()

FireplaceLight GetLightEntity ( )
protected
2525 {
2526 return m_Light;
2527 }
FireplaceLight m_Light
Definition FireplaceBase.c:96

Перекрестные ссылки m_Light.

Используется в RefreshFireplaceVisuals() и ~FireplaceBase().

◆ GetPlaceSoundset()

override string GetPlaceSoundset ( )
protected
2554 {
2555 return "placeFireplace_SoundSet";
2556 }

◆ GetSmokeEffectPosition()

vector GetSmokeEffectPosition ( )
protected
1330 {
1331 return Vector(0, 0.05, 0);
1332 }

Перекрестные ссылки Vector().

◆ GetSurfaceWetnessOnHeatModifier()

float GetSurfaceWetnessOnHeatModifier ( notnull EntityAI entity)
protected
2406 {
2407 string surfaceType
2408 int liquidType;
2409 g_Game.SurfaceUnderObjectCorrectedLiquid(entity, surfaceType, liquidType);
2410
2411 return Surface.GetParamFloat(surfaceType, "wetnessOnHeatModifier");
2412 }
DayZGame g_Game
Definition DayZGame.c:3815
Definition Surface.c:2
static float GetParamFloat(string surface_name, string param_name)
Definition Surface.c:18

Перекрестные ссылки g_Game и Surface::GetParamFloat().

Используется в OnItemLocationChanged().

◆ GetTemperatureLossMP()

float GetTemperatureLossMP ( )
protected

determines how fast will the fireplace loose its temperature when cooling (lower is better)

2790 {
2791 return m_TemperatureLossMP;
2792 }
float m_TemperatureLossMP
value for calculating of wetness that fireplace gain when raining
Definition FireplaceBase.c:2786

Перекрестные ссылки m_TemperatureLossMP.

◆ HasAnyKindling()

bool HasAnyKindling ( )
protected
2328 {
2329 return GetKindlingCount() > 0;
2330 }
int GetKindlingCount()
Returns count of all kindling type items (define in 'm_KindlingTypes') attached to fireplace.
Definition FireplaceBase.c:1524

Перекрестные ссылки GetKindlingCount().

Используется в FireplaceBase::CanBeIgnitedBy() и FireplaceBase::IsThisIgnitionSuccessful().

◆ HasAshes()

bool HasAshes ( )
protected
1636 {
1637 return m_HasAshes;
1638 }
bool m_HasAshes
Definition FireplaceBase.c:25

Перекрестные ссылки m_HasAshes.

Используется в FireplaceBase::CanPutInCargo(), FireplaceBase::CanPutIntoHands(), IsPrepareToDelete(), FireplaceBase::IsPrepareToDelete(), RefreshFireplaceVisuals() и SpendFireConsumable().

◆ HasCookingStand()

bool HasCookingStand ( )
protected
2445 {
2446 return GetInventory().FindAttachment(InventorySlots.GetSlotIdFromString("CookingTripod")) != null;
2447 }
provides access to slot configuration
Definition InventorySlots.c:6
static proto native int GetSlotIdFromString(string slot_name)
converts string to slot_id

Перекрестные ссылки InventorySlots::GetSlotIdFromString().

Используется в FireplaceBase::CanPutInCargo(), FireplaceBase::CanPutIntoHands() и Heating().

◆ HasLastAttachment()

bool HasLastAttachment ( )
protected
1608 {
1609 return GetInventory().AttachmentCount() == 1;
1610 }

◆ HasLastFuelKindlingAttached()

bool HasLastFuelKindlingAttached ( )
protected
1614 {
1615 return (GetFuelCount() + GetKindlingCount()) == 1;
1616 }

Перекрестные ссылки GetFuelCount() и GetKindlingCount().

◆ HasStoneCircle()

bool HasStoneCircle ( )
protected
1652 {
1653 return m_HasStoneCircle;
1654 }
bool m_HasStoneCircle
Definition FireplaceBase.c:27

Перекрестные ссылки m_HasStoneCircle.

Используется в CanBuildOven(), CanBuildStoneCircle(), CanDismantleStoneCircle(), FireplaceBase::CanPutInCargo(), FireplaceBase::CanPutIntoHands(), FireplaceBase::CanReleaseAttachment() и RefreshFireplaceVisuals().

◆ HasStones()

bool HasStones ( )
protected
1657 {
1658 EntityAI attached_item = GetAttachmentByType(ATTACHMENT_STONES);
1659
1660 return attached_item && attached_item.GetQuantity() > 0;
1661 }

Перекрестные ссылки ATTACHMENT_STONES.

Используется в FireplaceBase::CanPutInCargo(), FireplaceBase::CanPutIntoHands(), GetAttachedStonesCount() и RefreshFireplaceVisuals().

◆ Heating()

void Heating ( )
protected
1805 {
1806 float temperature;
1807 float temperatureModifier = 0;
1808
1809 if (IsOpen() && !IsOven())
1811
1812 //check burning conditions
1814 {
1815 StopFire(FireplaceFireState.EXTINGUISHED_FIRE);
1816 return;
1817 }
1818 else
1819 {
1820 if (m_FireConsumables.Count() == 0)
1821 {
1822 StopFire();
1823 return;
1824 }
1825 }
1826
1827 //spend actual fire consumable
1829 SpendFireConsumable(amount);
1830
1831 //set wetness and alter temperature modifier (which will lower temperature increase because of soaking)
1832 float rain = GetGame().GetWeather().GetRain().GetActual();
1833 float combinedWindAndSnowfall = MiscGameplayFunctions.GetCombinedSnowfallWindValue();
1834
1835 if ((rain >= RAIN_EFFECT_LIMIT || combinedWindAndSnowfall >= SNOWFALL_EFFECT_LIMIT) && !IsRoofAbove() && IsOpen() && !IsOven())
1836 {
1838 {
1841 }
1842 else
1843 {
1846 }
1847 }
1848 //subtract wetness when heating and not raining above
1849 else
1850 {
1852 }
1853
1856
1857 // temperature via UniversalTemperatureSource
1858 m_UTSLFireplace.SetFuelCount(GetFuelCount());
1860 m_UTSLFireplace.SetCurrentTemperature(temperature);
1862
1863 //check fire state
1864 if (GetFireState() != FireplaceFireState.EXTINGUISHING_FIRE)
1865 {
1867 }
1868
1869 //damage cargo items
1871
1872 //manage cooking equipment (this applies only for case of cooking pot on a tripod)
1874 {
1876 }
1877
1879 int i;
1880 // manage cooking on direct cooking slots
1882 {
1883 for (i = 0; i < DIRECT_COOKING_SLOT_COUNT; i++)
1884 {
1886 {
1887 cookingItemTemperature = m_DirectCookingSlots[i].GetTemperature();
1889 }
1890 }
1891 }
1892
1893 // manage smoking slots
1894 if (SmokingSlotsInUse())
1895 {
1896 for (i = 0; i < SMOKING_SLOT_COUNT; i++)
1897 {
1898 if (m_SmokingSlots[i])
1899 {
1901 }
1902 }
1903 }
1904
1905 //Make noise for AI, only at night
1906 if (GetGame().GetWorld().IsNight() && m_CanNoise)
1907 {
1908 NoiseSystem noise = GetGame().GetNoiseSystem();
1909 if (noise && m_NoisePar)
1910 {
1911 noise.AddNoisePos(this, GetPosition(), m_NoisePar, NoiseAIEvaluate.GetNoiseReduction(GetGame().GetWeather()));
1912 }
1913 m_CanNoise = false;
1914 }
1915 else
1916 m_CanNoise = true;
1917
1918 Synchronize();
1919 }
float GetFuelBurnRateMP()
Definition FireplaceBase.c:1698
const float WET_SURFACE_INCREMENT
Definition FireplaceBase.c:223
const float PARAM_TEMPERATURE_INCREASE
minimum fireplace temperature under which the fireplace is inactive (degree Celsius)
Definition FireplaceBase.c:45
const float PARAM_FIRE_CONSUM_RATE_AMOUNT
value for calculating wetness loss during cooling process
Definition FireplaceBase.c:53
bool m_CanNoise
Definition FireplaceBase.c:215
bool HasCookingStand()
Definition FireplaceBase.c:2444
void StopFire(FireplaceFireState fire_state=FireplaceFireState.END_FIRE)
Definition FireplaceBase.c:1925
ref NoiseParams m_NoisePar
Definition FireplaceBase.c:214
void SpendFireConsumable(float amount)
Definition FireplaceBase.c:1472
void RefreshFireState()
Definition FireplaceBase.c:1056
int GetFireState()
Definition FireplaceBase.c:1709
const float PARAM_BURN_WET_THRESHOLD
maximum rain value when the fireplace can be ignited
Definition FireplaceBase.c:50
Definition SensesAIEvaluate.c:2
static float GetNoiseReduction(Weather weather)
Definition SensesAIEvaluate.c:18
Definition Noise.c:2

Перекрестные ссылки AddWetnessToFireplace(), BurnItemsInFireplace(), CheckForRoofLimited(), CookOnDirectSlot(), CookWithEquipment(), DIRECT_COOKING_SLOT_COUNT, DirectCookingSlotsInUse(), GetFireState(), GetFuelBurnRateMP(), GetFuelCount(), GetGame(), NoiseAIEvaluate::GetNoiseReduction(), GetPosition, GetWet(), HasCookingStand(), FireplaceBase::IsOpen(), IsOven(), m_CanNoise, m_CookingEquipment, m_DirectCookingSlots, m_FireConsumables, m_NoisePar, m_SmokingSlots, m_UTSLFireplace, m_UTSource, m_UTSSettings, PARAM_BURN_WET_THRESHOLD, PARAM_FIRE_CONSUM_RATE_AMOUNT, PARAM_TEMPERATURE_DECREASE, PARAM_TEMPERATURE_INCREASE, PARAM_WET_HEATING_DECREASE_COEF, RAIN_EFFECT_LIMIT, RAIN_WETNESS_INCREASE, RefreshFireState(), SmokeOnSmokingSlot(), SMOKING_SLOT_COUNT, SmokingSlotsInUse(), SNOWFALL_EFFECT_LIMIT, SNOWFALL_WETNESS_INCREASE, SpendFireConsumable(), StopFire(), Synchronize(), TIMER_HEATING_UPDATE_INTERVAL и WET_SURFACE_INCREMENT.

◆ InitializeTemperatureSources()

void InitializeTemperatureSources ( )
protected
586 {
588 m_UTSLFireplace.SetSmallFireplaceTemperatureMax(PARAM_SMALL_FIRE_TEMPERATURE);
589 m_UTSLFireplace.SetNormalFireplaceTemperatureMax(PARAM_NORMAL_FIRE_TEMPERATURE);
590
592 }
const float PARAM_SMALL_FIRE_TEMPERATURE
Definition FireplaceBase.c:41
original Timer deletes m_params which is unwanted
Definition UniversalTemperatureSource.c:28
Definition UniversalTemperatureSourceLambdaFireplace.c:2

Перекрестные ссылки m_UTSLFireplace, m_UTSource, m_UTSSettings, PARAM_NORMAL_FIRE_TEMPERATURE и PARAM_SMALL_FIRE_TEMPERATURE.

◆ IsBarrelWithHoles()

bool IsBarrelWithHoles ( )
protected
556 {
557 return false;
558 }

◆ IsBaseFireplace()

bool IsBaseFireplace ( )
protected
551 {
552 return false;
553 }

◆ IsBurning()

◆ IsCargoEmpty()

bool IsCargoEmpty ( )
protected
2440 {
2441 return (GetInventory().GetCargo().GetItemCount() == 0);
2442 }

Используется в FireplaceBase::CanPutInCargo() и FireplaceBase::CanPutIntoHands().

◆ IsCeilingHighEnoughForSmoke()

bool IsCeilingHighEnoughForSmoke ( )
protected
2371 {
2372 return !MiscGameplayFunctions.IsUnderRoof(this, FireplaceBase.MIN_CEILING_HEIGHT);
2373 }
Definition BarrelHoles_ColorBase.c:2

Используется в FireplaceBase::IsThisIgnitionSuccessful().

◆ IsEmpty()

override bool IsEmpty ( )
protected
2434 {
2435 return (GetInventory().GetCargo().GetItemCount() == 0 && GetInventory().AttachmentCount() == 0);
2436 }

Используется в RecipeBase::CanDo(), CivilianBelt::CanPutInCargo(), HipPack_ColorBase::CanPutInCargo(), Belt_Base::CanPutInCargo(), MilitaryBelt::CanPutInCargo(), RopeBelt::CanPutInCargo() и IsPrepareToDelete().

◆ IsEntityOnInteriorSurface()

static bool IsEntityOnInteriorSurface ( notnull EntityAI entity_ai)
staticprotected
2421 {
2422 string surfaceType;
2423 vector fireplacePosition = entity_ai.GetPosition();
2424 GetGame().SurfaceGetType3D(fireplacePosition[0], fireplacePosition[1] + 1.0, fireplacePosition[2], surfaceType);
2425 return (GetGame().ConfigGetInt("CfgSurfaces " + surfaceType + " interior") == 1);
2426 }

Перекрестные ссылки GetGame().

Используется в FireplaceBase::CanIgniteEntityAsFireplace().

◆ IsEntityOnWaterSurface()

static bool IsEntityOnWaterSurface ( notnull EntityAI entity_ai)
staticprotected
2388 {
2389 vector fireplacePosition = entity_ai.GetPosition();
2390 string surfaceType;
2391 g_Game.SurfaceGetType3D(fireplacePosition[0], fireplacePosition[1] + g_Game.SurfaceGetSeaLevel(), fireplacePosition[2], surfaceType);
2392 if (!surfaceType)
2393 {
2394 float waterLevelDiff = fireplacePosition[1] - g_Game.SurfaceGetSeaLevel();
2395 return waterLevelDiff < 0.5;
2396 }
2397 else if (surfaceType.Contains("water"))
2398 {
2399 return true;
2400 }
2401
2402 return false;
2403 }

Перекрестные ссылки g_Game.

◆ IsEntityWet()

static bool IsEntityWet ( notnull EntityAI entity_ai)
staticprotected
2354 {
2355 return (entity_ai.GetWet() >= FireplaceBase.PARAM_MAX_WET_TO_IGNITE);
2356 }

◆ IsFacingFireplace()

bool IsFacingFireplace ( PlayerBase player)
protected

DEPRECATED.

2316 {
2317 ErrorEx("Deprecated method", ErrorExSeverity.INFO);
2318
2319 return false;
2320 }
ErrorExSeverity
Definition EnDebug.c:62
enum ShapeType ErrorEx

Перекрестные ссылки ErrorEx.

◆ IsFireplace()

override bool IsFireplace ( )
protected
546 {
547 return true;
548 }

Используется в TripodBase::CanSwapEntities().

◆ IsFireplaceIndoor()

bool IsFireplaceIndoor ( )
protected
561 {
562 return false;
563 }

◆ IsFuel()

bool IsFuel ( ItemBase item)
protected

Returns if item attached to fireplace is fuel.

support for inherited classes; second pass of lookup inside FireConsumableType

1576 {
1578 if (!fireConsumableType)
1579 {
1581 int count = m_FireConsumableTypes.Count();
1582 for (int i = 0; i < count; ++i)
1583 {
1584 if (item.IsInherited(m_FireConsumableTypes.GetKey(i)))
1586 }
1587 }
1588
1589 return fireConsumableType && !fireConsumableType.IsKindling();
1590 }

Перекрестные ссылки m_FireConsumableTypes.

Используется в AddDamageToItemByFireEx(), FireplaceBase::CanReceiveAttachment(), CanReleaseAttachment(), FireplaceBase::CanReleaseAttachment(), FireplaceBase::EEItemAttached(), FireplaceBase::EEItemDetached() и GetFuelCount().

◆ IsInAnimPhase()

bool IsInAnimPhase ( string anim_phase)
protected
2451 {
2452 return GetAnimationPhase(anim_phase) == 0;
2453 }

Используется в SetBurntFirewood().

◆ IsIndoorOven()

bool IsIndoorOven ( )
protected
566 {
567 return false;
568 }

◆ IsItemAttachedQuantity()

bool IsItemAttachedQuantity ( typename item_type ,
float quantity )
protected
1600 {
1601 ItemBase item = ItemBase.Cast(GetAttachmentByType(item_type));
1602
1603 return item.GetQuantity() >= quantity;
1604 }

◆ IsItemTypeAttached()

bool IsItemTypeAttached ( typename item_type )
protected
1594 {
1595 return GetAttachmentByType(item_type) != null;
1596 }

Используется в RefreshFireplaceVisuals() и FireplaceBase::RefreshPhysics().

◆ IsKindling()

bool IsKindling ( ItemBase item)
protected

Returns if item attached to fireplace is kindling.

support for inherited classes; second pass of lookup inside FireConsumableType

1558 {
1560 if (!fireConsumableType)
1561 {
1563 int count = m_FireConsumableTypes.Count();
1564 for (int i = 0; i < count; ++i)
1565 {
1566 if (item.IsInherited(m_FireConsumableTypes.GetKey(i)))
1568 }
1569 }
1570
1571 return fireConsumableType && fireConsumableType.IsKindling();
1572 }

Перекрестные ссылки m_FireConsumableTypes.

Используется в AddDamageToItemByFireEx(), FireplaceBase::CanReceiveAttachment(), CanReleaseAttachment(), FireplaceBase::CanReleaseAttachment(), FireplaceBase::EEItemAttached(), FireplaceBase::EEItemDetached() и GetKindlingCount().

◆ IsOnInteriorSurface()

bool IsOnInteriorSurface ( )
protected
2428 {
2429 return FireplaceBase.IsEntityOnInteriorSurface(this);
2430 }

Используется в FireplaceBase::IsThisIgnitionSuccessful().

◆ IsOnWaterSurface()

bool IsOnWaterSurface ( )
protected
2415 {
2416 return FireplaceBase.IsEntityOnWaterSurface(this);
2417 }

Используется в FireplaceBase::IsThisIgnitionSuccessful().

◆ IsOpen()

override bool IsOpen ( )
protected
2365 {
2366 return true;
2367 }

◆ IsOven()

◆ IsPrepareToDelete()

override bool IsPrepareToDelete ( )
protected
652 {
653 return IsEmpty() && !IsBurning() && !HasAshes();
654 }
bool HasAshes()
Definition FireplaceBase.c:1635
override bool IsEmpty()
Definition FireplaceBase.c:2433

Перекрестные ссылки HasAshes(), IsBurning() и IsEmpty().

Используется в Entity::CheckForDestroy() и Entity::TryDelete().

◆ IsRainingAbove()

bool IsRainingAbove ( )
protected
2382 {
2383 return FireplaceBase.IsRainingAboveEntity(this);
2384 }

Используется в FireplaceBase::IsThisIgnitionSuccessful().

◆ IsRainingAboveEntity()

static bool IsRainingAboveEntity ( notnull EntityAI entity_ai)
staticprotected
2377 {
2378 return (GetGame() && (GetGame().GetWeather().GetRain().GetActual() >= FireplaceBase.PARAM_IGNITE_RAIN_THRESHOLD));
2379 }

Перекрестные ссылки GetGame().

◆ IsSelfAdjustingTemperature()

override bool IsSelfAdjustingTemperature ( )
protected
581 {
582 return m_IsBurning || (m_CoolingTimer && m_CoolingTimer.IsRunning())); //FireplaceFireState.NO_FIRE?
583 }

Перекрестные ссылки m_CoolingTimer и m_IsBurning.

◆ IsSpaceFor()

bool IsSpaceFor ( vector size)
protected
2456 {
2457 array<Object> objs = {};
2458 if (GetGame().IsBoxCollidingGeometry(GetWorldPosition() + Vector(0, size[1] * 0.5 + 0.1, 0), GetDirection().VectorToAngles(), size, ObjIntersect.View, ObjIntersect.Geom, {this}, objs))
2459 {
2460 foreach (Object obj : objs)
2461 {
2462 if (dBodyGetInteractionLayer(obj) == PhxInteractionLayers.ITEM_LARGE)
2463 return false;
2464 }
2465 }
2466 return true;
2467 }
PhxInteractionLayers
Definition DayZPhysics.c:2
Definition ObjectTyped.c:2
proto native int dBodyGetInteractionLayer(notnull IEntity ent)

Перекрестные ссылки dBodyGetInteractionLayer(), GetGame() и Vector().

Используется в IsSpaceForCircle() и IsSpaceForOven().

◆ IsSpaceForCircle()

bool IsSpaceForCircle ( )
protected
2498 {
2499 return IsSpaceFor(Vector(0.9, 0.1, 0.9));
2500 }
bool IsSpaceFor(vector size)
Definition FireplaceBase.c:2455

Перекрестные ссылки IsSpaceFor() и Vector().

Используется в CanBuildStoneCircle().

◆ IsSpaceForOven()

bool IsSpaceForOven ( )
protected
2486 {
2487 const float size = 0.6;
2488 return IsSpaceFor(Vector(size, size, size));
2489 }

Перекрестные ссылки IsSpaceFor() и Vector().

Используется в CanBuildOven().

◆ IsWet()

bool IsWet ( )
protected
2359 {
2360 return FireplaceBase.IsEntityWet(this);
2361 }

Используется в FireplaceBase::IsThisIgnitionSuccessful() и RefreshFireplaceVisuals().

◆ IsWindy()

static bool IsWindy ( )
staticprotected
2334 {
2335 //check wind
2336 float wind_speed = GetGame().GetWeather().GetWindSpeed();
2337 float wind_speed_threshold = GetGame().GetWeather().GetWindMaximumSpeed() * FireplaceBase.IGNITE_WIND_THRESHOLD;
2338
2339 return (wind_speed >= wind_speed_threshold);
2340 }

Перекрестные ссылки GetGame().

Используется в FireplaceBase::IsThisIgnitionSuccessful() и StartHeating().

◆ LockOvenAttachments()

void LockOvenAttachments ( bool lock)
protected
2648 {
2649 //Print("LockOvenAttachments");
2650 //string path_cooking_equipment = "" + CFG_VEHICLESPATH + " " + GetType() + " GUIInventoryAttachmentsProps CookingEquipment attachmentSlots";
2651 string path_cooking_equipment = string.Format("%1 %2 GUIInventoryAttachmentsProps CookingEquipment attachmentSlots", CFG_VEHICLESPATH, GetType());
2652 //string path_direct_cooking = "" + CFG_VEHICLESPATH + " " + GetType() + " GUIInventoryAttachmentsProps DirectCooking attachmentSlots";
2653 string path_direct_cooking = string.Format("%1 %2 GUIInventoryAttachmentsProps DirectCooking attachmentSlots", CFG_VEHICLESPATH, GetType());
2654 if (GetGame().ConfigIsExisting(path_cooking_equipment) && GetGame().ConfigIsExisting(path_direct_cooking))
2655 {
2659 GetGame().ConfigGetTextArray(path_direct_cooking,arr_direct_cooking);
2660 for (int i = 0; i < arr_cooking_equipment.Count(); i++)
2661 {
2662 if (lock != GetInventory().GetSlotLock(InventorySlots.GetSlotIdFromString(arr_cooking_equipment[i])))
2663 {
2664 GetInventory().SetSlotLock(InventorySlots.GetSlotIdFromString(arr_cooking_equipment[i]),lock);
2665 //Print("attachment lock: " + arr_cooking_equipment[i] + " " + lock);
2666 }
2667 }
2668
2669 for (i = 0; i < arr_direct_cooking.Count(); i++)
2670 {
2671 if (lock == GetInventory().GetSlotLock(InventorySlots.GetSlotIdFromString(arr_direct_cooking[i])))
2672 {
2673 GetInventory().SetSlotLock(InventorySlots.GetSlotIdFromString(arr_direct_cooking[i]),!lock);
2674 //Print("attachment lock: " + arr_direct_cooking[i] + " " + !lock);
2675 }
2676 }
2677 }
2679 }
eBleedingSourceType GetType()
Definition BleedingSource.c:63
int m_OvenAttachmentsLockState
Definition FireplaceBase.c:29
const string CFG_VEHICLESPATH
Definition constants.c:217

Перекрестные ссылки CFG_VEHICLESPATH, GetGame(), InventorySlots::GetSlotIdFromString(), GetType() и m_OvenAttachmentsLockState.

Используется в RefreshFireplaceVisuals().

◆ OnAction()

override bool OnAction ( int action_id,
Man player,
ParamsReadContext ctx )
protected
2753 {
2754 if (super.OnAction(action_id, player, ctx))
2755 return true;
2756 if (GetGame().IsServer() || !GetGame().IsMultiplayer())
2757 {
2758 if (action_id == EActions.ACTIVATE_ENTITY)
2759 {
2761 }
2762 else if (action_id == EActions.DEACTIVATE_ENTITY)
2763 {
2764 StopFire();
2765 }
2766 }
2767 return false;
2768 }
override void OnIgnitedThis(EntityAI fire_source)
Executed on Server when some item ignited this one.
Definition FireworksBase.c:96

Перекрестные ссылки GetGame(), FireplaceBase::OnIgnitedThis() и StopFire().

◆ OnAttachmentQuantityChanged()

override void OnAttachmentQuantityChanged ( ItemBase item)
protected
2627 {
2628 super.OnAttachmentQuantityChanged(item);
2629
2631 }

Перекрестные ссылки CalcAndSetQuantity().

◆ OnAttachmentRuined()

override void OnAttachmentRuined ( EntityAI attachment)
protected
378 {
379 switch (attachment.Type())
380 {
383 int slot = InventorySlots.GetSlotIdFromString("CookingEquipment");
384 EntityAI ent = GetInventory().FindAttachment(slot);
385 if (ent)
386 {
387 switch (ent.Type())
388 {
392 vector direction = ent.GetDirection();
394
395 float angle = Math.Acos(dot);
396 if (direction[0] < 0)
397 {
398 angle = -angle;
399 }
400
401 float cos = Math.Cos(angle);
402 float sin = Math.Sin(angle);
403 GetInventory().DropEntityInBounds(InventoryMode.SERVER, this, ent, "2 0 2", angle, cos, sin);
404 break;
405 }
406 }
407
408 attachment.Delete();
409 break;
410 }
411 }
InventoryMode
NOTE: PREDICTIVE is not to be used at all in multiplayer.
Definition Inventory.c:22
static const vector Forward
Definition EnConvert.c:109
static float Dot(vector v1, vector v2)
Returns Dot product of vector v1 and vector v2.
Definition EnConvert.c:271
static proto float Acos(float c)
Returns angle in radians from cosinus.
static proto float Cos(float angle)
Returns cosinus of angle in radians.
static proto float Sin(float angle)
Returns sinus of angle in radians.

Перекрестные ссылки Math::Acos(), ATTACHMENT_CAULDRON, ATTACHMENT_COOKING_POT, ATTACHMENT_COOKINGSTAND, ATTACHMENT_FRYING_PAN, ATTACHMENT_TRIPOD, Math::Cos(), vector::Dot(), vector::Forward, InventorySlots::GetSlotIdFromString() и Math::Sin().

◆ OnDebugSpawn()

override void OnDebugSpawn ( )
protected
2728 {
2729 ItemBase firewood = ItemBase.Cast(GetInventory().CreateInInventory("Firewood"));
2730 firewood.SetQuantity(firewood.GetQuantityMax());
2731
2732 ItemBase sticks = ItemBase.Cast(GetInventory().CreateInInventory("WoodenStick"));
2733 sticks.SetQuantity(sticks.GetQuantityMax());
2734
2735 ItemBase stone = ItemBase.Cast(GetInventory().CreateInInventory("Stone"));
2736 stone.SetQuantity(stone.GetQuantityMax());
2737
2738 GetInventory().CreateInInventory("Rag");
2739
2740 SpawnEntityOnGroundPos("PetrolLighter", GetPosition());
2741 }

Перекрестные ссылки GetPosition.

◆ OnItemLocationChanged()

override void OnItemLocationChanged ( EntityAI old_owner,
EntityAI new_owner )
protected
346 {
347 super.OnItemLocationChanged(old_owner, new_owner);
348
349 //refresh physics after location change (with delay)
351
353 GetInventory().GetCurrentInventoryLocation(loc);
354 if (loc.GetType() == InventoryLocationType.GROUND)
355 {
356 if (IsOpen() && !IsOven())
357 CheckForRoofLimited(0); //roof check when moved to ground
358
360 {
363 }
364 }
365 else
366 {
368 {
371 }
372 }
373
375 }
void RefreshFireplacePhysics()
float GetSurfaceWetnessOnHeatModifier(notnull EntityAI entity)
Definition FireplaceBase.c:2405
InventoryLocationType
types of Inventory Location
Definition InventoryLocation.c:4
InventoryLocation.
Definition InventoryLocation.c:29
const int CALL_CATEGORY_GAMEPLAY
Definition tools.c:10

Перекрестные ссылки CALL_CATEGORY_GAMEPLAY, CheckForRoofLimited(), GetGame(), GetSurfaceWetnessOnHeatModifier(), FireplaceBase::IsOpen(), IsOven(), m_ThawnSurfaceUnderSupport, m_UnderObjectDecalSpawnComponent, m_UnderObjectDecalSpawnSettings, FireplaceBase::RefreshFireplacePhysics() и UnderObjectDecalSpawnComponent().

◆ OnPlacementComplete()

override void OnPlacementComplete ( Man player,
vector position = "0 0 0",
vector orientation = "0 0 0" )
protected
2539 {
2540 super.OnPlacementComplete(player, position, orientation);
2541
2542 if (GetGame().IsServer())
2543 {
2544 //remove grass
2546 cc_object.SetOrientation(orientation);
2547 GetGame().GetCallQueue(CALL_CATEGORY_GAMEPLAY).CallLater(GetGame().ObjectDelete, 1000, false, cc_object);
2548
2549 SetIsPlaceSound(true);
2550 }
2551 }
const int ECE_PLACE_ON_SURFACE
Definition CentralEconomy.c:37
const string OBJECT_CLUTTER_CUTTER
Definition FireplaceBase.c:204
void SetIsPlaceSound(bool is_place_sound)
Definition ItemBase.c:9083

Перекрестные ссылки CALL_CATEGORY_GAMEPLAY, ECE_PLACE_ON_SURFACE, GetGame(), OBJECT_CLUTTER_CUTTER и SetIsPlaceSound().

◆ OnRPC()

override void OnRPC ( PlayerIdentity sender,
int rpc_type,
ParamsReadContext ctx )
protected
2686 {
2687 super.OnRPC(sender, rpc_type, ctx);
2688
2689 ref Param1<bool> p = new Param1<bool>(false);
2690
2691 if (ctx.Read(p))
2692 {
2693 bool failure = p.param1;
2694 }
2695
2696 switch (rpc_type)
2697 {
2698 case FirePlaceFailure.WIND:
2699
2700 if (failure)
2701 {
2703 SoundFireStop();
2705 }
2706
2707 break;
2708
2709 case FirePlaceFailure.WET:
2710
2711 if (failure)
2712 {
2714 SoundFireStop();
2716 }
2717
2718 break;
2719 }
2720 }
void ParticleWetNoIgniteStart()
Definition FireplaceBase.c:1285
void SoundFireStop()
Definition FireplaceBase.c:1375
void SoundFireWetNoIgniteStart()
Definition FireplaceBase.c:1359
void SoundFireWindyNoIgniteStart()
Definition FireplaceBase.c:1369
void ParticleFireWindyNoIgniteStart()
Definition FireplaceBase.c:1251

Перекрестные ссылки ParticleFireWindyNoIgniteStart(), ParticleWetNoIgniteStart(), SoundFireStop(), SoundFireWetNoIgniteStart() и SoundFireWindyNoIgniteStart().

◆ OnStoreLoad()

override bool OnStoreLoad ( ParamsReadContext ctx,
int version )
protected
441 {
442 if (!super.OnStoreLoad(ctx, version))
443 return false;
444
445 //--- Fireplace data ---
446 //Load ashes state
447 if (!ctx.Read(m_HasAshes))
448 {
449 m_HasAshes = false; //set default
450 return false;
451 }
452
453 //Load temperature loss MP
454 if (version < 139 && !ctx.Read(m_TemperatureLossMP))
455 {
456 m_TemperatureLossMP = 1.0; //set default
457 return false;
458 }
459
460 //Load fuel burn rate MP
461 if (!ctx.Read(m_FuelBurnRateMP))
462 {
463 m_FuelBurnRateMP = 1.0; //set default
464 return false;
465 }
466
467 //Load burning state, if true start fire
468 if (!ctx.Read(m_IsBurning))
469 {
470 m_IsBurning = false; //set default
471 return false;
472 }
473 //---
474
475 return true;
476 }

Перекрестные ссылки m_FuelBurnRateMP, m_HasAshes, m_IsBurning и m_TemperatureLossMP.

◆ OnStoreSave()

override void OnStoreSave ( ParamsWriteContext ctx)
protected
427 {
428 super.OnStoreSave(ctx);
429
430 //Save ashes state
431 ctx.Write(m_HasAshes);
432
433 //Save fuel burn rate MP
434 ctx.Write(m_FuelBurnRateMP);
435
436 //Save burning state
437 ctx.Write(m_IsBurning);
438 }

Перекрестные ссылки m_FuelBurnRateMP, m_HasAshes и m_IsBurning.

◆ OnVariablesSynchronized()

override void OnVariablesSynchronized ( )
protected
512 {
513 super.OnVariablesSynchronized();
514
517
518 if (IsPlaceSound())
519 {
521 }
522
523 if (IsBaseFireplace() && !IsOven())
524 {
526 {
528 }
529 else if (!m_IsBurning && m_AreaDamage)
530 {
532 }
533 }
534
536 m_UnderObjectDecalSpawnComponent.UpdateSize(Math.InverseLerp(0.0, GetTemperatureMax() * 0.6, GetTemperature()));
537 }
void RefreshFireParticlesAndSounds(bool force_refresh)
Definition FireplaceBase.c:852
void CreateAreaDamage()
Definition FireplaceBase.c:2290
bool IsBaseFireplace()
Definition FireplaceBase.c:550
void PlayPlaceSound()
Definition ItemBase.c:9148
bool IsPlaceSound()
Definition ItemBase.c:9088
static proto float InverseLerp(float a, float b, float value)
Calculates the linear value that produces the interpolant value within the range [a,...

Перекрестные ссылки FireplaceBase::CreateAreaDamage(), DestroyAreaDamage(), Math::InverseLerp(), FireplaceBase::IsBaseFireplace(), IsOven(), IsPlaceSound(), m_AreaDamage, m_IsBurning, m_ThawnSurfaceUnderSupport, m_UnderObjectDecalSpawnComponent, PlayPlaceSound(), RefreshFireParticlesAndSounds() и RefreshFireplaceVisuals().

◆ ParticleFireEndStart()

void ParticleFireEndStart ( )
protected
1235 {
1236 if (IsOven())
1237 {
1239 }
1240 else
1241 {
1243 }
1244 }
bool PlayParticle(out Particle particle, int particle_type, vector pos, bool worldpos=false)
Definition FireplaceBase.c:1094
int PARTICLE_FIRE_END
Definition FireplaceBase.c:113
vector GetFireEffectPosition()
Definition FireplaceBase.c:1324
Particle m_ParticleFireEnd
Definition FireplaceBase.c:124
int PARTICLE_OVEN_FIRE_END
Definition FireplaceBase.c:114

Перекрестные ссылки GetFireEffectPosition(), IsOven(), m_ParticleFireEnd, PARTICLE_FIRE_END, PARTICLE_OVEN_FIRE_END и PlayParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleFireEndStop()

void ParticleFireEndStop ( )
protected
1247 {
1249 }
bool StopParticle(out Particle particle)
Definition FireplaceBase.c:1114

Перекрестные ссылки m_ParticleFireEnd и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleFireStartStart()

void ParticleFireStartStart ( )
protected
1129 {
1130 if (IsOven())
1131 {
1133 }
1134 else
1135 {
1137 }
1138 }
Particle m_ParticleFireStart
Definition FireplaceBase.c:119
int PARTICLE_FIRE_START
Definition FireplaceBase.c:106
int PARTICLE_OVEN_FIRE_START
Definition FireplaceBase.c:107

Перекрестные ссылки GetFireEffectPosition(), IsOven(), m_ParticleFireStart, PARTICLE_FIRE_START, PARTICLE_OVEN_FIRE_START и PlayParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleFireStartStop()

void ParticleFireStartStop ( )
protected
1141 {
1143 }

Перекрестные ссылки m_ParticleFireStart и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleFireWindyNoIgniteStart()

void ParticleFireWindyNoIgniteStart ( )
protected
1252 {
1253 if (IsOven())
1254 {
1256 }
1257 else
1258 {
1260 }
1261 }
int PARTICLE_NO_IGNITE_WIND
Definition FireplaceBase.c:117

Перекрестные ссылки GetFireEffectPosition(), IsOven(), m_ParticleFireEnd, PARTICLE_NO_IGNITE_WIND, PARTICLE_OVEN_FIRE_END и PlayParticle().

Используется в OnRPC().

◆ ParticleNormalFireStart()

void ParticleNormalFireStart ( )
protected
1165 {
1166 if (IsOven())
1167 {
1169 }
1170 else
1171 {
1173 }
1174 }
Particle m_ParticleNormalFire
Definition FireplaceBase.c:121
int PARTICLE_NORMAL_FIRE
Definition FireplaceBase.c:109
int PARTICLE_OVEN_FIRE
Definition FireplaceBase.c:110

Перекрестные ссылки GetFireEffectPosition(), IsOven(), m_ParticleNormalFire, PARTICLE_NORMAL_FIRE, PARTICLE_OVEN_FIRE и PlayParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleNormalFireStop()

void ParticleNormalFireStop ( )
protected
1177 {
1179 }

Перекрестные ссылки m_ParticleNormalFire и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleNormalSmokeStart()

void ParticleNormalSmokeStart ( )
protected
1209 {
1211
1212 //calculate air resistance
1213 float actual_height;
1215 {
1217
1218 //alter smoke height
1220 }
1221
1222 if (IsRoofAbove() || !IsOpen() || IsOven())
1223 {
1225 }
1226 }
float GetAirResistanceForSmokeParticles(float actual_height)
Definition FireplaceBase.c:1311
int PARTICLE_NORMAL_SMOKE
Definition FireplaceBase.c:112
bool GetCeilingHeight(out float actual_height)
Definition FireplaceBase.c:1295
vector GetSmokeEffectPosition()
Definition FireplaceBase.c:1329
Particle m_ParticleNormalSmoke
Definition FireplaceBase.c:123
void SetParameter(int emitter, int parameter, float value)
Set the value of a parameter of an emitor in the particle.
Definition Particle.c:625
EmitorParam
Definition EnVisual.c:114

Перекрестные ссылки GetAirResistanceForSmokeParticles(), GetCeilingHeight(), FireplaceBase::GetSmokeEffectPosition(), FireplaceBase::IsOpen(), IsOven(), m_ParticleNormalSmoke, PARTICLE_NORMAL_SMOKE, PlayParticle() и Particle::SetParameter().

◆ ParticleNormalSmokeStop()

void ParticleNormalSmokeStop ( )
protected
1229 {
1231 }

Перекрестные ссылки m_ParticleNormalSmoke и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleSmallFireStart()

void ParticleSmallFireStart ( )
protected
1147 {
1148 if (IsOven())
1149 {
1151 }
1152 else
1153 {
1155 }
1156 }
Particle m_ParticleSmallFire
Definition FireplaceBase.c:120
int PARTICLE_SMALL_FIRE
Definition FireplaceBase.c:108

Перекрестные ссылки GetFireEffectPosition(), IsOven(), m_ParticleSmallFire, PARTICLE_OVEN_FIRE, PARTICLE_SMALL_FIRE и PlayParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleSmallFireStop()

void ParticleSmallFireStop ( )
protected
1159 {
1161 }

Перекрестные ссылки m_ParticleSmallFire и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleSmallSmokeStart()

void ParticleSmallSmokeStart ( )
protected
1183 {
1185
1186 //calculate air resistance
1187 float actual_height;
1189 {
1191
1192 //alter smoke height
1194 }
1195
1196 if (IsRoofAbove() || !IsOpen() || IsOven())
1197 {
1199 }
1200 }
Particle m_ParticleSmallSmoke
Definition FireplaceBase.c:122
int PARTICLE_SMALL_SMOKE
Definition FireplaceBase.c:111

Перекрестные ссылки GetAirResistanceForSmokeParticles(), GetCeilingHeight(), FireplaceBase::GetSmokeEffectPosition(), FireplaceBase::IsOpen(), IsOven(), m_ParticleSmallSmoke, PARTICLE_SMALL_SMOKE, PlayParticle() и Particle::SetParameter().

◆ ParticleSmallSmokeStop()

void ParticleSmallSmokeStop ( )
protected
1203 {
1205 }

Перекрестные ссылки m_ParticleSmallSmoke и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleSteamEndStart()

void ParticleSteamEndStart ( )
protected
1276 {
1278 }
int PARTICLE_STEAM_END
Definition FireplaceBase.c:115
Particle m_ParticleSteamEnd
Definition FireplaceBase.c:125

Перекрестные ссылки GetFireEffectPosition(), m_ParticleSteamEnd, PARTICLE_STEAM_END и PlayParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleSteamEndStop()

void ParticleSteamEndStop ( )
protected
1281 {
1283 }

Перекрестные ссылки m_ParticleSteamEnd и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleSteamExtinguishingStart()

void ParticleSteamExtinguishingStart ( )
protected
1265 {
1267 }
int PARTICLE_STEAM_EXTINGUISHING
Definition FireplaceBase.c:116
Particle m_ParticleSteamExtinguishing
Definition FireplaceBase.c:126

Перекрестные ссылки GetFireEffectPosition(), m_ParticleSteamExtinguishing, PARTICLE_STEAM_EXTINGUISHING и PlayParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleSteamExtinguishingStop()

void ParticleSteamExtinguishingStop ( )
protected

Перекрестные ссылки m_ParticleSteamExtinguishing и StopParticle().

Используется в RefreshFireParticlesAndSounds().

◆ ParticleWetNoIgniteStart()

void ParticleWetNoIgniteStart ( )
protected

Перекрестные ссылки GetFireEffectPosition(), m_ParticleSteamEnd, PARTICLE_STEAM_END и PlayParticle().

Используется в OnRPC().

◆ ParticleWetNoIgniteStop()

void ParticleWetNoIgniteStop ( )
protected
1291 {
1293 }

Перекрестные ссылки m_ParticleSteamEnd и StopParticle().

◆ PlayParticle()

bool PlayParticle ( out Particle particle,
int particle_type,
vector pos,
bool worldpos = false )
protected
1095 {
1096 if (!particle && GetGame() && (!GetGame().IsDedicatedServer()))
1097 {
1098 if (!worldpos)
1099 {
1100 particle = ParticleManager.GetInstance().PlayOnObject(particle_type, this, pos);
1101 }
1102 else
1103 {
1104 particle = ParticleManager.GetInstance().PlayInWorld(particle_type, pos);
1105 }
1106
1107 return true;
1108 }
1109
1110 return false;
1111 }
void ParticleManager(ParticleManagerSettings settings)
Constructor (ctor)
Definition ParticleManager.c:84

Перекрестные ссылки GetGame() и ParticleManager().

◆ RefreshFireParticlesAndSounds()

void RefreshFireParticlesAndSounds ( bool force_refresh)
protected
853 {
855
857 {
858 switch (fire_state)
859 {
860 case FireplaceFireState.START_FIRE:
861 {
862 //particles
864
865 //sounds
868 break;
869 }
870 case FireplaceFireState.SMALL_FIRE:
871 {
872 //particles
874
876
877 if (CanShowSmoke())
879 else
881
884
886
887 //sounds
890 break;
891 }
892 case FireplaceFireState.NORMAL_FIRE:
893 {
894 //particles
896
899
901
902 if (CanShowSmoke())
904 else
906
908
909 //sounds
912 break;
913 }
914 case FireplaceFireState.END_FIRE:
915 {
916 //particles
918
921
924
926
927 //sounds
930 break;
931 }
932 case FireplaceFireState.EXTINGUISHING_FIRE: //TODO add steam particles when extinguishing
933 {
934 //particles
936
939
942
944
946
947 //sounds
950 break;
951 }
952 case FireplaceFireState.EXTINGUISHED_FIRE: //TODO add steam particles when fireplace is extinguished
953 {
954 //particles
956
959
962
964
966
967 if (CanShowSmoke())
969 else
971
972 //sounds
976 break;
977 }
978 case FireplaceFireState.REIGNITED_FIRE:
979 {
980 //particles
982
985
988
990
992
993 //sounds
995 break;
996 }
997 case FireplaceFireState.NO_FIRE:
998 {
999 //particles
1001
1004
1007
1009
1012
1013 //sounds
1014 SoundFireStop();
1015 break;
1016 }
1017 }
1018
1020 }
1021 }
void ParticleSteamExtinguishingStop()
Definition FireplaceBase.c:1269
void ParticleSmallFireStart()
Definition FireplaceBase.c:1146
void SoundFireLightStart()
Definition FireplaceBase.c:1339
void ParticleNormalFireStop()
Definition FireplaceBase.c:1176
void ParticleSteamEndStart()
Definition FireplaceBase.c:1275
void SoundFireExtinguishedStart()
Definition FireplaceBase.c:1354
void ParticleSteamExtinguishingStart()
Definition FireplaceBase.c:1264
void ParticleSmallSmokeStart()
Definition FireplaceBase.c:1182
void SoundFireHeavyStart()
Definition FireplaceBase.c:1344
FireplaceFireState m_LastFireState
Definition FireplaceBase.c:31
void ParticleNormalSmokeStop()
Definition FireplaceBase.c:1228
bool CanShowSmoke()
Definition FireplaceBase.c:1050
void ParticleFireStartStart()
Definition FireplaceBase.c:1128
void SoundFireExtinguishingStart()
Definition FireplaceBase.c:1364
void ParticleNormalFireStart()
Definition FireplaceBase.c:1164
void SoundFireNoFireStart()
Definition FireplaceBase.c:1349
void ParticleSmallSmokeStop()
Definition FireplaceBase.c:1202
void ParticleFireEndStart()
Definition FireplaceBase.c:1234
void ParticleFireEndStop()
Definition FireplaceBase.c:1246
void ParticleFireStartStop()
Definition FireplaceBase.c:1140
void ParticleSteamEndStop()
Definition FireplaceBase.c:1280
void ParticleSmallFireStop()
Definition FireplaceBase.c:1158
void ParticleNormalSmokeStart()
Definition FireplaceBase.c:1208

Перекрестные ссылки FireplaceBase::CanShowSmoke(), GetFireState(), m_LastFireState, ParticleFireEndStart(), ParticleFireEndStop(), ParticleFireStartStart(), ParticleFireStartStop(), ParticleNormalFireStart(), ParticleNormalFireStop(), FireplaceBase::ParticleNormalSmokeStart(), ParticleNormalSmokeStop(), ParticleSmallFireStart(), ParticleSmallFireStop(), FireplaceBase::ParticleSmallSmokeStart(), ParticleSmallSmokeStop(), ParticleSteamEndStart(), ParticleSteamEndStop(), ParticleSteamExtinguishingStart(), ParticleSteamExtinguishingStop(), SoundFireExtinguishedStart(), SoundFireExtinguishingStart(), SoundFireHeavyStart(), SoundFireLightStart(), SoundFireNoFireStart() и SoundFireStop().

Используется в OnVariablesSynchronized() и FireplaceBase::OnVariablesSynchronized().

◆ RefreshFireplacePhysics()

void RefreshFireplacePhysics ( )
protected

◆ RefreshFireplaceVisuals()

void RefreshFireplaceVisuals ( )
protected

single stone; everything else hidden

hide stones stack completely

668 {
669 if (IsHologram())
670 {
671 return;
672 }
673
674 // Light
675 #ifndef SERVER
676 if (IsBurning())
677 {
678 //turn light on
679 if (!GetLightEntity())
680 {
681 SetLightEntity(FireplaceLight.Cast(ScriptedLightBase.CreateLight(FireplaceLight, GetPosition(), 20)));
682 GetLightEntity().AttachOnMemoryPoint(this, "light");
683 }
684
685 if (GetLightEntity() && GetLightEntity().GetBrightness() > 0)
686 {
687 // change brightness based on the distance of player to the fireplace
688 Object player = GetGame().GetPlayer();
690
691 if (IsOven())
692 {
693 lightDist = 50;
694 }
695
696 if (player)
697 {
698 if (vector.DistanceSq(player.GetPosition(), this.GetPosition()) > lightDist * lightDist)
699 {
700 GetLightEntity().FadeBrightnessTo(0, 5);
701 }
702 else
703 {
704 GetLightEntity().FadeBrightnessTo(FireplaceLight.m_FireplaceBrightness, 5);
705 }
706 }
707
708 // The following solves an issue with the light point clipping through narrow geometry
710 {
711 GetLightEntity().SetInteriorMode();
712 }
713 else
714 {
715 GetLightEntity().SetExteriorMode();
716 }
717 }
718 }
719 else
720 {
721 //turn light off
722 if (GetLightEntity())
723 {
724 GetLightEntity().FadeOut();
725 }
726 }
727 #endif
728
729 //set default burn parameters based on fireplace type
731 {
733 }
734 else if (HasStoneCircle())
735 {
737 }
738 else
739 {
741 }
742
743 // Oven attachments
744 if (IsOven())
745 {
746 //lock attachment slots
748 {
750 }
751 }
752 else
753 {
754 //unlock attachment slots
756 {
757 LockOvenAttachments(false);
758 }
759 }
760
761 //VISUAL STATES
762 //Fuel state
763 if (GetGame().IsServer())
764 {
765 // Sticks state
767 SetAnimationPhase(ANIMATION_STICKS, 0);
768 else
769 SetAnimationPhase(ANIMATION_STICKS, 1);
770
771 // Firewood state
773 {
774 if (IsBurning() && HasAshes())
775 {
776 SetAnimationPhase(ANIMATION_BURNT_WOOD, 0); // Because this might not be set under certain circumstances
777 SetAnimationPhase(ANIMATION_WOOD, 1);
778 }
779 else if (IsWet() || !IsBurning())
780 {
781 SetAnimationPhase(ANIMATION_BURNT_WOOD, 1);
782 SetAnimationPhase(ANIMATION_WOOD, 0);
783 }
784 else
785 {
786 SetAnimationPhase(ANIMATION_BURNT_WOOD, 1);
787 SetAnimationPhase(ANIMATION_WOOD, 0);
788 }
789 }
790 else
791 {
792 SetAnimationPhase(ANIMATION_WOOD, 1);
793 SetAnimationPhase(ANIMATION_BURNT_WOOD, 1);
794 }
795
796 // Kindling state
797 if (GetKindlingCount() != 0)
798 SetAnimationPhase(ANIMATION_KINDLING, 0);
799 else
800 SetAnimationPhase(ANIMATION_KINDLING, 1);
801
802 // Ashes state
803 if (HasAshes())
804 SetAnimationPhase(ANIMATION_ASHES, 0);
805 else
806 SetAnimationPhase(ANIMATION_ASHES, 1);
807
808 // Stone variations
809 if (HasStones())
810 {
811 if (HasStoneCircle())
812 {
813 SetAnimationPhase(ANIMATION_STONES, 0);
814 SetAnimationPhase(ANIMATION_STONE, 1);
815 }
816 else if (IsOven())
817 {
818 SetAnimationPhase(ANIMATION_OVEN, 0);
819 SetAnimationPhase(ANIMATION_STONE, 1);
820 }
821 else
822 {
824 SetAnimationPhase(ANIMATION_STONES, 1);
825 SetAnimationPhase(ANIMATION_OVEN, 1);
826 SetAnimationPhase(ANIMATION_STONE, 0);
827 }
828 }
829 else
830 {
831 SetAnimationPhase(ANIMATION_STONE, 1);
832 }
833 }
834
835 //refresh physics (with delay)
837 }
const string ANIMATION_OVEN
Definition FireplaceBase.c:172
void LockOvenAttachments(bool lock)
Definition FireplaceBase.c:2647
bool IsBarrelWithHoles()
Definition FireplaceBase.c:555
float m_LightDistance
Definition FireplaceBase.c:97
FireplaceLight GetLightEntity()
Definition FireplaceBase.c:2524
const string ANIMATION_ASHES
Definition FireplaceBase.c:164
const string ANIMATION_STONES
Definition FireplaceBase.c:170
const float FUEL_BURN_RATE_OVEN
Definition FireplaceBase.c:68
bool IsWet()
Definition FireplaceBase.c:2358
bool IsIndoorOven()
Definition FireplaceBase.c:565
const string ANIMATION_WOOD
Definition FireplaceBase.c:167
const float FUEL_BURN_RATE_STONES
Definition FireplaceBase.c:67
const string ANIMATION_KINDLING
Definition FireplaceBase.c:165
const string ANIMATION_STICKS
Definition FireplaceBase.c:166
const string ANIMATION_STONE
Definition FireplaceBase.c:169
bool IsFireplaceIndoor()
Definition FireplaceBase.c:560
bool IsItemTypeAttached(typename item_type)
Definition FireplaceBase.c:1593
const string ANIMATION_BURNT_WOOD
Definition FireplaceBase.c:168
void SetLightEntity(FireplaceLight light)
Definition FireplaceBase.c:2529
override bool IsHologram()
Definition ItemBase.c:5760
Definition PointLightBase.c:2
static proto native float DistanceSq(vector v1, vector v2)
Returns the square distance between tips of two 3D vectors.

Перекрестные ссылки ANIMATION_ASHES, ANIMATION_BURNT_WOOD, ANIMATION_KINDLING, ANIMATION_OVEN, ANIMATION_STICKS, ANIMATION_STONE, ANIMATION_STONES, ANIMATION_WOOD, ATTACHMENT_FIREWOOD, ATTACHMENT_STICKS, ATTACHMENT_STONES, CALL_CATEGORY_GAMEPLAY, vector::DistanceSq(), FUEL_BURN_RATE_DEFAULT, FUEL_BURN_RATE_OVEN, FUEL_BURN_RATE_STONES, GetGame(), GetKindlingCount(), GetLightEntity(), GetPosition, HasAshes(), HasStoneCircle(), HasStones(), FireplaceBase::IsBarrelWithHoles(), IsBurning(), FireplaceBase::IsFireplaceIndoor(), IsHologram(), FireplaceBase::IsIndoorOven(), IsItemTypeAttached(), IsOven(), IsWet(), LockOvenAttachments(), m_LightDistance, m_OvenAttachmentsLockState, FireplaceBase::RefreshFireplacePhysics(), SetFuelBurnRateMP() и SetLightEntity().

Используется в EEInit(), FireplaceBase::EEItemAttached(), FireplaceBase::EEItemDetached(), OnVariablesSynchronized(), SetItemToConsume() и Synchronize().

◆ RefreshFireState()

void RefreshFireState ( )
protected
1057 {
1058 float temperature = GetTemperature();
1059
1060 //if it's burning
1061 if (IsBurning())
1062 {
1063 //Start fire
1065 {
1066 if (GetFireState() != FireplaceFireState.START_FIRE)
1067 {
1068 SetFireState(FireplaceFireState.START_FIRE);
1069 }
1070 }
1071 //Small fire
1073 {
1074 if (GetFireState() != FireplaceFireState.SMALL_FIRE)
1075 {
1076 SetFireState(FireplaceFireState.SMALL_FIRE);
1077 }
1078 }
1079 //Normal fire
1081 {
1082 if (GetFireState() != FireplaceFireState.NORMAL_FIRE)
1083 {
1084 SetFireState(FireplaceFireState.NORMAL_FIRE);
1085 }
1086 }
1087 }
1088 }

Перекрестные ссылки GetFireState(), IsBurning(), PARAM_MIN_FIRE_TEMPERATURE, PARAM_SMALL_FIRE_TEMPERATURE и SetFireState().

Используется в Heating().

◆ RemoveFromFireConsumables()

void RemoveFromFireConsumables ( FireConsumable fire_consumable)
protected
1412 {
1413 if (fire_consumable)
1414 {
1415 m_FireConsumables.Remove(fire_consumable.GetItem());
1416 delete fire_consumable;
1417 }
1418
1420 }

Перекрестные ссылки CalcAndSetQuantity() и m_FireConsumables.

Используется в FireplaceBase::EEItemDetached() и SpendFireConsumable().

◆ SetAshesState()

void SetAshesState ( bool has_ashes)
protected
1642 {
1644 }

Перекрестные ссылки m_HasAshes.

Используется в SpendFireConsumable().

◆ SetBurningState()

void SetBurningState ( bool is_burning)
protected
1630 {
1632 }

Перекрестные ссылки m_IsBurning.

Используется в StartFire() и StopFire().

◆ SetBurntFirewood()

void SetBurntFirewood ( )
protected

DEPRECATED.

841 {
842 if (GetGame().IsServer() && IsInAnimPhase(ANIMATION_WOOD))
843 {
844 SetAnimationPhase(ANIMATION_WOOD, 1);
845 SetAnimationPhase(ANIMATION_BURNT_WOOD, 0);
846 }
847 }
bool IsInAnimPhase(string anim_phase)
Definition FireplaceBase.c:2450

Перекрестные ссылки ANIMATION_BURNT_WOOD, ANIMATION_WOOD, GetGame() и IsInAnimPhase().

◆ SetCookingEquipment()

void SetCookingEquipment ( ItemBase equipment)
protected
601 {
603 }

Перекрестные ссылки m_CookingEquipment.

Используется в ItemBase::ClearCookingEquipment() и ItemBase::EEItemAttached().

◆ SetExtinguishingState()

void SetExtinguishingState ( )
protected
1726 {
1727 SetFireState(FireplaceFireState.EXTINGUISHING_FIRE);
1728 }

Перекрестные ссылки SetFireState().

◆ SetFireState()

void SetFireState ( FireplaceFireState state)
protected
1716 {
1717 if (m_FireState != state)
1718 {
1720
1721 Synchronize();
1722 }
1723 }

Перекрестные ссылки m_FireState и Synchronize().

Используется в EEDelete(), RefreshFireState(), SetExtinguishingState(), StopCooling() и StopFire().

◆ SetFuelBurnRateMP()

void SetFuelBurnRateMP ( float value)
protected
1704 {
1706 }

Перекрестные ссылки m_FuelBurnRateMP.

Используется в FireplaceBase() и RefreshFireplaceVisuals().

◆ SetIgniteFailure()

void SetIgniteFailure ( bool failure)
protected
2348 {
2350 }

Перекрестные ссылки m_NoIgnite.

Используется в FireplaceBase::IsThisIgnitionSuccessful().

◆ SetItemToConsume()

FireConsumable SetItemToConsume ( )
protected
1431 {
1432 if (m_FireConsumables.Count() == 0)
1433 {
1435 }
1436 else
1437 {
1438 for (int i = 0; i < m_FireConsumables.Count(); ++i)
1439 {
1440 ItemBase key = m_FireConsumables.GetKey(i);
1442
1443 if (i == 0)
1444 {
1446 }
1447 else
1448 {
1449 if (fireConsumable.GetEnergy() < m_ItemToConsume.GetEnergy())
1450 {
1452 }
1453 }
1454 }
1455 }
1456
1457 //refresh visual
1459
1460 return m_ItemToConsume;
1461 }

Перекрестные ссылки m_FireConsumables, m_ItemToConsume и RefreshFireplaceVisuals().

Используется в SpendFireConsumable() и StartFire().

◆ SetLightEntity()

void SetLightEntity ( FireplaceLight light)
protected
2530 {
2531 m_Light = light;
2532 }

Перекрестные ссылки m_Light.

Используется в RefreshFireplaceVisuals().

◆ SetOvenState()

void SetOvenState ( bool is_oven)
protected
1674 {
1675 if (m_IsOven != is_oven)
1676 {
1677 m_IsOven = is_oven;
1678
1679 GetInventory().SetSlotLock(InventorySlots.GetSlotIdFromString("Stones") , is_oven);
1680
1681 Synchronize();
1682 }
1683 }

Перекрестные ссылки InventorySlots::GetSlotIdFromString(), m_IsOven и Synchronize().

◆ SetStoneCircleState()

void SetStoneCircleState ( bool has_stonecircle)
protected
1686 {
1688 {
1690
1691 GetInventory().SetSlotLock(InventorySlots.GetSlotIdFromString("Stones") , has_stonecircle);
1692
1693 Synchronize();
1694 }
1695 }

Перекрестные ссылки InventorySlots::GetSlotIdFromString(), m_HasStoneCircle и Synchronize().

◆ SetTemperatureLossMP()

void SetTemperatureLossMP ( float value)
protected
2795 {
2797 }

Перекрестные ссылки m_TemperatureLossMP.

◆ SmokeOnSmokingSlot()

void SmokeOnSmokingSlot ( ItemBase slot_item,
float temp_equip,
float temp_ext )
protected
2132 {
2133 if (m_CookingProcess == NULL)
2134 m_CookingProcess = new Cooking();
2135
2136 // smoking slots accept only individual meat/fruit/veg items
2138 if (ingr)
2139 m_CookingProcess.SmokeItem(ingr, FireplaceBase.TIMER_HEATING_UPDATE_INTERVAL * FireplaceBase.SMOKING_SPEED);
2140 }
Definition Edible_Base.c:2

Перекрестные ссылки m_CookingProcess.

Используется в Cooling() и Heating().

◆ SmokingSlotsInUse()

bool SmokingSlotsInUse ( )
protected
634 {
635 for (int i = 0; i < SMOKING_SLOT_COUNT; i++)
636 {
637 if (m_SmokingSlots[i])
638 {
639 return true;
640 }
641 }
642 return false;
643 }

Перекрестные ссылки m_SmokingSlots и SMOKING_SLOT_COUNT.

Используется в CanDismantleOven(), FireplaceBase::CanPutIntoHands(), Cooling() и Heating().

◆ SoundFireExtinguishedStart()

void SoundFireExtinguishedStart ( )
protected
1355 {
1356 PlaySoundSet(m_SoundFire, SOUND_FIRE_EXTINGUISHED, 0.1, 0.1);
1357 }
const string SOUND_FIRE_EXTINGUISHED
Definition FireplaceBase.c:133
EffectSound m_SoundFire
Definition FireplaceBase.c:137

Перекрестные ссылки m_SoundFire и SOUND_FIRE_EXTINGUISHED.

Используется в RefreshFireParticlesAndSounds().

◆ SoundFireExtinguishingStart()

void SoundFireExtinguishingStart ( )
protected
1365 {
1366 PlaySoundSetLoop(m_SoundFireLoop, SOUND_FIRE_EXTINGUISHING, 1.0, 0.5);
1367 }
const string SOUND_FIRE_EXTINGUISHING
Definition FireplaceBase.c:132
EffectSound m_SoundFireLoop
Definition FireplaceBase.c:136

Перекрестные ссылки m_SoundFireLoop и SOUND_FIRE_EXTINGUISHING.

Используется в RefreshFireParticlesAndSounds().

◆ SoundFireHeavyStart()

void SoundFireHeavyStart ( )
protected
1345 {
1346 PlaySoundSetLoop(m_SoundFireLoop, SOUND_FIRE_HEAVY, 1.0, 2.0);
1347 }
const string SOUND_FIRE_HEAVY
Definition FireplaceBase.c:129

Перекрестные ссылки m_SoundFireLoop и SOUND_FIRE_HEAVY.

Используется в RefreshFireParticlesAndSounds().

◆ SoundFireLightStart()

void SoundFireLightStart ( )
protected
1340 {
1341 PlaySoundSetLoop(m_SoundFireLoop, SOUND_FIRE_LIGHT, 1.0, 1.0);
1342 }
const string SOUND_FIRE_LIGHT
Definition FireplaceBase.c:130

Перекрестные ссылки m_SoundFireLoop и SOUND_FIRE_LIGHT.

Используется в RefreshFireParticlesAndSounds().

◆ SoundFireNoFireStart()

void SoundFireNoFireStart ( )
protected
1350 {
1351 PlaySoundSetLoop(m_SoundFireLoop, SOUND_FIRE_NO_FIRE, 2.0, 2.0);
1352 }
const string SOUND_FIRE_NO_FIRE
Definition FireplaceBase.c:131

Перекрестные ссылки m_SoundFireLoop и SOUND_FIRE_NO_FIRE.

Используется в RefreshFireParticlesAndSounds().

◆ SoundFireStop()

void SoundFireStop ( )
protected
1376 {
1377 StopSoundSet(m_SoundFireLoop);
1378 }

Перекрестные ссылки m_SoundFireLoop.

Используется в OnRPC() и RefreshFireParticlesAndSounds().

◆ SoundFireWetNoIgniteStart()

void SoundFireWetNoIgniteStart ( )
protected
1360 {
1361 PlaySoundSet(m_SoundFire, SOUND_FIRE_EXTINGUISHED, 0.1, 0.1);
1362 }

Перекрестные ссылки m_SoundFire и SOUND_FIRE_EXTINGUISHED.

Используется в OnRPC().

◆ SoundFireWindyNoIgniteStart()

void SoundFireWindyNoIgniteStart ( )
protected
1370 {
1371 PlaySoundSet(m_SoundFire, "ExtinguishByWind_SoundSet", 0, 0);
1372 }

Перекрестные ссылки m_SoundFire.

Используется в OnRPC().

◆ SpendFireConsumable()

void SpendFireConsumable ( float amount)
protected
1473 {
1474 //spend item
1476
1477 if (!fireConsumable)
1478 {
1479 //Set new item to consume
1481 }
1482
1483 if (fireConsumable)
1484 {
1485 ItemBase item = fireConsumable.GetItem();
1486 fireConsumable.SetRemainingEnergy(fireConsumable.GetRemainingEnergy() - amount);
1487
1488 if (fireConsumable.GetRemainingEnergy() <= 0 || amount == 0)
1489 {
1490 //set ashes
1491 if (!HasAshes())
1492 {
1493 SetAshesState(true);
1494 }
1495
1496 if (item.IsAnyInherited({ItemBook, Paper, GiftWrapPaper, EyeMask_ColorBase}))
1497 {
1499 item.Delete();
1500 }
1501 else
1502 {
1503 //if there is nothing left, delete and remove old consumable, set new fire consumable
1504 if (item.GetQuantity() <= 1)
1505 {
1506 //remove item from fuel items
1508 }
1509 else
1510 {
1511 fireConsumable.SetRemainingEnergy(fireConsumable.GetEnergy());
1512 }
1513
1514 item.AddQuantity(-1);
1516 }
1517 }
1518 }
1519
1521 }
void RemoveFromFireConsumables(FireConsumable fire_consumable)
Definition FireplaceBase.c:1411
FireConsumable GetItemToConsume()
Definition FireplaceBase.c:1463
void SetAshesState(bool has_ashes)
Definition FireplaceBase.c:1641
FireConsumable SetItemToConsume()
Definition FireplaceBase.c:1430

Перекрестные ссылки CalcAndSetQuantity(), GetItemToConsume(), HasAshes(), RemoveFromFireConsumables(), SetAshesState() и SetItemToConsume().

Используется в Heating() и StopFire().

◆ StartCooling()

void StartCooling ( )
protected
1957 {
1958 if (m_HeatingTimer)
1959 {
1960 m_HeatingTimer.Stop();
1962 }
1963
1964 //Start cooling
1966 m_CoolingTimer.Run(TIMER_COOLING_UPDATE_INTERVAL, this, "Cooling", null, true);
1967 m_CookingProcess.SetCookingUpdateTime(TIMER_COOLING_UPDATE_INTERVAL);
1968 }
Definition DayZPlayerImplement.c:63

Перекрестные ссылки CALL_CATEGORY_GAMEPLAY, m_CookingProcess, m_CoolingTimer, m_HeatingTimer и TIMER_COOLING_UPDATE_INTERVAL.

Используется в StopFire().

◆ StartFire()

void StartFire ( bool force_start = false)
protected
1739 {
1740 //stop cooling process if active
1741 if (m_CoolingTimer)
1742 {
1743 m_CoolingTimer.Stop();
1745 }
1746
1747 //start fire
1748 if (!IsBurning() || force_start)
1749 {
1750 //roof check
1752
1754 SetBurningState(true);
1755 m_UTSource.SetActive(true);
1756 StartHeating();
1757
1758 //Update navmesh
1759 if (!IsFireplaceIndoor())
1760 {
1761 SetAffectPathgraph(false, true);
1762 GetGame().GetCallQueue(CALL_CATEGORY_SYSTEM).CallLater(GetGame().UpdatePathgraphRegionByObject, 100, false, this);
1763 }
1764 }
1765
1766 Synchronize();
1767 }
void StartHeating()
Definition FireplaceBase.c:1770
void SetBurningState(bool is_burning)
Definition FireplaceBase.c:1629
const int CALL_CATEGORY_SYSTEM
Definition tools.c:8

Перекрестные ссылки CALL_CATEGORY_SYSTEM, CheckForRoofLimited(), GetGame(), IsBurning(), FireplaceBase::IsFireplaceIndoor(), m_CoolingTimer, m_UTSource, SetBurningState(), SetItemToConsume(), StartHeating() и Synchronize().

Используется в AfterStoreLoad() и FireplaceBase::OnIgnitedThis().

◆ StartHeating()

void StartHeating ( )
protected
1771 {
1772 //visual
1773 SetObjectMaterial(0, MATERIAL_FIREPLACE_GLOW);
1774
1775 if (IsWindy() && !IsRoofAbove() && IsOpen() && !IsOven() && !IsBarrelWithHoles())
1776 {
1777 StopFire();
1778 return;
1779 }
1780
1782 {
1783 StopFire(FireplaceFireState.EXTINGUISHED_FIRE);
1784 return;
1785 }
1786
1787 //create area damage
1788 if (IsBaseFireplace() && !IsOven())
1790
1792 m_HeatingTimer.Run(TIMER_HEATING_UPDATE_INTERVAL, this, "Heating", null, true);
1793 m_CookingProcess.SetCookingUpdateTime(TIMER_HEATING_UPDATE_INTERVAL);
1794
1795 //Setup the noise parameters on fire start
1796 m_NoisePar = new NoiseParams();
1797 if (IsRoofAbove() || IsOven() || IsFireplaceIndoor()) //If we have a roof, we are probably inside
1798 m_NoisePar.LoadFromPath("CfgVehicles FireplaceBase NoiseFireplaceSpecial");
1799 else
1800 m_NoisePar.LoadFromPath("CfgVehicles FireplaceBase NoiseFireplaceBase");
1801 }
const string MATERIAL_FIREPLACE_GLOW
Definition FireplaceBase.c:179
static bool IsWindy()
Definition FireplaceBase.c:2333
class NoiseSystem NoiseParams()
Definition Noise.c:15

Перекрестные ссылки CALL_CATEGORY_GAMEPLAY, FireplaceBase::CreateAreaDamage(), GetWet(), FireplaceBase::IsBarrelWithHoles(), FireplaceBase::IsBaseFireplace(), FireplaceBase::IsFireplaceIndoor(), FireplaceBase::IsOpen(), IsOven(), IsWindy(), m_CookingProcess, m_HeatingTimer, m_NoisePar, MATERIAL_FIREPLACE_GLOW, NoiseParams(), PARAM_BURN_WET_THRESHOLD, StopFire() и TIMER_HEATING_UPDATE_INTERVAL.

Используется в StartFire().

◆ StopAllParticlesAndSounds()

void StopAllParticlesAndSounds ( )
protected

◆ StopCooling()

void StopCooling ( )
protected
2062 {
2063 //stop all fire visuals
2065 SetObjectMaterial(0, MATERIAL_FIREPLACE_NOGLOW);
2066
2067 //Stop cooling
2068 m_CoolingTimer.Stop();
2070
2071 //destroy area damage
2073
2074 //remove cookware audio visuals
2075 if (GetCookingEquipment())
2076 {
2078 if (cooking_pot)
2079 cooking_pot.RemoveAudioVisualsOnClient();
2080 }
2081
2083 {
2084 for (int i = 0; i < DIRECT_COOKING_SLOT_COUNT; i++)
2085 {
2087 {
2089 if (cookingpot)
2090 cookingpot.RemoveAudioVisualsOnClient();
2091
2093 if (fryingpan)
2094 fryingpan.RemoveAudioVisualsOnClient();
2095
2097 if (itsfood)
2098 itsfood.MakeSoundsOnClient(false);
2099 }
2100 }
2101 }
2102 }
ItemBase GetCookingEquipment()
Definition FireplaceBase.c:595
const string MATERIAL_FIREPLACE_NOGLOW
Definition FireplaceBase.c:180
Definition Canteen.c:2
Definition FryingPan.c:2

Перекрестные ссылки DestroyAreaDamage(), DIRECT_COOKING_SLOT_COUNT, DirectCookingSlotsInUse(), GetCookingEquipment(), m_CoolingTimer, m_DirectCookingSlots, MATERIAL_FIREPLACE_NOGLOW и SetFireState().

Используется в Cooling().

◆ StopFire()

void StopFire ( FireplaceFireState fire_state = FireplaceFireState.END_FIRE)
protected
1926 {
1927 //roof check
1928 if (IsBurning())
1930
1931 StopHeating();
1933 SetBurningState(false);
1934 StartCooling();
1936
1937 //Update navmesh
1938 if (!IsFireplaceIndoor())
1939 {
1940 SetAffectPathgraph(false, false);
1941 GetGame().GetCallQueue(CALL_CATEGORY_SYSTEM).CallLater(GetGame().UpdatePathgraphRegionByObject, 100, false, this);
1942 }
1943
1944 Synchronize();
1945 }
void StartCooling()
Definition FireplaceBase.c:1956
void StopHeating()
Definition FireplaceBase.c:1947

Перекрестные ссылки CALL_CATEGORY_SYSTEM, CheckForRoofLimited(), GetGame(), IsBurning(), FireplaceBase::IsFireplaceIndoor(), SetBurningState(), SetFireState(), SpendFireConsumable(), StartCooling(), StopHeating() и Synchronize().

Используется в Heating(), OnAction() и StartHeating().

◆ StopHeating()

void StopHeating ( )
protected
1948 {
1949 if (!m_HeatingTimer)
1950 return;
1951
1952 m_HeatingTimer.Stop();
1954 }

Перекрестные ссылки m_HeatingTimer.

Используется в StopFire().

◆ StopParticle()

bool StopParticle ( out Particle particle)
protected
1115 {
1116 if (particle && GetGame() && (!GetGame().IsDedicatedServer()))
1117 {
1118 particle.Stop();
1119 particle = NULL;
1120
1121 return true;
1122 }
1123
1124 return false;
1125 }

Перекрестные ссылки GetGame().

◆ Synchronize()

void Synchronize ( )
protected
498 {
499 if (GetGame() && GetGame().IsServer())
500 {
501 SetSynchDirty();
502
503 if (GetGame().IsMultiplayer() && GetGame().IsServer())
504 {
505 //Refresh visuals (on server)
507 }
508 }
509 }

Перекрестные ссылки CALL_CATEGORY_GAMEPLAY, GetGame() и RefreshFireplaceVisuals().

◆ TransferHeatToNearPlayers()

void TransferHeatToNearPlayers ( )
protected

DEPRECATED.

2287{}

◆ ~FireplaceBase()

Переменные

◆ ANIMATION_ASHES

const string ANIMATION_ASHES = "Ashes"
protected

Используется в RefreshFireplaceVisuals().

◆ ANIMATION_BURNT_WOOD

const string ANIMATION_BURNT_WOOD = "BurntWood"
protected

Используется в RefreshFireplaceVisuals() и SetBurntFirewood().

◆ ANIMATION_CAULDRON_HANDLE

const string ANIMATION_CAULDRON_HANDLE = "handle1Rotate"
protected

◆ ANIMATION_COOKWARE_HANDLE

const string ANIMATION_COOKWARE_HANDLE = "handleRotate"
protected

◆ ANIMATION_INVENTORY

const string ANIMATION_INVENTORY = "Inventory"
protected

◆ ANIMATION_KINDLING

const string ANIMATION_KINDLING = "Kindling"
protected

Используется в RefreshFireplaceVisuals().

◆ ANIMATION_OVEN

const string ANIMATION_OVEN = "Oven"
protected

◆ ANIMATION_STICKS

const string ANIMATION_STICKS = "Sticks"
protected

Используется в RefreshFireplaceVisuals().

◆ ANIMATION_STONE

const string ANIMATION_STONE = "Stone"
protected

Используется в RefreshFireplaceVisuals().

◆ ANIMATION_STONES

const string ANIMATION_STONES = "StonesCircle"
protected

Используется в RefreshFireplaceVisuals().

◆ ANIMATION_TRIPOD

const string ANIMATION_TRIPOD = "Tripod"
protected

Используется в FireplaceBase::RefreshPhysics().

◆ ANIMATION_WOOD

const string ANIMATION_WOOD = "Wood"
protected

Используется в RefreshFireplaceVisuals() и SetBurntFirewood().

◆ ATTACHMENT_BANDAGE

ATTACHMENT_BANDAGE = BandageDressing
protected

Используется в FireplaceBase().

◆ ATTACHMENT_BARK_BIRCH

ATTACHMENT_BARK_BIRCH = Bark_Birch
protected

Используется в FireplaceBase().

◆ ATTACHMENT_BARK_OAK

ATTACHMENT_BARK_OAK = Bark_Oak
protected

Используется в FireplaceBase().

◆ ATTACHMENT_BOOK

ATTACHMENT_BOOK = ItemBook
protected

Используется в FireplaceBase().

◆ ATTACHMENT_CAULDRON

◆ ATTACHMENT_COOKING_POT

◆ ATTACHMENT_COOKINGSTAND

ATTACHMENT_COOKINGSTAND = CookingStand
protected

Используется в AddDamageToItemByFireEx() и OnAttachmentRuined().

◆ ATTACHMENT_EYEMASK_COLORBASE

ATTACHMENT_EYEMASK_COLORBASE = EyeMask_ColorBase
protected

Используется в FireplaceBase().

◆ ATTACHMENT_FIREWOOD

ATTACHMENT_FIREWOOD = Firewood
protected

Используется в FireplaceBase() и RefreshFireplaceVisuals().

◆ ATTACHMENT_FRYING_PAN

◆ ATTACHMENT_GIFTWRAP

ATTACHMENT_GIFTWRAP = GiftWrapPaper
protected

Используется в FireplaceBase().

◆ ATTACHMENT_PAPER

ATTACHMENT_PAPER = Paper
protected

Используется в FireplaceBase().

◆ ATTACHMENT_PUNCHEDCARD

ATTACHMENT_PUNCHEDCARD = PunchedCard
protected

Используется в FireplaceBase().

◆ ATTACHMENT_RAGS

ATTACHMENT_RAGS = Rag
protected

Используется в FireplaceBase().

◆ ATTACHMENT_STICKS

ATTACHMENT_STICKS = WoodenStick
protected

Используется в FireplaceBase() и RefreshFireplaceVisuals().

◆ ATTACHMENT_STONES

◆ ATTACHMENT_TRIPOD

◆ DIRECT_COOKING_SLOT_COUNT

const int DIRECT_COOKING_SLOT_COUNT = 3
protected

direct cooking slots

update interval duration of cooling process (seconds)

Используется в Cooling(), DirectCookingSlotsInUse(), Heating() и StopCooling().

◆ DIRECT_COOKING_SPEED

const float DIRECT_COOKING_SPEED = 1.5
protected

how much will temperature increase when attached on burning fireplace (degree Celsius)

◆ FUEL_BURN_RATE_DEFAULT

const float FUEL_BURN_RATE_DEFAULT = 1.0
protected

min height of ceiling for fire to be ignited

Используется в FireplaceBase() и RefreshFireplaceVisuals().

◆ FUEL_BURN_RATE_OVEN

const float FUEL_BURN_RATE_OVEN = 0.85
protected

Используется в RefreshFireplaceVisuals().

◆ FUEL_BURN_RATE_STONES

const float FUEL_BURN_RATE_STONES = 0.92
protected

Используется в RefreshFireplaceVisuals().

◆ IGNITE_WIND_THRESHOLD

const float IGNITE_WIND_THRESHOLD = 0.8
protected

◆ LIFETIME_FIREPLACE_STONE_CIRCLE

const int LIFETIME_FIREPLACE_STONE_CIRCLE = 172800
protected

◆ LIFETIME_FIREPLACE_STONE_OVEN

const int LIFETIME_FIREPLACE_STONE_OVEN = 604800
protected

◆ m_AreaDamage

◆ m_CanNoise

bool m_CanNoise = true
private

Используется в Heating().

◆ m_ClutterCutter

◆ m_CookingEquipment

◆ m_CookingProcess

◆ m_CoolingTimer

◆ m_DirectCookingSlots

◆ m_FireConsumables

◆ m_FireConsumableTypes

ref map<typename, ref FireConsumableType> m_FireConsumableTypes
staticprotected

◆ m_FireState

Используется в GetFireState() и SetFireState().

◆ m_FuelBurnRateMP

float m_FuelBurnRateMP = 1.0
protected

◆ m_HalfExtents

vector m_HalfExtents
protected

◆ m_HasAshes

bool m_HasAshes = false
protected

Используется в HasAshes(), OnStoreLoad(), OnStoreSave() и SetAshesState().

◆ m_HasStoneCircle

bool m_HasStoneCircle = false
protected

◆ m_HeatingTimer

ref Timer m_HeatingTimer
protected

value for calculating of wetness that fireplace gain when raining

Используется в AddDamageToItemByFireEx(), AddTemperatureToItemByFire(), StartCooling(), StartHeating() и StopHeating().

◆ m_IsBurning

◆ m_IsOven

bool m_IsOven = false
protected

◆ m_ItemToConsume

ref FireConsumable m_ItemToConsume
protected

Используется в GetItemToConsume() и SetItemToConsume().

◆ m_LastFireState

FireplaceFireState m_LastFireState = FireplaceFireState.NO_FIRE
protected

Используется в RefreshFireParticlesAndSounds().

◆ m_Light

FireplaceLight m_Light
protected

◆ m_LightDistance

◆ m_NoIgnite

bool m_NoIgnite = false
protected

Используется в GetIgniteFailure() и SetIgniteFailure().

◆ m_NoisePar

ref NoiseParams m_NoisePar
protected

◆ m_OvenAttachmentsLockState

int m_OvenAttachmentsLockState = -1
protected

Используется в LockOvenAttachments() и RefreshFireplaceVisuals().

◆ m_ParticleFireEnd

◆ m_ParticleFireStart

Particle m_ParticleFireStart
protected

◆ m_ParticleNormalFire

Particle m_ParticleNormalFire
protected

◆ m_ParticleNormalSmoke

◆ m_ParticleSmallFire

Particle m_ParticleSmallFire
protected

◆ m_ParticleSmallSmoke

◆ m_ParticleSteamEnd

◆ m_ParticleSteamExtinguishing

Particle m_ParticleSteamExtinguishing
protected

◆ m_SmokingSlots

◆ m_SoundFire

◆ m_SoundFireLoop

◆ m_TemperatureLossMP

float m_TemperatureLossMP = 1.0
protected

value for calculating of wetness that fireplace gain when raining

Используется в GetTemperatureLossMP(), OnStoreLoad() и SetTemperatureLossMP().

◆ m_ThawnSurfaceUnderSupport

bool m_ThawnSurfaceUnderSupport
protected

size of wetness increment (per FP heating tick) added to overall FP wetness when ignited on wet surface

Используется в FireplaceBase::BarrelHoles_ColorBase(), EEInit(), FireplaceBase::Fireplace(), OnItemLocationChanged(), OnVariablesSynchronized() и ~FireplaceBase().

◆ m_TotalEnergy

float m_TotalEnergy
protected

Используется в CalcAndSetQuantity() и CalcAndSetTotalEnergy().

◆ m_UnderObjectDecalSpawnComponent

ref UnderObjectDecalSpawnComponent m_UnderObjectDecalSpawnComponent
protected

◆ m_UnderObjectDecalSpawnSettings

ref UnderObjectDecalSpawnSettings m_UnderObjectDecalSpawnSettings
protected

◆ m_UTSLFireplace

◆ m_UTSource

◆ m_UTSSettings

◆ MATERIAL_FIREPLACE_GLOW

const string MATERIAL_FIREPLACE_GLOW = "dz\\gear\\cooking\\data\\stoneground.rvmat"
protected

Используется в StartHeating().

◆ MATERIAL_FIREPLACE_NOGLOW

const string MATERIAL_FIREPLACE_NOGLOW = "dz\\gear\\cooking\\data\\stonegroundnoemit.rvmat"
protected

Используется в StopCooling().

◆ MAX_TEMPERATURE_TO_DISMANTLE_OVEN

const int MAX_TEMPERATURE_TO_DISMANTLE_OVEN = 40
protected

minimum amount of stones for oven

Используется в CanDismantleOven().

◆ MESSAGE_BURY_ASHES_FAILED_BURNING

const string MESSAGE_BURY_ASHES_FAILED_BURNING = "Cannot bury ashes, the fireplace is still burning."
protected

◆ MESSAGE_BURY_ASHES_FAILED_NOT_EMPTY

const string MESSAGE_BURY_ASHES_FAILED_NOT_EMPTY = "Cannot bury ashes. There are sill items in it."
protected

◆ MESSAGE_BURY_ASHES_FAILED_SURFACE

const string MESSAGE_BURY_ASHES_FAILED_SURFACE = "Cannot bury ashes on hard surface."
protected

◆ MESSAGE_BURY_ASHES_FAILED_TOO_HOT

const string MESSAGE_BURY_ASHES_FAILED_TOO_HOT = "Cannot bury ashes, the fireplace is too hot."
protected

◆ MESSAGE_CANNOT_BUILD_OVEN

const string MESSAGE_CANNOT_BUILD_OVEN = "Cannot build oven."
protected

◆ MESSAGE_CANNOT_DISMANTLE_OVEN

const string MESSAGE_CANNOT_DISMANTLE_OVEN = "Cannot dismantle oven."
protected

◆ MESSAGE_IGNITE_IGNIT_ITEM_DAMAGED

const string MESSAGE_IGNITE_IGNIT_ITEM_DAMAGED = "You cannot start fire. Fireplace is ruined."
protected

◆ MESSAGE_IGNITE_IN_WATER

const string MESSAGE_IGNITE_IN_WATER = "I cannot ignite the fireplace in the water."
protected

◆ MESSAGE_IGNITE_NO_KINDLING

const string MESSAGE_IGNITE_NO_KINDLING = "There needs to be some kindling to start a fire."
protected

◆ MESSAGE_IGNITE_RAIN

const string MESSAGE_IGNITE_RAIN = "The fire went out because of the rain."
protected

◆ MESSAGE_IGNITE_TOO_WET

const string MESSAGE_IGNITE_TOO_WET = "The fireplace is too wet to be ignited."
protected

◆ MESSAGE_IGNITE_UNDER_LOW_ROOF

const string MESSAGE_IGNITE_UNDER_LOW_ROOF = "I cannot ignite the fireplace here, the is not enough room."
protected

◆ MESSAGE_IGNITE_WIND

const string MESSAGE_IGNITE_WIND = "The fire went out because of the wind."
protected

◆ MESSAGE_REIGNITE_NO_KINDLING

const string MESSAGE_REIGNITE_NO_KINDLING = "There needs to be some kindling to start a fire."
protected

◆ MESSAGE_REIGNITE_RAIN

const string MESSAGE_REIGNITE_RAIN = "Cannot reignite fireplace in rain."
protected

◆ MESSAGE_REIGNITE_TOO_WET

const string MESSAGE_REIGNITE_TOO_WET = "The fireplace is too wet to be reignited."
protected

◆ MIN_CEILING_HEIGHT

const float MIN_CEILING_HEIGHT = 5
protected

maximum temperature for dismantling oven

Используется в GetCeilingHeight().

◆ MIN_STONES_TO_BUILD_CIRCLE

const int MIN_STONES_TO_BUILD_CIRCLE = 8
protected

maximum value for temperature that will be transfered to player (environment)

Используется в CanBuildStoneCircle().

◆ MIN_STONES_TO_BUILD_OVEN

const int MIN_STONES_TO_BUILD_OVEN = 16
protected

minimum amount of stones for circle

Используется в CanBuildOven().

◆ OBJECT_CLUTTER_CUTTER

const string OBJECT_CLUTTER_CUTTER = "ClutterCutterFireplace"
protected

◆ PARAM_BURN_DAMAGE_COEF

const float PARAM_BURN_DAMAGE_COEF = 5.0
protected

base value of fire consumption rate (how many base energy will be spent on each update)

◆ PARAM_BURN_WET_THRESHOLD

const float PARAM_BURN_WET_THRESHOLD = 0.40
protected

maximum rain value when the fireplace can be ignited

Используется в Heating() и StartHeating().

◆ PARAM_COOKING_EQUIP_MAX_TEMP

const float PARAM_COOKING_EQUIP_MAX_TEMP = 250
protected

Используется в ItemBase::OnWork().

◆ PARAM_COOKING_EQUIP_TEMP_INCREASE

const float PARAM_COOKING_EQUIP_TEMP_INCREASE = 10
protected

maximum temperature of attached cooking equipment (degree Celsius)

◆ PARAM_COOKING_TEMP_THRESHOLD

const float PARAM_COOKING_TEMP_THRESHOLD = 100
protected

cooking

Используется в CanCookOnStick() и Cooling().

◆ PARAM_FIRE_CONSUM_RATE_AMOUNT

const float PARAM_FIRE_CONSUM_RATE_AMOUNT = 0.5
protected

value for calculating wetness loss during cooling process

Используется в Heating().

◆ PARAM_FULL_HEAT_RADIUS

const float PARAM_FULL_HEAT_RADIUS = 2.0
protected

value for calculating damage on items located in fireplace cargo

Используется в BuildingSuper::EEInit() и FireplaceBase().

◆ PARAM_HEAT_RADIUS

const float PARAM_HEAT_RADIUS = 4.0
protected

radius in which objects are fully heated by fire

Используется в BuildingSuper::EEInit() и FireplaceBase().

◆ PARAM_HEAT_THROUGH_AIR_COEF

const float PARAM_HEAT_THROUGH_AIR_COEF = 0.1
protected

maximum value of temperature of items in fireplace when heating (degree Celsius)

◆ PARAM_IGNITE_RAIN_THRESHOLD

const float PARAM_IGNITE_RAIN_THRESHOLD = 0.1
protected

minimum fireplace temperature under which the fireplace can be reignited using air only (degree Celsius)

◆ PARAM_ITEM_HEAT_MIN_TEMP

const float PARAM_ITEM_HEAT_MIN_TEMP = 40
protected

◆ PARAM_ITEM_HEAT_TEMP_HEATING_COEF

const float PARAM_ITEM_HEAT_TEMP_HEATING_COEF = 1.0
protected

value for calculating temperature increase on each heat update interval (degree Celsius)

◆ PARAM_ITEM_HEAT_TEMP_INCREASE_COEF

const float PARAM_ITEM_HEAT_TEMP_INCREASE_COEF = 10
protected

DEPRECATED.

◆ PARAM_MAX_ITEM_HEAT_TEMP_INCREASE

const float PARAM_MAX_ITEM_HEAT_TEMP_INCREASE = 200
protected

multiplies temperature change on heating

◆ PARAM_MAX_TRANSFERED_TEMPERATURE

const float PARAM_MAX_TRANSFERED_TEMPERATURE = 20
protected

radius in which objects are heated by fire

Используется в BuildingSuper::EEInit() и FireplaceBase().

◆ PARAM_MAX_WET_TO_IGNITE

const float PARAM_MAX_WET_TO_IGNITE = 0.2
protected

how much will temperature decrease when fireplace is cooling (degree Celsius per second)

◆ PARAM_MIN_FIRE_TEMPERATURE

const float PARAM_MIN_FIRE_TEMPERATURE = 30
protected

maximum fireplace temperature of an outdoor fire (degree Celsius)

Используется в AddWetnessToFireplace() и RefreshFireState().

◆ PARAM_MIN_TEMP_TO_REIGNITE

const float PARAM_MIN_TEMP_TO_REIGNITE = 30
protected

maximum wetness value when the fireplace can be ignited

◆ PARAM_NORMAL_FIRE_TEMPERATURE

const float PARAM_NORMAL_FIRE_TEMPERATURE = 1000
protected

maximum fireplace temperature of a small fire (degree Celsius)

Используется в AddWetnessToFireplace(), FireplaceBase() и InitializeTemperatureSources().

◆ PARAM_OUTDOOR_FIRE_TEMPERATURE

const float PARAM_OUTDOOR_FIRE_TEMPERATURE = 500
protected

maximum fireplace temperature of a normal fire (degree Celsius)

Используется в FireplaceBase::BarrelHoles_ColorBase(), FireplaceBase::Fireplace() и FireplaceBase::InitializeTemperatureSources().

◆ PARAM_SMALL_FIRE_TEMPERATURE

const float PARAM_SMALL_FIRE_TEMPERATURE = 150
protected

◆ PARAM_TEMPERATURE_DECREASE

const float PARAM_TEMPERATURE_DECREASE = 10
protected

how much will temperature increase when fireplace is burning (degree Celsius per second)

Используется в Cooling() и Heating().

◆ PARAM_TEMPERATURE_INCREASE

const float PARAM_TEMPERATURE_INCREASE = 10
protected

minimum fireplace temperature under which the fireplace is inactive (degree Celsius)

Используется в Heating().

◆ PARAM_WET_COOLING_DECREASE_COEF

const float PARAM_WET_COOLING_DECREASE_COEF = 0.002
protected

value for calculating wetness loss during heating process

Используется в Cooling().

◆ PARAM_WET_HEATING_DECREASE_COEF

const float PARAM_WET_HEATING_DECREASE_COEF = 0.01
protected

maximum wetness value when the fireplace is able to burn

Используется в BurnItemsInFireplace() и Heating().

◆ PARAM_WET_INCREASE_COEF

const float PARAM_WET_INCREASE_COEF = 0.02
protected

◆ PARTICLE_FIRE_END

◆ PARTICLE_FIRE_START

◆ PARTICLE_NO_IGNITE_WIND

int PARTICLE_NO_IGNITE_WIND = ParticleList.CAMP_NO_IGNITE_WIND
protected

Используется в ParticleFireWindyNoIgniteStart().

◆ PARTICLE_NORMAL_FIRE

◆ PARTICLE_NORMAL_SMOKE

◆ PARTICLE_OVEN_FIRE

int PARTICLE_OVEN_FIRE = ParticleList.CAMP_STOVE_FIRE
protected

Используется в ParticleNormalFireStart() и ParticleSmallFireStart().

◆ PARTICLE_OVEN_FIRE_END

int PARTICLE_OVEN_FIRE_END = ParticleList.CAMP_STOVE_FIRE_END
protected

◆ PARTICLE_OVEN_FIRE_START

int PARTICLE_OVEN_FIRE_START = ParticleList.CAMP_STOVE_FIRE_START
protected

Используется в ParticleFireStartStart().

◆ PARTICLE_SMALL_FIRE

◆ PARTICLE_SMALL_SMOKE

◆ PARTICLE_STEAM_END

◆ PARTICLE_STEAM_EXTINGUISHING

int PARTICLE_STEAM_EXTINGUISHING = ParticleList.CAMP_STEAM_EXTINGUISH_START
protected

Используется в ParticleSteamExtinguishingStart().

◆ RAIN_EFFECT_LIMIT

const float RAIN_EFFECT_LIMIT = 0.4
protected

Используется в Cooling() и Heating().

◆ RAIN_WETNESS_INCREASE

const float RAIN_WETNESS_INCREASE = 0.02
protected

snowfall level that triggers fireplace to start soaking

Используется в Cooling() и Heating().

◆ SMOKING_SLOT_COUNT

const int SMOKING_SLOT_COUNT = 4
protected

Используется в Cooling(), Heating() и SmokingSlotsInUse().

◆ SMOKING_SPEED

const float SMOKING_SPEED = 1
protected

◆ SNOWFALL_EFFECT_LIMIT

const float SNOWFALL_EFFECT_LIMIT = 1.3
protected

rain level that triggers fireplace to start soaking

Используется в Cooling() и Heating().

◆ SNOWFALL_WETNESS_INCREASE

const float SNOWFALL_WETNESS_INCREASE = 0.01
protected

value for calculating of wetness that fireplace gain when raining

Используется в Cooling() и Heating().

◆ SOUND_FIRE_EXTINGUISHED

const string SOUND_FIRE_EXTINGUISHED = "ExtinguishByWaterEnd_SoundSet"
protected

◆ SOUND_FIRE_EXTINGUISHING

const string SOUND_FIRE_EXTINGUISHING = "ExtinguishByWater_SoundSet"
protected

Используется в SoundFireExtinguishingStart().

◆ SOUND_FIRE_HEAVY

const string SOUND_FIRE_HEAVY = "HeavyFire_SoundSet"
protected

Используется в SoundFireHeavyStart().

◆ SOUND_FIRE_LIGHT

const string SOUND_FIRE_LIGHT = "LightFire_SoundSet"
protected

Используется в SoundFireLightStart().

◆ SOUND_FIRE_NO_FIRE

const string SOUND_FIRE_NO_FIRE = "NoFuelFire_SoundSet"
protected

Используется в SoundFireNoFireStart().

◆ TEMPERATURE_LOSS_MP_DEFAULT

const float TEMPERATURE_LOSS_MP_DEFAULT = 1.0
protected

DEPRECATED value for calculation of heat transfered from fireplace through air to player (environment)

◆ TEMPERATURE_LOSS_MP_OVEN

const float TEMPERATURE_LOSS_MP_OVEN = 0.75
protected

◆ TEMPERATURE_LOSS_MP_STONES

const float TEMPERATURE_LOSS_MP_STONES = 0.90
protected

◆ TIMER_COOLING_UPDATE_INTERVAL

const int TIMER_COOLING_UPDATE_INTERVAL = 3
protected

update interval duration of heating process (seconds)

Используется в AddDamageToItemByFireEx(), AddTemperatureToItemByFire(), Cooling() и StartCooling().

◆ TIMER_HEATING_UPDATE_INTERVAL

const int TIMER_HEATING_UPDATE_INTERVAL = 3
protected

timer constants

temperature threshold for starting coooking process (degree Celsius)

Используется в AddDamageToItemByFireEx(), Cooling(), BuildingSuper::EEInit(), Heating() и StartHeating().

◆ WET

◆ WET_SURFACE_INCREMENT

const float WET_SURFACE_INCREMENT = 0.06
protected

Используется в Heating().

◆ WIND