Skip to content

Commit

Permalink
Merge pull request #213 from ME3Tweaks/Beta
Browse files Browse the repository at this point in the history
ME3Explorer - ME3Tweaks Fork 5.0.2
  • Loading branch information
Mgamerz authored Jan 2, 2021
2 parents f6011e4 + f57bad9 commit 7b692c7
Show file tree
Hide file tree
Showing 29 changed files with 274 additions and 167 deletions.
5 changes: 3 additions & 2 deletions ME3Explorer/Interpreter/InterpreterWPF.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public partial class InterpreterWPF : ExportLoaderControl
//same type and are not distinguishable without changing to another export, wasting a lot of time.
//values are the class of object value being parsed
public static readonly string[] ExportToStringConverters = { "LevelStreamingKismet", "StaticMeshComponent", "ParticleSystemComponent", "DecalComponent", "LensFlareComponent" };
public static readonly string[] IntToStringConverters = { "WwiseEvent" };
public static readonly string[] IntToStringConverters = { "WwiseEvent", "WwiseBank" };
public ObservableCollectionExtended<IndexedName> ParentNameList { get; private set; }

public bool SubstituteImageForHexBox
Expand Down Expand Up @@ -1196,10 +1196,11 @@ private static string IntToString(NameReference name, int value, ExportEntry exp
switch (export.ClassName)
{
case "WwiseEvent":
case "WwiseBank":
switch (name)
{
case "Id":
return $" (0x{value:X8})";
return $"(0x{value:X8})";
}
break;
}
Expand Down
20 changes: 15 additions & 5 deletions ME3Explorer/ME3Explorer.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -1612,10 +1612,10 @@
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>xcopy /f /y "$(SolutionDir)Libraries" "$(ProjectDir)$(OutDir)"
<PostBuildEvent>IF NOT EXIST "$(ProjectDir)$(OutDir)lib" md $(ProjectDir)$(OutDir)lib"
xcopy /f /y "$(SolutionDir)Libraries" "$(ProjectDir)$(OutDir)lib"

xcopy /f /e /y "$(SolutionDir)Resources" "$(ProjectDir)$(OutDir)"
move "$(ProjectDir)$(OutDir)x64\e_sqlite3.dll" "$(ProjectDir)$(OutDir)e_sqlite3.dll"
rmdir /s /q "$(ProjectDir)$(OutDir)x86"
rmdir /s /q "$(ProjectDir)$(OutDir)x64"
rmdir /s /q "$(ProjectDir)$(OutDir)fr-CA"
Expand All @@ -1633,15 +1633,25 @@ rmdir /s /q "$(ProjectDir)$(OutDir)sv"
rmdir /s /q "$(ProjectDir)$(OutDir)zh-Hans"
rmdir /s /q "$(ProjectDir)$(OutDir)runtimes\win-arm"
rmdir /s /q "$(ProjectDir)$(OutDir)runtimes\win-x86"

del /s "$(TargetDir)*.xml"

move /y "$(ProjectDir)$(OutDir)Shader3DeComp.exe" "$(ProjectDir)$(OutDir)lib\"
move /y "$(ProjectDir)$(OutDir)Shader3DeComp.exe.config" "$(ProjectDir)$(OutDir)lib\"
del "$(ProjectDir)$(OutDir)HexConverter.exe.config"
if $(ConfigurationName) == Release (copy /Y "$(SolutionDir)Deployment\ReleaseBuilder.cmd" "$(TargetDir)..\ReleaseBuilder.bat" /y)

if $(ConfigurationName) == Release (copy /Y "$(SolutionDir)Deployment\ReleaseBuilder.ps1" "$(TargetDir)..\ReleaseBuilder.ps1" /y)
</PostBuildEvent>
REM MAKE SURE BELOW ITEMS ARE LAST
REM CAUSE ROBOCOPY HAS SPECIFIC RETURN CODES
REM THAT MUST BE SWALLOWED TO PASS THE BUILD

if EXIST "$(ProjectDir)$(OutDir)runtimes" (
IF EXIST "$(ProjectDir)$(OutDir)lib\runtimes" (
robocopy "$(ProjectDir)$(OutDir)runtimes" "$(ProjectDir)$(OutDir)lib\runtimes" /E /IS /MOVE
IF %25ERRORLEVEL%25 LEQ 8 EXIT 0
) ELSE (
move /y "$(ProjectDir)$(OutDir)runtimes" "$(ProjectDir)$(OutDir)lib\runtimes"
)
)</PostBuildEvent>
</PropertyGroup>
<PropertyGroup>
<PreBuildEvent>::del "$(ProjectDir)$(OutDir)*.txt"
Expand Down
Binary file modified ME3Explorer/Properties/AssemblyInfo.cs
Binary file not shown.
44 changes: 29 additions & 15 deletions ME3Explorer/Soundplorer/Soundpanel.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,6 @@
</ContextMenu>

<!--Sets a context menu for each ListBoxItem in the current ListBox-->


<DataTemplate DataType="{x:Type local:EmbeddedWEMFile}">
<!-- Do not remove transparent background. It is required for mouse hit testing.-->
<TextBlock Text="{Binding DisplayString}" Foreground="DarkBlue"/>
Expand Down Expand Up @@ -182,28 +180,39 @@
<RowDefinition MinHeight="230"/>
</Grid.RowDefinitions>

<ListBox ItemsSource="{Binding HIRCObjects}" Name="HIRC_ListBox" SelectionChanged="HIRC_ListBox_SelectionChanged" Grid.Row="0" Grid.ColumnSpan="3" HorizontalContentAlignment="Stretch">
<ListBox ItemsSource="{Binding HIRCObjects}"
Name="HIRC_ListBox" SelectionChanged="HIRC_ListBox_SelectionChanged"
HorizontalContentAlignment="Stretch"
Grid.Row="0" Grid.ColumnSpan="3">
<ListBox.Resources>
<DataTemplate DataType="{x:Type soundplorer:HIRCDisplayObject}">
<StackPanel Name="HIRCContainer" Orientation="Horizontal" VerticalAlignment="Center">
<TextBlock Text="{Binding Index}" VerticalAlignment="Center" Margin="0,0,5,0" Padding="10,0,10,0"/>
<StackPanel>
<TextBlock Text="{Binding ID,StringFormat='HIRC 0x{0:X8}'}"/>
<TextBlock Text="{Binding Path=ObjType, Converter={StaticResource HIRCObjectTypeConverter}}" FontStyle="Italic"/>
<Border Margin="0" Padding="2,0,2,0" BorderThickness="1" BorderBrush="Red" Background="AntiqueWhite" CornerRadius="2" HorizontalAlignment="Left" Visibility="{Binding Converter={StaticResource HIRCObjectTypeVisibilityConverter},ConverterParameter=2}">
<TextBlock Text="{Binding State,Converter={StaticResource HIRCMediaFetchTypeConverter}}" FontWeight="Bold"/>
</Border>
</StackPanel>
<StackPanel.ContextMenu>
<DockPanel x:Name="HIRCContainer" VerticalAlignment="Center">
<TextBlock Text="{Binding Index}" DockPanel.Dock="Left" VerticalAlignment="Center" Margin="0,0,5,0" Padding="10,0,10,0"/>
<TextBlock Text="{Binding ID,StringFormat='HIRC 0x{0:X8}'}" DockPanel.Dock="Top"/>
<Button Content="PLAY" DockPanel.Dock="Right"
VerticalAlignment="Center"
Padding="5"
Visibility="{Binding Converter={StaticResource HIRCObjectTypeVisibilityConverter},ConverterParameter=2}"
Command="{Binding PlayHIRCCommand, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type local:Soundpanel}}}"
CommandParameter="{Binding}">

</Button>
<Border Margin="0" DockPanel.Dock="Bottom" Padding="2,0,2,0" BorderThickness="1" BorderBrush="Red" Background="AntiqueWhite"
CornerRadius="2" HorizontalAlignment="Left"
Visibility="{Binding Converter={StaticResource HIRCObjectTypeVisibilityConverter},ConverterParameter=2}">
<TextBlock Text="{Binding State,Converter={StaticResource HIRCMediaFetchTypeConverter}}" FontWeight="Bold"/>
</Border>
<TextBlock Text="{Binding Path=ObjType, Converter={StaticResource HIRCObjectTypeConverter}}" FontStyle="Italic"/>
<DockPanel.ContextMenu>
<ContextMenu>
<MenuItem Click="CloneHIRCObject" ToolTip="Clones HIRC object">
<MenuItem.Header>
<TextBlock Text="Clone" Foreground="{DynamicResource {x:Static SystemColors.ControlTextBrush}}"/>
</MenuItem.Header>
</MenuItem>
</ContextMenu>
</StackPanel.ContextMenu>
</StackPanel>
</DockPanel.ContextMenu>
</DockPanel>
<DataTemplate.Triggers>
<DataTrigger Binding="{Binding Path=DataChanged}" Value="true">
<Setter Property="Background" Value="Yellow" TargetName="HIRCContainer"/>
Expand All @@ -214,6 +223,11 @@
</DataTemplate.Triggers>
</DataTemplate>
</ListBox.Resources>
<ListBox.ItemContainerStyle>
<Style TargetType="ListBoxItem">
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
</Style>
</ListBox.ItemContainerStyle>
</ListBox>
<GridSplitter Grid.Column="0" Grid.ColumnSpan="3"
Grid.Row="1" HorizontalAlignment="Stretch"
Expand Down
Loading

0 comments on commit 7b692c7

Please sign in to comment.