mirror of
https://gitgud.io/c0ffeeeeeeee/rimworld-animations.git
synced 2024-08-15 00:43:45 +00:00
patch for dont shave your head
This commit is contained in:
parent
d3db12f744
commit
ce09ac0b2a
2 changed files with 30 additions and 0 deletions
|
@ -91,6 +91,7 @@
|
|||
<Compile Include="Source\MainTabWindows\MainTabWindow_SexAnimator.cs" />
|
||||
<Compile Include="Source\Patches\HarmonyPatch_AlienRace.cs" />
|
||||
<Compile Include="Source\Patches\HarmonyPatch_CSL.cs" />
|
||||
<Compile Include="Source\Patches\HarmonyPatch_DontShaveYourHead.cs" />
|
||||
<Compile Include="Source\Patches\HarmonyPatch_FacialAnimation.cs" />
|
||||
<Compile Include="Source\Patches\HarmonyPatch_PawnRenderer.cs" />
|
||||
<Compile Include="Source\Patches\HarmonyPatch_PawnRotation.cs" />
|
||||
|
|
29
Source/Patches/HarmonyPatch_DontShaveYourHead.cs
Normal file
29
Source/Patches/HarmonyPatch_DontShaveYourHead.cs
Normal file
|
@ -0,0 +1,29 @@
|
|||
using HarmonyLib;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Verse;
|
||||
|
||||
namespace Rimworld_Animations {
|
||||
class HarmonyPatch_DontShaveYourHead {
|
||||
|
||||
[StaticConstructorOnStartup]
|
||||
public static class Patch_DontShaveYourHead {
|
||||
|
||||
static Patch_DontShaveYourHead() {
|
||||
try {
|
||||
((Action)(() =>
|
||||
{
|
||||
if (LoadedModManager.RunningModsListForReading.Any(x => x.Name == "Don't Shave Your Head 1.0")) {
|
||||
(new Harmony("rjw")).Patch(AccessTools.Method(AccessTools.TypeByName("DontShaveYourHead.Harmony_PawnRenderer"), "DrawHairReroute"), //typeof(ShowHair.Patch_PawnRenderer_RenderPawnInternal), nameof(ShowHair.Patch_PawnRenderer_RenderPawnInternal.Postfix)),
|
||||
transpiler: new HarmonyMethod(AccessTools.Method(typeof(Patch_ShowHairWithHats), "Transpiler")));
|
||||
}
|
||||
}))();
|
||||
}
|
||||
catch (TypeLoadException ex) { }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue