Skip to content

Commit

Permalink
-upgrade: To .NET8 (#8)
Browse files Browse the repository at this point in the history
- Updated targets to .NET8 (Windows)
- Updated Versions and Copyright dates
- Fixed a bug in `AAPak.FileExists()`
- Added Publishing rules to make single executables and added a `COPY` to `AAMod`'s publish as to add it to the resource of `AAPakEditor` to be used as SFX.
  • Loading branch information
ZeromusXYZ authored Jan 6, 2025
1 parent c1e32d3 commit 965bc18
Show file tree
Hide file tree
Showing 32 changed files with 945 additions and 1,323 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -332,3 +332,5 @@ ASALocalRun/

# Local History for Visual Studio
.localhistory/

.publish/
114 changes: 31 additions & 83 deletions AAMod/AAMod.csproj
Original file line number Diff line number Diff line change
@@ -1,60 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{7FA9DDE6-4799-4269-9C2D-F5ADF66F10AC}</ProjectGuid>
<TargetFramework>net8.0-windows</TargetFramework>
<OutputType>WinExe</OutputType>
<RootNamespace>AAMod</RootNamespace>
<AssemblyName>AAMod</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<Deterministic>true</Deterministic>
<TargetFrameworkProfile />
<LangVersion>default</LangVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<GenerateAssemblyInfo>True</GenerateAssemblyInfo>
<UseWindowsForms>true</UseWindowsForms>
<ImportWindowsDesktopTargets>true</ImportWindowsDesktopTargets>
<PublishSingleFile>true</PublishSingleFile>
<SelfContained>true</SelfContained>
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>Resources\aamod_icon.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup>
<NoWin32Manifest>true</NoWin32Manifest>
<AssemblyTitle>AAMod</AssemblyTitle>
<Product>AAMod</Product>
<Copyright>Copyright © 2019-2025, No rights reserved</Copyright>
<AssemblyVersion>1.0.8.0</AssemblyVersion>
<FileVersion>1.0.8.0</FileVersion>
</PropertyGroup>
<PropertyGroup>
<RunPostBuildEvent>OnBuildSuccess</RunPostBuildEvent>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\AAPacker\AAPak.cs">
<Link>AAPak.cs</Link>
Expand All @@ -77,46 +43,28 @@
<Compile Include="..\AAPacker\PakFileType.cs">
<Link>PakFileType.cs</Link>
</Compile>
<Compile Include="Forms\ModMainForm.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\ModMainForm.Designer.cs">
<DependentUpon>ModMainForm.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="Forms\ModMainForm.resx">
<DependentUpon>ModMainForm.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
<SubType>Designer</SubType>
</EmbeddedResource>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
<DesignTime>True</DesignTime>
</Compile>
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
</ItemGroup>
<ItemGroup>
<Content Include="aamod_icon.ico" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
</ItemGroup>
<ItemGroup>
<Compile Update="Properties\Settings.Designer.cs">
<DesignTimeSharedInput>True</DesignTimeSharedInput>
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
</ItemGroup>
<ItemGroup>
<Content Include="aamod_icon.ico" />
<None Include="Resources\aamod_icon.ico" />
<None Update="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>copy /Y "$(TargetPath)" "$(SolutionDir)AAPakEditor\Resources\$(TargetFileName)"</PostBuildEvent>
</PropertyGroup>
<Target Name="CopyToAAPakEditor" AfterTargets="Publish">
<Exec WorkingDirectory="$(PublishDir)" Command="copy /Y AAMod.exe &quot;$(SolutionDir)AAPakEditor\Resources\AAMod.exe&quot;" />
</Target>
</Project>
6 changes: 0 additions & 6 deletions AAMod/App.config

This file was deleted.

2 changes: 2 additions & 0 deletions AAMod/Forms/ModMainForm.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Drawing;
using System.IO;
using System.Linq;
Expand All @@ -12,6 +13,7 @@

namespace AAMod.Forms
{
[SuppressMessage("Interoperability", "CA1416:Validate platform compatibility")]
public partial class ModMainForm : Form
{
private static readonly string appVerDate = "V20190518";
Expand Down
35 changes: 0 additions & 35 deletions AAMod/Properties/AssemblyInfo.cs

This file was deleted.

Loading

0 comments on commit 965bc18

Please sign in to comment.