public bool CheckPauldronRotation(Pawn pawn, ShoulderPadType shoulderPadType) { if (shoulderPadType == ShoulderPadType.Left && pawn.Rotation == Rot4.East) { return(false); } if (shoulderPadType == ShoulderPadType.Right && pawn.Rotation == Rot4.West) { return(false); } return(true); }
public override void PostSpawnSetup(bool respawningAfterLoad) { base.PostSpawnSetup(respawningAfterLoad); ShoulderPadEntry entry = this.pprops.PauldronEntries.RandomElementByWeight((ShoulderPadEntry x) => x.commonality); this.graphicPath = entry.padTexPath; if (entry.UseFactionTextures) { this.graphicPath += ("_" + this.apparel.Wearer.Faction.Name); } this.shader = ShaderDatabase.ShaderFromType(entry.shaderType); this.useSecondaryColor = entry.UseSecondaryColor; this.padType = entry.shoulderPadType; }