Fix removal of EST bones.

This commit is contained in:
Ottermandias 2022-06-06 21:17:27 +02:00
parent d2b969d996
commit caf19f24cb
2 changed files with 9 additions and 4 deletions

View file

@ -88,9 +88,14 @@ public sealed unsafe class EstFile : MetaBaseFile
control[ i ] = control[ i + 1 ];
}
for( var i = 0; i < Count; ++i )
for( var i = 0; i < idx; ++i )
{
entries[ i - 2 ] = entries[ i + 1 ];
entries[ i - 2 ] = entries[ i ];
}
for( var i = idx; i < Count - 1; ++i )
{
entries[i - 2] = entries[i + 1];
}
entries[ Count - 3 ] = 0;

View file

@ -232,7 +232,7 @@ public partial class ConfigWindow
var (data, length) = resource->GetData();
if( data != IntPtr.Zero && length > 0 )
{
ImGui.SetClipboardText( string.Join( " ",
ImGui.SetClipboardText( string.Join( "\n",
new ReadOnlySpan< byte >( ( byte* )data, length ).ToArray().Select( b => b.ToString( "X2" ) ) ) );
}
}
@ -245,7 +245,7 @@ public partial class ConfigWindow
ImGui.Selectable( $"0x{Penumbra.CharacterUtility.DefaultResources[ i ].Address:X}" );
if( ImGui.IsItemClicked() )
{
ImGui.SetClipboardText( string.Join( " ",
ImGui.SetClipboardText( string.Join( "\n",
new ReadOnlySpan< byte >( ( byte* )Penumbra.CharacterUtility.DefaultResources[ i ].Address,
Penumbra.CharacterUtility.DefaultResources[ i ].Size ).ToArray().Select( b => b.ToString( "X2" ) ) ) );
}