-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Rider IDE support. * Untested patch for Anomaly proximity detector. * Update Rider support gitignore.
- Loading branch information
Showing
5 changed files
with
61 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
Source/AnimationMod/Patches/Patch_Building_ProximityDetector_RunDetection.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
using HarmonyLib; | ||
using JetBrains.Annotations; | ||
using RimWorld; | ||
|
||
namespace AM.Patches; | ||
|
||
/// <summary> | ||
/// The proximity detector freaks out if it detects any invisible pawn in range, | ||
/// which includes the animated pawns. | ||
/// This patch makes them not be considered invisible when the detection process is running. | ||
/// </summary> | ||
[HarmonyPatch(typeof(Building_ProximityDetector), nameof(Building_ProximityDetector.RunDetection))] | ||
[UsedImplicitly(ImplicitUseKindFlags.Access, ImplicitUseTargetFlags.Itself | ImplicitUseTargetFlags.WithMembers)] | ||
public class Patch_Building_ProximityDetector_RunDetection | ||
{ | ||
[HarmonyPriority(Priority.First)] | ||
private static void Prefix(ref bool __state) | ||
{ | ||
__state = Patch_InvisibilityUtility_IsPsychologicallyInvisible.IsRendering; | ||
Patch_InvisibilityUtility_IsPsychologicallyInvisible.IsRendering = true; | ||
} | ||
|
||
[HarmonyPriority(Priority.First)] | ||
private static void Postfix(bool __state) | ||
{ | ||
Patch_InvisibilityUtility_IsPsychologicallyInvisible.IsRendering = __state; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters