From c63c589d565b7e4da3a82868fd0f55134c0a0c74 Mon Sep 17 00:00:00 2001 From: Tory <22203-Tory@users.noreply.gitgud.io> Date: Wed, 23 Jun 2021 23:39:26 +0000 Subject: [PATCH] Updated to include string for actors --- Source/AnimationUtility.cs | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/Source/AnimationUtility.cs b/Source/AnimationUtility.cs index 02899dd..5bb091a 100644 --- a/Source/AnimationUtility.cs +++ b/Source/AnimationUtility.cs @@ -39,7 +39,22 @@ namespace Rimworld_Animations { return false; } } - + if (x.actors[i].requiredGender != null && !x.actors[i].requiredGender.Contains(localParticipants[i].gender.ToStringSafe())) + { + if (AnimationSettings.debugMode) + { + Log.Message(string.Concat(new string[] + { + x.defName.ToStringSafe(), + " not selected -- ", + localParticipants[i].def.defName.ToStringSafe(), + " ", + localParticipants[i].Name.ToStringSafe(), + " does not match required gender" + }), false); + } + return false; + } if ((x.actors[i].blacklistedRaces != null) && x.actors[i].blacklistedRaces.Contains(localParticipants[i].def.defName)) { if(AnimationSettings.debugMode) Log.Message(x.defName.ToStringSafe() + " not selected -- " + localParticipants[i].def.defName.ToStringSafe() + " " + localParticipants[i].Name.ToStringSafe() + " is blacklisted");