Process transmission of agents between entities (for specified transmission type)
307 {
308
309 int sourceAgents = agents;
310 int targetAgents;
311
312 if (!sourceAgents && source)
313 sourceAgents = source.GetAgents();
314
315 if (target)
316 targetAgents = target.GetAgents();
317
318 int pollution =
g_Game.GetMission().GetWorldData().GetPollution();
319
320 float count = 0;
321
322 switch (pathway)
323 {
325 break;
326
328 break;
329
331
332 break;
333
335 if (pollution & EPollution.HEAVYMETAL)
336 {
337 sourceAgents = sourceAgents |
eAgents.HEAVYMETAL;
338 }
339 sourceAgents = sourceAgents |
eAgents.CHOLERA;
341 break;
342
344 sourceAgents = sourceAgents |
eAgents.FOOD_POISON |
eAgents.HEAVYMETAL;
346 break;
347
349 if (pollution & EPollution.HEAVYMETAL)
350 {
351 sourceAgents = sourceAgents |
eAgents.HEAVYMETAL;
352 }
354 break;
355
357
359 break;
360
363 break;
364
367 break;
368
371 break;
372
375 break;
376
378 Man manTarget = Man.Cast(target);
379 Man manSource = Man.Cast(source);
383 manTarget,
384 );
388 manSource,
389 );
393 manTarget,
394 );
398 manSource,
399 );
400 float targetProtection = Math.Max(targetMaskProtection, targetHeadgearProtection);
401 float sourceProtection = Math.Max(sourceMaskProtection, sourceHeadgearProtection);
402 float combinedProtection = 1 - (1 - targetProtection) * (1 - sourceProtection);
404 break;
409 Man.Cast(target),
410 );
411
413 break;
415 switch (sourceAgents)
416 {
417 float protectionLevel = 0.0;
418 Man man = Man.Cast(target);
419
424 man,
425 );
426 break;
431 man,
432 );
433 break;
434 }
435
437 break;
438 default:
439 break;
440 }
441 return count;
442 }
ECachedEquipmentItemCategory
float InjectAgentWithPlayerDose(EntityAI target, int agent, float protection, float dose_size, int inject_type)
Injects agent to a given target.
static float GetProtectionLevelCachedEquipment(int type, int cachedEquipmentStorageMask, Man player)
Protection level of an attachment against enviromental hazard (mask/filters for example) based on res...
void InjectAgentsWithPlayer(EntityAI target, int agents, float protection, int dose_size, int inject_type)
Injects agents to a given target, using chance of transmission and full dose size if chance succeeds.
void InjectAgentsWithPlayerCount(EntityAI target, int agents, float protection, int dose_size, int inject_type)
Injects agents to a given target, with no probability, but the dose size is modified by m_Transferabi...
void InjectAgentsWithoutPlayer(EntityAI target, int agents)
Injects specified agents directly to target.
const int AGT_UACTION_CONSUME
const int DEF_DUST_PARTICLE_BREATH
const int AGT_ITEM_TO_FLESH
const int AGT_UACTION_TOUCH
const int AGT_AIRBOURNE_BIOLOGICAL
const int DEF_DUST_PARTICLE_EYES
const int AGT_TRANSFER_COPY
const int AGT_WATER_HOT_SPRING
const int AGT_UACTION_TO_PLAYER
const int AGT_AIRBOURNE_CHEMICAL
const int AGT_UACTION_TO_ITEM
const int AGT_AIRBOURNE_SOLID