Removed the DiseaseGene

This commit is contained in:
Vegapnk 2024-07-03 10:20:57 +02:00
parent bccd258d13
commit c90c9e2c02
4 changed files with 5 additions and 23 deletions

View file

@ -2,12 +2,9 @@
<Defs>
<GeneDef>
<displayCategory>rjw_genes_diseases</displayCategory>
<defName>rjw_genes_genetic_disease_immunity</defName>
<displayOrderInCategory>1</displayOrderInCategory>
<label>genetic disease immunity</label>
<description>This gene makes the pawn immune against genetic STDs and other genes that imply negative side-effects. </description>
<biostatCpx>2</biostatCpx>
@ -17,15 +14,12 @@
Class="VanillaGenesExpanded.GeneExtension">
<backgroundPathEndogenes>Genes/Icons/RJW_Genes_Endogene_Background</backgroundPathEndogenes>
<backgroundPathXenogenes>Genes/Icons/RJW_Genes_Xenogene_Background</backgroundPathXenogenes>
</li>
</li>
</GeneDef>
<GeneDef>
<displayCategory>rjw_genes_diseases</displayCategory>
<defName>rjw_genes_minor_vulnerability</defName>
<geneClass>RJW_Genes.DiseaseGene</geneClass>
<label>minor vulnerability</label>
<description>This gene makes the pawn more vulnerable, and a more attractive target for rape. </description>
<biostatCpx>2</biostatCpx>

View file

@ -1,14 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Verse;
namespace RJW_Genes
{
public class DiseaseGene : Gene
{
}
}

View file

@ -87,7 +87,9 @@ namespace RJW_Genes.Genes.Diseases.Patches
private static bool IsGeneticDiseaseGene(GeneDef geneDef)
{
return geneDef.geneClass.FullName.Contains("DiseaseGene");
if (geneDef == null) return false;
GeneticDiseaseExtension diseaseExt = geneDef.GetModExtension<GeneticDiseaseExtension>();
return diseaseExt != null;
}
private static float LookupDiseaseInfectionChance(GeneDef geneDef)

View file

@ -75,7 +75,6 @@
<Compile Include="Genes\Cum\Patch_LikesCumflation.cs" />
<Compile Include="Genes\Damage\Gene_Elasticity.cs" />
<Compile Include="Genes\Diseases\Defs\GeneticDiseaseExtension.cs" />
<Compile Include="Genes\Diseases\Genes\DiseaseGene.cs" />
<Compile Include="Genes\Diseases\Patches\Patch_AftersexUtility_TransferGeneticDiseases.cs" />
<Compile Include="Genes\Life_Force\Events\SuccubusVisit\IncidentWorker_SuccubusVisit.cs" />
<Compile Include="Genes\Life_Force\Events\SuccubusVisit\LordJob_SuccubusVisit.cs" />
@ -241,6 +240,7 @@
</Reference>
</ItemGroup>
<ItemGroup>
<Folder Include="Genes\Diseases\Genes\" />
<Folder Include="Genes\Gender\Patches\" />
</ItemGroup>
<ItemGroup>