mirror of
https://github.com/amevarashi/RJW-Sexperience.git
synced 2024-08-14 23:54:08 +00:00
Move disable Mtb functionality to PreceptComp_UnwillingToDo
This commit is contained in:
parent
6941293212
commit
85ed241217
4 changed files with 12 additions and 10 deletions
|
@ -43,9 +43,6 @@ namespace RJWSexperience.Ideology
|
|||
if (defExtension == null)
|
||||
continue;
|
||||
|
||||
if (defExtension.disable)
|
||||
return -1f;
|
||||
|
||||
finalMultiplier *= defExtension.multiplier;
|
||||
}
|
||||
return finalMultiplier;
|
||||
|
|
|
@ -11,7 +11,14 @@ namespace RJWSexperience.Ideology.Patches
|
|||
{
|
||||
public static void Postfix(Pawn pawn, ref float __result)
|
||||
{
|
||||
if (__result > 0f && pawn.Ideo != null) // ideo is null if don't have dlc
|
||||
if (__result < 0f || pawn.Ideo == null) // ideo is null if don't have dlc
|
||||
return;
|
||||
|
||||
if (!VariousDefOf.RSI_SexWithAnimal.CreateEvent(pawn).DoerWillingToDo())
|
||||
{
|
||||
__result = -2f;
|
||||
return;
|
||||
}
|
||||
__result *= IdeoUtility.GetPreceptsMtbMultiplier<DefExtension_ModifyBestialityMtb>(pawn.Ideo);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -7,7 +7,5 @@ namespace RJWSexperience.Ideology.Precepts
|
|||
{
|
||||
[SuppressMessage("Minor Code Smell", "S1104:Fields should not have public accessibility", Justification = "Field value loaded from XML")]
|
||||
public float multiplier = 1f;
|
||||
[SuppressMessage("Minor Code Smell", "S1104:Fields should not have public accessibility", Justification = "Field value loaded from XML")]
|
||||
public bool disable = false;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -88,6 +88,9 @@
|
|||
<li>HumanPrimacy</li>
|
||||
</associatedMemes>
|
||||
<comps>
|
||||
<li Class="PreceptComp_UnwillingToDo">
|
||||
<eventDef>RSI_SexWithAnimal</eventDef>
|
||||
</li>
|
||||
<li Class="PreceptComp_SelfTookMemoryThought">
|
||||
<eventDef>RSI_SexWithVeneratedAnimal</eventDef>
|
||||
<thought>Bestiality_Abhorrent</thought>
|
||||
|
@ -116,9 +119,6 @@
|
|||
</li>
|
||||
</rules>
|
||||
</li>
|
||||
<li Class="RJWSexperience.Ideology.Precepts.DefExtension_ModifyBestialityMtb">
|
||||
<disable>true</disable>
|
||||
</li>
|
||||
</modExtensions>
|
||||
</PreceptDef>
|
||||
|
||||
|
|
Loading…
Reference in a new issue