mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
- Fix: disease notification should not be visible to the player
- Fix: disease infection happened even though disease feaure was off - Disease Improvement: infection chance by corpse is now affected by age of corpse git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7486 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -3105,3 +3105,15 @@ BOOLEAN CorpseOkToDress( ROTTING_CORPSE* pCorpse )
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
// Flugente: how rotten is this corpse? values from 0 to 1, 1 as soon as it is rotting
|
||||
FLOAT GetCorpseRotFactor( ROTTING_CORPSE* pCorpse )
|
||||
{
|
||||
if ( !pCorpse )
|
||||
return 0.0f;
|
||||
|
||||
if ( pCorpse->def.ubType == ROTTING_STAGE2 )
|
||||
return 1.0f;
|
||||
|
||||
return (GetWorldTotalMin( ) - pCorpse->def.uiTimeOfDeath) / DELAY_UNTIL_ROTTING;
|
||||
}
|
||||
Reference in New Issue
Block a user