Further debug logging for animations

This commit is contained in:
c0ffee 2024-05-03 10:51:59 -07:00
parent 7596fe86c6
commit e639ae8fb8
3 changed files with 6 additions and 5 deletions

View File

@ -19,11 +19,6 @@ namespace Rimworld_Animations
public bool canAnimationBeUsed(List<Pawn> actors)
{
if (RJWAnimationSettings.debugMode)
{
Log.Message("[anims] Checking if " + defName + " is valid animation");
}
if (!contexts.NullOrEmpty())
{
foreach (BaseGroupAnimationContext context in contexts)

View File

@ -44,6 +44,12 @@ namespace Rimworld_Animations {
//each participant gets their own unique extendedanimatoranchor, important for scribe_deep saving
List<AnimationDef> allAnimationsForPawn = groupAnimationDef.GetAllAnimationsForActor(i, seed, reorder);
BaseExtendedAnimatorAnchor animatorAnchor = new ExtendedAnimatorAnchor_Thing(anchor);
if (RJWAnimationSettings.debugMode)
{
Log.Message("Now playing animation: " + groupAnimationDef.defName);
}
participants[i].TryGetComp<CompExtendedAnimator>().PlayGroupAnimation(allAnimationsForPawn, position, rotation, animatorAnchor);
}
}