Hello!
I'm currently trying to change the hair color of a pawn midgame. The piece of code I have currently that is supposed to change the hair color is this.
P1.story.hairColor = Color.green;
The problem is that when I trigger the code nothing happens, but when I quit to menu and reload the game, the hair changes to the intended color.
Any tips on how I could make the hair change color as soon as the code is triggered?
Incase anyone is looking for the answer in the future, here's how I managed to solve this:
Pawn.Drawer.renderer.graphics.ResolveAllGraphics();
I guess this reloads the graphics of the pawn somehow, making any changes to the hair color appear right away. Probably not the best solution, but it works for me
Nope, that actually is the best/only solution. RimWorld 1.3+ caches the pawn graphics, unless you're using a mod like Graphics Settings, HD Pawn Renderer, etc.