mirror of
https://github.com/KillzXGaming/Switch-Toolbox
synced 2024-11-22 20:43:09 +00:00
BFRES : Rename duplicate bone names when new bones are imported.
This commit is contained in:
parent
b48e0af34b
commit
82f104d8f1
1 changed files with 3 additions and 0 deletions
|
@ -523,11 +523,13 @@ namespace Bfres.Structs
|
|||
{
|
||||
BfresBone bn = new BfresBone(fskl);
|
||||
|
||||
List<string> boneKeys = fskl.bones.Select(i => i.Text).ToList();
|
||||
if (SkeletonU != null)
|
||||
{
|
||||
ResU.Bone bone = new ResU.Bone();
|
||||
bone.Import(FileName, GetResFileU());
|
||||
bone.ParentIndex = -1;
|
||||
bone.Name = Utils.RenameDuplicateString(boneKeys, bone.Name);
|
||||
|
||||
BfresWiiU.ReadBone(bn, bone, false);
|
||||
|
||||
|
@ -542,6 +544,7 @@ namespace Bfres.Structs
|
|||
Bone bone = new Bone();
|
||||
bone.Import(FileName);
|
||||
bone.ParentIndex = -1;
|
||||
bone.Name = Utils.RenameDuplicateString(boneKeys, bone.Name);
|
||||
|
||||
BfresSwitch.ReadBone(bn, bone, false);
|
||||
|
||||
|
|
Loading…
Reference in a new issue