DayZ 1.28
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ DrugsAttack()

void PlayerAgentPool::DrugsAttack ( EMedicalDrugsType drugType,
float attackValue )
inlineprotected

Drugs treatment logic.

Аргументы
drugTypeType of drug used (see EMedicalDrugsType enum)
attack_valueStrength of the drug attack

См. определение в файле PlayerAgentPool.c строка 341

342 {
343 switch (drugType)
344 {
345 case EMedicalDrugsType.ANTIBIOTICS:
346 AntibioticsAttack(attackValue);
347 break;
348 default:
349 for (int i = 0; i < m_VirusPool.Count(); ++i)
350 {
351 int agentId = m_VirusPool.GetKey(i);
352 float actualAgentCount = m_VirusPool.Get(agentId);
353 float newAgentCount = actualAgentCount - attackValue;
354 SetAgentCount(agentId, newAgentCount);
355 }
356 }
357 }
EMedicalDrugsType
Определения EMedicalDrugsType.c:2
ref map< int, float > m_VirusPool
Определения PlayerAgentPool.c:17
void AntibioticsAttack(float attack_value)
Antibiotics treatment agains agents which are not resistent to it (see agent attributes)
Определения PlayerAgentPool.c:323
void SetAgentCount(int agent_id, float count)
Directly set the count of agents for give id in pool.
Определения PlayerAgentPool.c:297

Перекрестные ссылки AntibioticsAttack(), m_VirusPool и SetAgentCount().