mirror of
https://github.com/vegapnk/RJW-Genes.git
synced 2024-08-15 00:23:31 +00:00
Hardened Utility to account for childs with in-active lifeforce
This commit is contained in:
parent
999236768e
commit
1b590ba2a2
2 changed files with 30 additions and 3 deletions
|
@ -42,7 +42,7 @@ namespace RJW_Genes
|
|||
{
|
||||
Pawn_GeneTracker genes = pawn.genes;
|
||||
Gene_LifeForce gene_Lifeforce = (genes != null) ? genes.GetFirstGeneOfType<Gene_LifeForce>() : null;
|
||||
if (gene_Lifeforce != null && gene_Lifeforce.Value < gene_Lifeforce.MinLevelForAlert)
|
||||
if (gene_Lifeforce != null && gene_Lifeforce.Active && gene_Lifeforce.Value < gene_Lifeforce.MinLevelForAlert)
|
||||
{
|
||||
this.targets.Add(pawn);
|
||||
this.targetLabels.Add(pawn.NameShortColored.Resolve());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue