mirror of
https://gitgud.io/c0ffeeeeeeee/rimworld-animations.git
synced 2024-08-15 00:43:45 +00:00
vanilla lovin does animation
This commit is contained in:
parent
b04afef7b1
commit
1e05e7a3dc
7 changed files with 77 additions and 6 deletions
|
@ -0,0 +1,28 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using HarmonyLib;
|
||||
using RimWorld;
|
||||
using Verse;
|
||||
using rjw;
|
||||
using Verse.AI;
|
||||
|
||||
namespace Rimworld_Animations {
|
||||
|
||||
[HarmonyPatch(typeof(JobGiver_DoLovin), "TryGiveJob")]
|
||||
public static class HarmonyPatch_DoLovinAnimationPatch {
|
||||
|
||||
public static void Postfix(ref Pawn pawn, ref Job __result) {
|
||||
|
||||
if(__result != null) {
|
||||
|
||||
RestUtility.WakeUp(pawn);
|
||||
Pawn partnerInMyBed = LovePartnerRelationUtility.GetPartnerInMyBed(pawn);
|
||||
__result = JobMaker.MakeJob(DefDatabase<JobDef>.GetNamed("JoinInBedAnimation", true), partnerInMyBed, partnerInMyBed.CurrentBed());
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue