Skip to content

Commit

Permalink
Fix exception thrown in "DecompileProperties"
Browse files Browse the repository at this point in the history
  • Loading branch information
EliotVU committed Sep 12, 2024
1 parent 68512e9 commit 92e6bc0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Core/Classes/UDefaultProperty.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public string Decompile()

string expr = name;
return ArrayIndex > 0
? $"{expr}{PropertyDisplay.FormatT3DElementAccess(ArrayIndex.ToString(), _Buffer.Version)}={value}"
? $"{expr}{PropertyDisplay.FormatT3DElementAccess(ArrayIndex.ToString(), _Container.Package.Version)}={value}"
: $"{expr}={value}";
}

Expand Down
2 changes: 1 addition & 1 deletion src/Core/Classes/UObjectDecompiler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ protected string DecompileProperties()
&& Properties[i].ArrayIndex <= 0
&& Properties[i + 1].ArrayIndex > 0)
{
propertyText = propertyText.Insert(Properties[i].Name.Length, PropertyDisplay.FormatT3DElementAccess("0", _Buffer.Version));
propertyText = propertyText.Insert(Properties[i].Name.Length, PropertyDisplay.FormatT3DElementAccess("0", Package.Version));
}

propertiesText += $"{UDecompilingState.Tabs}{propertyText}\r\n";
Expand Down
5 changes: 5 additions & 0 deletions src/Eliot.UELib.csproj.DotSettings
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<s:Boolean x:Key="/Default/CodeInspection/NamespaceProvider/NamespaceFoldersToSkip/=core_005Cclasses/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/CodeInspection/NamespaceProvider/NamespaceFoldersToSkip/=core_005Ctables/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/CodeInspection/NamespaceProvider/NamespaceFoldersToSkip/=core_005Ctokens/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/CodeInspection/NamespaceProvider/NamespaceFoldersToSkip/=core_005Ctypes/@EntryIndexedValue">True</s:Boolean></wpf:ResourceDictionary>

0 comments on commit 92e6bc0

Please sign in to comment.