diff --git a/res/GameObjectBlank.nif b/res/GameObjectBlank.nif deleted file mode 100644 index 291c52c8..00000000 Binary files a/res/GameObjectBlank.nif and /dev/null differ diff --git a/res/SkeletonBlank.nif b/res/SkeletonBlank.nif deleted file mode 100644 index 067c0c4d..00000000 Binary files a/res/SkeletonBlank.nif and /dev/null differ diff --git a/res/SkeletonBlank_fo4.nif b/res/SkeletonBlank_fo4.nif index 4f49491e..9f28e18c 100644 Binary files a/res/SkeletonBlank_fo4.nif and b/res/SkeletonBlank_fo4.nif differ diff --git a/res/SkeletonBlank_sk.nif b/res/SkeletonBlank_sk.nif new file mode 100644 index 00000000..b7aaa525 Binary files /dev/null and b/res/SkeletonBlank_sk.nif differ diff --git a/res/SkeletonBlank_sse.nif b/res/SkeletonBlank_sse.nif index 3a129eaf..ea258d3f 100644 Binary files a/res/SkeletonBlank_sse.nif and b/res/SkeletonBlank_sse.nif differ diff --git a/res/skeleton_female_sk.nif b/res/skeleton_female_sk.nif new file mode 100644 index 00000000..c423b5b0 Binary files /dev/null and b/res/skeleton_female_sk.nif differ diff --git a/res/skeleton_female_sse.nif b/res/skeleton_female_sse.nif index a9dba00e..6702e18d 100644 Binary files a/res/skeleton_female_sse.nif and b/res/skeleton_female_sse.nif differ diff --git a/res/skeleton_female_vanilla.nif b/res/skeleton_female_vanilla.nif deleted file mode 100644 index 30b90d35..00000000 Binary files a/res/skeleton_female_vanilla.nif and /dev/null differ diff --git a/res/skeleton_female_xpms.nif b/res/skeleton_female_xpms.nif deleted file mode 100644 index 4d598a6e..00000000 Binary files a/res/skeleton_female_xpms.nif and /dev/null differ diff --git a/res/skeleton_female_xpmse.nif b/res/skeleton_female_xpmse.nif deleted file mode 100644 index 3a016863..00000000 Binary files a/res/skeleton_female_xpmse.nif and /dev/null differ diff --git a/res/skeleton_fo4.nif b/res/skeleton_fo4.nif index 353044f2..cc66d252 100644 Binary files a/res/skeleton_fo4.nif and b/res/skeleton_fo4.nif differ diff --git a/res/skeleton_male_sk.nif b/res/skeleton_male_sk.nif new file mode 100644 index 00000000..e1302405 Binary files /dev/null and b/res/skeleton_male_sk.nif differ diff --git a/res/skeleton_male_sse.nif b/res/skeleton_male_sse.nif new file mode 100644 index 00000000..c14ec59e Binary files /dev/null and b/res/skeleton_male_sse.nif differ diff --git a/src/program/BodySlideApp.cpp b/src/program/BodySlideApp.cpp index 60073c9b..16cd07ea 100644 --- a/src/program/BodySlideApp.cpp +++ b/src/program/BodySlideApp.cpp @@ -1043,17 +1043,17 @@ bool BodySlideApp::ShowSetup() { switch (targ) { case FO3: dataDir = dirFallout3->GetDirName(); - Config.SetValue("Anim/DefaultSkeletonReference", "res\\skeleton_female_fo3nv.nif"); - Config.SetValue("Anim/SkeletonRootName", "Bip"); + Config.SetValue("Anim/DefaultSkeletonReference", "res\\skeleton_fo3nv.nif"); + Config.SetValue("Anim/SkeletonRootName", "Bip01"); break; case FONV: dataDir = dirFalloutNV->GetDirName(); - Config.SetValue("Anim/DefaultSkeletonReference", "res\\skeleton_female_fo3nv.nif"); - Config.SetValue("Anim/SkeletonRootName", "Bip"); + Config.SetValue("Anim/DefaultSkeletonReference", "res\\skeleton_fo3nv.nif"); + Config.SetValue("Anim/SkeletonRootName", "Bip01"); break; case SKYRIM: dataDir = dirSkyrim->GetDirName(); - Config.SetValue("Anim/DefaultSkeletonReference", "res\\skeleton_female_xpmse.nif"); + Config.SetValue("Anim/DefaultSkeletonReference", "res\\skeleton_female_sk.nif"); Config.SetValue("Anim/SkeletonRootName", "NPC Root [Root]"); break; case FO4: @@ -2859,7 +2859,7 @@ void BodySlideFrame::OnChooseTargetGame(wxCommandEvent& event) { choiceSkeletonRoot->SetStringSelection("Bip01"); break; case SKYRIM: - fpSkeletonFile->SetPath("res\\skeleton_female_xpmse.nif"); + fpSkeletonFile->SetPath("res\\skeleton_female_sk.nif"); choiceSkeletonRoot->SetStringSelection("NPC Root [Root]"); break; case SKYRIMSE: diff --git a/src/program/OutfitProject.cpp b/src/program/OutfitProject.cpp index 59f47cd1..830eb8a3 100644 --- a/src/program/OutfitProject.cpp +++ b/src/program/OutfitProject.cpp @@ -466,24 +466,15 @@ int OutfitProject::AddShapeFromObjFile(const string& fileName, const string& sha int OutfitProject::CreateNifShapeFromData(const string& shapeName, vector& v, vector& t, vector& uv, vector* norms) { - bool staticMode = Config["StaticMeshMode"] == "True"; - string blankSkel; - string defaultName; - if (!staticMode) { - defaultName = "New Outfit"; + string defaultName = "New Outfit"; - if (owner->targetGame <= SKYRIM) - blankSkel = "res\\SkeletonBlank.nif"; - else if (owner->targetGame == FO4) - blankSkel = "res\\SkeletonBlank_fo4.nif"; - else if (owner->targetGame == SKYRIMSE) - blankSkel = "res\\SkeletonBlank_sse.nif"; - } - else { - blankSkel = "res\\GameObjectBlank.nif"; - defaultName = "New Object"; - } + if (owner->targetGame <= SKYRIM) + blankSkel = "res\\SkeletonBlank_sk.nif"; + else if (owner->targetGame == FO4) + blankSkel = "res\\SkeletonBlank_fo4.nif"; + else if (owner->targetGame == SKYRIMSE) + blankSkel = "res\\SkeletonBlank_sse.nif"; NifFile blank; blank.Load(blankSkel); @@ -505,21 +496,18 @@ int OutfitProject::CreateNifShapeFromData(const string& shapeName, vectorSetDataRef(skinID); - nifDismemberInst->SetSkinPartitionRef(partID); - nifDismemberInst->SetSkeletonRootRef(0); - } + BSDismemberSkinInstance* nifDismemberInst = new BSDismemberSkinInstance(workNif.GetHeader()); + int dismemberID = blank.GetHeader().AddBlock(nifDismemberInst, "BSDismemberSkinInstance"); + nifDismemberInst->SetDataRef(skinID); + nifDismemberInst->SetSkinPartitionRef(partID); + nifDismemberInst->SetSkeletonRootRef(0); BSShaderTextureSet* nifTexset = new BSShaderTextureSet(workNif.GetHeader()); @@ -558,33 +546,24 @@ int OutfitProject::CreateNifShapeFromData(const string& shapeName, vectortargetGame == FO4) { BSTriShape* triShapeBase; string wetShaderName = "template/OutfitTemplate_Wet.bgsm"; - if (staticMode) { - triShapeBase = new BSTriShape(workNif.GetHeader()); - triShapeBase->Create(&v, &t, &uv, norms); - blank.GetHeader().AddBlock(triShapeBase, "BSTriShape"); - wetShaderName.clear(); - } - else { - BSSubIndexTriShape* nifBSTriShape = new BSSubIndexTriShape(workNif.GetHeader()); - nifBSTriShape->Create(&v, &t, &uv, norms); - blank.GetHeader().AddBlock(nifBSTriShape, "BSSubIndexTriShape"); - - BSSkinInstance* nifBSSkinInstance = new BSSkinInstance(workNif.GetHeader()); - int skinID = blank.GetHeader().AddBlock(nifBSSkinInstance, "BSSkin::Instance"); - nifBSSkinInstance->SetTargetRef(workNif.GetRootNodeID()); - - BSSkinBoneData* nifBoneData = new BSSkinBoneData(workNif.GetHeader()); - int boneID = blank.GetHeader().AddBlock(nifBoneData, "BSSkin::BoneData"); - nifBSSkinInstance->SetDataRef(boneID); - nifBSTriShape->SetSkinInstanceRef(skinID); - triShapeBase = nifBSTriShape; - } + BSSubIndexTriShape* nifBSTriShape = new BSSubIndexTriShape(workNif.GetHeader()); + nifBSTriShape->Create(&v, &t, &uv, norms); + blank.GetHeader().AddBlock(nifBSTriShape, "BSSubIndexTriShape"); + + BSSkinInstance* nifBSSkinInstance = new BSSkinInstance(workNif.GetHeader()); + int skinID = blank.GetHeader().AddBlock(nifBSSkinInstance, "BSSkin::Instance"); + nifBSSkinInstance->SetTargetRef(workNif.GetRootNodeID()); + + BSSkinBoneData* nifBoneData = new BSSkinBoneData(workNif.GetHeader()); + int boneID = blank.GetHeader().AddBlock(nifBoneData, "BSSkin::BoneData"); + nifBSSkinInstance->SetDataRef(boneID); + nifBSTriShape->SetSkinInstanceRef(skinID); + triShapeBase = nifBSTriShape; BSShaderTextureSet* nifTexset = new BSShaderTextureSet(workNif.GetHeader()); - int shaderID; BSLightingShaderProperty* nifShader = new BSLightingShaderProperty(workNif.GetHeader()); - shaderID = blank.GetHeader().AddBlock(nifShader, "BSLightingShaderProperty"); + int shaderID = blank.GetHeader().AddBlock(nifShader, "BSLightingShaderProperty"); nifShader->textureSetRef = blank.GetHeader().AddBlock(nifTexset, "BSShaderTextureSet"); nifShader->SetWetMaterialName(wetShaderName); @@ -596,27 +575,24 @@ int OutfitProject::CreateNifShapeFromData(const string& shapeName, vectorCreate(&v, &t, &uv, norms); blank.GetHeader().AddBlock(triShape, "BSTriShape"); - if (!staticMode) { - NiSkinData* nifSkinData = new NiSkinData(workNif.GetHeader()); - int skinID = blank.GetHeader().AddBlock(nifSkinData, "NiSkinData"); + NiSkinData* nifSkinData = new NiSkinData(workNif.GetHeader()); + int skinID = blank.GetHeader().AddBlock(nifSkinData, "NiSkinData"); - NiSkinPartition* nifSkinPartition = new NiSkinPartition(workNif.GetHeader()); - int partID = blank.GetHeader().AddBlock(nifSkinPartition, "NiSkinPartition"); + NiSkinPartition* nifSkinPartition = new NiSkinPartition(workNif.GetHeader()); + int partID = blank.GetHeader().AddBlock(nifSkinPartition, "NiSkinPartition"); - BSDismemberSkinInstance* nifDismemberInst = new BSDismemberSkinInstance(workNif.GetHeader()); - int dismemberID = blank.GetHeader().AddBlock(nifDismemberInst, "BSDismemberSkinInstance"); - nifDismemberInst->SetDataRef(skinID); - nifDismemberInst->SetSkinPartitionRef(partID); - nifDismemberInst->SetSkeletonRootRef(0); - triShape->SetSkinInstanceRef(dismemberID); - triShape->SetSkinned(true); - } + BSDismemberSkinInstance* nifDismemberInst = new BSDismemberSkinInstance(workNif.GetHeader()); + int dismemberID = blank.GetHeader().AddBlock(nifDismemberInst, "BSDismemberSkinInstance"); + nifDismemberInst->SetDataRef(skinID); + nifDismemberInst->SetSkinPartitionRef(partID); + nifDismemberInst->SetSkeletonRootRef(0); + triShape->SetSkinInstanceRef(dismemberID); + triShape->SetSkinned(true); BSShaderTextureSet* nifTexset = new BSShaderTextureSet(workNif.GetHeader()); - int shaderID; BSLightingShaderProperty* nifShader = new BSLightingShaderProperty(workNif.GetHeader()); - shaderID = blank.GetHeader().AddBlock(nifShader, "BSLightingShaderProperty"); + int shaderID = blank.GetHeader().AddBlock(nifShader, "BSLightingShaderProperty"); nifShader->textureSetRef = blank.GetHeader().AddBlock(nifTexset, "BSShaderTextureSet"); triShape->SetName(shapeName);