1
0
mirror of synced 2025-01-31 04:13:51 +01:00

Fix user data not setting properly for switch bfres

This commit is contained in:
KillzXGaming 2019-07-02 20:16:00 -04:00
parent b86be4e68c
commit 208f25408b
9 changed files with 11 additions and 11 deletions

Binary file not shown.

View File

@ -9,7 +9,7 @@ using Switch_Toolbox.Library;
using Switch_Toolbox.Library.IO;
using Switch_Toolbox.Library.Forms;
namespace FirstPlugin
namespace FirstPlugin.New
{
public class SARC : IArchiveFile, IFileFormat
{

View File

@ -186,7 +186,7 @@ namespace FirstPlugin.Forms
}
else
{
userDataEditor.LoadUserData(material.Material.UserDatas.ToList());
userDataEditor.LoadUserData(material.Material.UserDatas);
}
}

View File

@ -55,7 +55,7 @@ namespace FirstPlugin.Forms
}
else
{
userDataEditor1.LoadUserData(fmdl.Model.UserData.ToList());
userDataEditor1.LoadUserData(fmdl.Model.UserData);
stPropertyGrid1.LoadProperty(fmdl.Model, OnPropertyChanged);
}
}
@ -72,7 +72,7 @@ namespace FirstPlugin.Forms
else
{
stPropertyGrid1.LoadProperty(anim.SkeletalAnim, OnPropertyChanged);
userDataEditor1.LoadUserData(anim.SkeletalAnim.UserDatas.ToList());
userDataEditor1.LoadUserData(anim.SkeletalAnim.UserDatas);
}
}
public void LoadSubFile(FMAA anim)
@ -80,7 +80,7 @@ namespace FirstPlugin.Forms
activeFmaa = anim;
stPropertyGrid1.LoadProperty(anim.MaterialAnim, OnPropertyChanged);
userDataEditor1.LoadUserData(anim.MaterialAnim.UserData.ToList());
userDataEditor1.LoadUserData(anim.MaterialAnim.UserData);
if (anim.AnimType == MaterialAnimation.AnimationType.TexturePattern)
{
@ -159,7 +159,7 @@ namespace FirstPlugin.Forms
else
{
stPropertyGrid1.LoadProperty(anim.ShapeAnim, OnPropertyChanged);
userDataEditor1.LoadUserData(anim.ShapeAnim.UserData.ToList());
userDataEditor1.LoadUserData(anim.ShapeAnim.UserData);
}
}
public void LoadSubFile(FSCN anim)
@ -174,7 +174,7 @@ namespace FirstPlugin.Forms
else
{
stPropertyGrid1.LoadProperty(anim.SceneAnim, OnPropertyChanged);
userDataEditor1.LoadUserData(anim.SceneAnim.UserData.ToList());
userDataEditor1.LoadUserData(anim.SceneAnim.UserData);
}
}
public void LoadSubFile(FVIS anim)
@ -189,7 +189,7 @@ namespace FirstPlugin.Forms
else
{
stPropertyGrid1.LoadProperty(anim.VisibilityAnim, OnPropertyChanged);
userDataEditor1.LoadUserData(anim.VisibilityAnim.UserData.ToList());
userDataEditor1.LoadUserData(anim.VisibilityAnim.UserData);
}
BoneVisualAnimEditor editor = (BoneVisualAnimEditor)GetActiveControl(typeof(BoneVisualAnimEditor));

View File

@ -23,13 +23,13 @@ namespace FirstPlugin
}
ResDict<UserData> userData;
List<ResNX.UserData> userDataNX;
IList<ResNX.UserData> userDataNX;
UserData SelectedDataU;
ResNX.UserData SelectedDataNX;
bool IsWiiU = false;
public void LoadUserData(List<ResNX.UserData> UserDataList)
public void LoadUserData(IList<ResNX.UserData> UserDataList)
{
listViewCustom1.Items.Clear();
@ -39,7 +39,7 @@ namespace FirstPlugin
}
//Convert the user data from bntx
public void LoadUserData(List<ResBNTX.UserData> UserDataList)
public void LoadUserData(IList<ResBNTX.UserData> UserDataList)
{
userDataNX = new List<ResNX.UserData>();