RimWorld

RimWorld

[NL] Facial Animation - WIP
Alien Race Framework/Kurin mod compatibility
Hello! I love your mod and the potential it has, but with some mods that add the alien races the facial animations don't work! I've looked into the XML code between Kurin, your mod and Alien Races and I noticed in the race_patch.xml file you tell it to animate the ThingDef "human", I tried adding to the patch to have it use the Alien Race (DRTNF_Race) but it didn't work out. I'm curious if you could look into this and add in that feature! There are other aliens mods out there too like Ratkins that would be amazing with this mod as well.

Again thank you for this mod and I hope you can make this work.
< >
Showing 1-15 of 58 comments
FlareFluffsune Jul 19, 2019 @ 4:13am 
I would also be interested in seeing if this can be done.
Nals  [developer] Jul 22, 2019 @ 7:06am 
Hi, I 'm not good at English, so I show some examples using patch codes. With this current version, you can make patches for Alien Races as following. That is for Android Mods.
Note: I have not tested it well, so, maybe, probably there are some bugs to use them.

<?xml version="1.0" encoding="utf-8" ?>
<Patch>
<Operation Class="PatchOperationSequence">
<success>Always</success>
<operations>
<li Class="PatchOperationTest">
<xpath>/Defs/AlienRace.ThingDef_AlienRace[defName="ChjAndroid"]</xpath>
</li>
<li Class="PatchOperationAdd">
<xpath>/Defs/AlienRace.ThingDef_AlienRace[defName="ChjAndroid"]/comps</xpath>
<value>
<li>
<compClass>FacialAnimation.DrawFaceGraphicsComp</compClass>
</li>
<li>
<compClass>FacialAnimation.HeadControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.EyeballControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.LidControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.BrowControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.MouthControllerComp</compClass>
</li>
<!--<li>
<compClass>FacialAnimation.EmotionControllerComp</compClass>
</li>-->
<li>
<compClass>FacialAnimation.FacialAnimationControllerComp</compClass>
</li>
</value>
</li>
</operations>
</Operation>
</Patch>
Last edited by Nals; Jul 22, 2019 @ 7:19am
felmane Aug 6, 2019 @ 12:42am 
Where would this file go, and could you do multiple races in 1 file? Or is it 1 file per race?
I love the mod!
felmane Aug 6, 2019 @ 3:42pm 
I tried using that code to patch Orassians (neko patch) and Dragonians, but it didn't work. Popped up an error before, but I can't find it again
Lyseria Aug 16, 2019 @ 3:08am 
@felmane
Seems like that patch is for Androids. It looks like a template though so I'm guessing you just need to change some keywords to apply it for Orassians and Dragonians.
Last edited by Lyseria; Aug 16, 2019 @ 3:19am
YoutubeDeclan Sep 1, 2019 @ 9:18pm 
Where exactly would you put the code?
Daemon976 Nov 6, 2019 @ 8:31am 
I've used this template to patch multiple alien races that have human-shaped heads successfully and it looks awesome. Ratkin get even cuter, if that's possible.

With non-human heads like Forsaken or Avali if you patch this in it will replace the heads with human shaped ones, which while cute doesn't fit with those races.

To use you need to place an xml file with the template in the Patch folder of this mod (or create a new local mod folder) so that the game will load and apply it.
Bonk Dec 2, 2019 @ 2:43am 
Originally posted by Daemon976:
I've used this template to patch multiple alien races that have human-shaped heads successfully and it looks awesome. Ratkin get even cuter, if that's possible.

With non-human heads like Forsaken or Avali if you patch this in it will replace the heads with human shaped ones, which while cute doesn't fit with those races.

To use you need to place an xml file with the template in the Patch folder of this mod (or create a new local mod folder) so that the game will load and apply it.

So, I've done what you've suggested, but the animations are still not showing up on my alien races. No errors in the console, but definitely no animations either. Humans have them, but Dragonians for example do not.
Wizard Dec 12, 2019 @ 5:58pm 
cant get this to work with any other race..... i find there defined names in the code but still doesnt work
Wizard Dec 12, 2019 @ 6:25pm 
Originally posted by Nals:
Hi, I 'm not good at English, so I show some examples using patch codes. With this current version, you can make patches for Alien Races as following. That is for Android Mods.
Note: I have not tested it well, so, maybe, probably there are some bugs to use them.

<?xml version="1.0" encoding="utf-8" ?>
<Patch>
<Operation Class="PatchOperationSequence">
<success>Always</success>
<operations>
<li Class="PatchOperationTest">
<xpath>/Defs/AlienRace.ThingDef_AlienRace[defName="ChjAndroid"]</xpath>
</li>
<li Class="PatchOperationAdd">
<xpath>/Defs/AlienRace.ThingDef_AlienRace[defName="ChjAndroid"]/comps</xpath>
<value>
<li>
<compClass>FacialAnimation.DrawFaceGraphicsComp</compClass>
</li>
<li>
<compClass>FacialAnimation.HeadControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.EyeballControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.LidControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.BrowControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.MouthControllerComp</compClass>
</li>
<!--<li>
<compClass>FacialAnimation.EmotionControllerComp</compClass>
</li>-->
<li>
<compClass>FacialAnimation.FacialAnimationControllerComp</compClass>
</li>
</value>
</li>
</operations>
</Operation>
</Patch>
ive tried multiple races such as Kurin, Ratkin, Callistan, Astoriel by replacing the "ChjAndroid" in both places with the specific races defName "DRTNF_Race" for kurin for example none of them work except for Android one.. what am i doing wrong?
Last edited by Wizard; Dec 12, 2019 @ 6:25pm
felmane Dec 13, 2019 @ 1:20pm 
Originally posted by Wizard530:
cant get this to work with any other race..... i find there defined names in the code but still doesnt work
This is my personal patch for Kurins, you can check it against yours:
<?xml version="1.0" encoding="utf-8" ?>
<Patch>
<Operation Class="PatchOperationSequence">
<success>Always</success>
<operations>
<li Class="PatchOperationTest">
<xpath>/Defs/AlienRace.ThingDef_AlienRace[defName="DRNTF_Race"]/comps</xpath>
<success>Invert</success>
</li>
<li Class="PatchOperationAdd">
<xpath>/Defs/AlienRace.ThingDef_AlienRace[defName="DRNTF_Race"]</xpath>
<value>
<comps />
</value>
</li>
</operations>
</Operation>

<Operation Class="PatchOperationAdd">
<xpath>/Defs/AlienRace.ThingDef_AlienRace[defName="DRNTF_Race"]/comps</xpath>
<value>
<li>
<compClass>FacialAnimation.DrawFaceGraphicsComp</compClass>
</li>
<li>
<compClass>FacialAnimation.HeadControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.EyeballControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.LidControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.BrowControllerComp</compClass>
</li>
<li>
<compClass>FacialAnimation.MouthControllerComp</compClass>
</li>
<!--<li>
<compClass>FacialAnimation.EmotionControllerComp</compClass>
</li>-->
<li>
<compClass>FacialAnimation.FacialAnimationControllerComp</compClass>
</li>

</value>
</Operation>
</Patch>
felmane Dec 13, 2019 @ 1:21pm 
I also have a bunch of other patches that I've made.
The John Jan 21, 2020 @ 2:36pm 
Could someone make a patch for the Astoriel and teach me how and where to put it?
Solzucht Apr 19, 2020 @ 12:01am 
@felmane
you planning to release the patches to the public? :)
felmane Apr 19, 2020 @ 4:49pm 
the patches are all the same, just replace "DRNTF_Race" with whatever race you want it to work for
< >
Showing 1-15 of 58 comments
Per page: 1530 50