Skip to content

Commit 1025159

Browse files
committed
Update 2.3.0.4
2 parents 4fdc943 + 43031f1 commit 1025159

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

xivModdingFramework/Materials/DataContainers/XivMtrl.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -802,7 +802,7 @@ private void RegenerateTextureUsageList(ShaderInfo info)
802802

803803
if (info.Shader == MtrlShader.Skin)
804804
{
805-
if (info.Preset == MtrlShaderPreset.Face)
805+
if (info.Preset == MtrlShaderPreset.Face || info.Preset == MtrlShaderPreset.FaceNoPores)
806806
{
807807
SetTextureUsage(XivTexType.Normal);
808808
SetTextureUsage(XivTexType.Diffuse);

xivModdingFramework/Models/DataContainers/TTModel.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1203,6 +1203,10 @@ public void SaveFullToFile(string filePath, string raceId, Action<bool, string>
12031203
}
12041204

12051205
var directory = Path.GetDirectoryName(filePath);
1206+
if (raceId.StartsWith("c"))
1207+
{
1208+
raceId = raceId.Substring(1, 4);
1209+
}
12061210
var race = XivRaces.GetXivRace(raceId);
12071211

12081212
var boneDict = ResolveFullBoneHeirarchy(race, loggingFunction);

xivModdingFramework/Models/FileTypes/Sklb.cs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,21 @@ public static async Task<string> GetExtraSkeletonFile(string fullMdlPath)
110110

111111
public static async Task<string> GetExtraSkeletonFile(XivDependencyRootInfo root, XivRace race = XivRace.All_Races)
112112
{
113+
if(root.SecondaryType == XivItemType.ear)
114+
{
115+
// Viera ears technically use their associated face's Extra Skeleton to resolve the bones. Kinda weird, but whatever.
116+
// The bones are nearly identical for all the faces, so just use face 1
117+
var nRoot = new XivDependencyRootInfo()
118+
{
119+
PrimaryType = root.PrimaryType,
120+
PrimaryId = root.PrimaryId,
121+
SecondaryId = 1,
122+
SecondaryType = XivItemType.face,
123+
Slot = "fac"
124+
};
125+
root = nRoot;
126+
}
127+
113128
var file = await GetExtraSkelbPath(root, race);
114129
if (file == null) return null;
115130

0 commit comments

Comments
 (0)