Skip to content

Commit

Permalink
Refactor to remove versioning system.
Browse files Browse the repository at this point in the history
  • Loading branch information
Epicguru committed Apr 10, 2024
1 parent 30721c3 commit e078794
Show file tree
Hide file tree
Showing 182 changed files with 194 additions and 498 deletions.
1 change: 1 addition & 0 deletions About/About.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,6 @@ Load as far down as possible.</description>
<li>erdelf.humanoidalienraces</li>
<li>Krkr.rule56</li>
<li>ceteam.combatextended</li>
<li>taranchuk.performanceoptimizer</li>
</loadAfter>
</ModMetaData>
Binary file added About/ModIcon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 2 additions & 16 deletions Source/AMRetextureSupport/AMRetextureSupport.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,36 +9,22 @@
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
<AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
<RootNamespace>AM.Retexture</RootNamespace>
<Configurations>v1.4;v1.5</Configurations>
<Nullable>disable</Nullable>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<DebugType>none</DebugType>

<!-- Version preprocesor defines here: -->
<DefineConstants Condition="'$(Configuration)'=='v1.4'">V14</DefineConstants>
<DefineConstants Condition="'$(Configuration)'=='v1.5'">V15</DefineConstants>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Krafs.Publicizer" Version="2.2.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
<PackageReference Include="Krafs.Rimworld.Ref" Version="1.5.4060-beta" />
</ItemGroup>

<ItemGroup>
<!-- Ungodly hack to access rimworld private properties & methods -->
<Publicize Include="Assembly-CSharp" />
</ItemGroup>

<!-- _____ 1.4 _____ -->
<ItemGroup Condition="'$(Configuration)'=='v1.4'">
<PackageReference Include="Krafs.Rimworld.Ref" Version="1.4.3901" />
</ItemGroup>

<!-- _____ 1.5 _____ -->
<ItemGroup Condition="'$(Configuration)'=='v1.5'">
<PackageReference Include="Krafs.Rimworld.Ref" Version="1.5.4033-beta" />
</ItemGroup>

</Project>
2 changes: 0 additions & 2 deletions Source/AMRetextureSupport/RetextureUtility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@
using System.Linq;
using UnityEngine;
using Verse;
#if !V14
using LudeonTK;
#endif

namespace AM.Retexture;

Expand Down
51 changes: 17 additions & 34 deletions Source/AlienRacesPatch/AlienRacesPatch.csproj
Original file line number Diff line number Diff line change
@@ -1,62 +1,45 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<Import Project="../GlobalCommon.targets"/>

<PropertyGroup>
<TargetFramework>net48</TargetFramework>
<OutputType>Library</OutputType>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<NoStdLib>false</NoStdLib>
<LangVersion>preview</LangVersion>
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
<AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
<Configurations>v1.4;v1.5</Configurations>
<AssemblyName>AM.AlienRacesPatch</AssemblyName>
<RootNamespace>AM.AlienRacesPatch</RootNamespace>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\ThingGenerator\AnimationMod.csproj">
<CopyLocal>False</CopyLocal>
<Private>False</Private>
<ExcludeAssets>all</ExcludeAssets>
</ProjectReference>
<PackageReference Include="Krafs.Rimworld.Ref" Version="1.5.4060-beta" />
</ItemGroup>

<!-- _____ 1.4 _____ -->
<ItemGroup Condition="'$(Configuration)'=='v1.4'">
<Reference Include="AlienRace">
<HintPath>refs/1.4/AlienRace14.dll</HintPath>
<ItemGroup>
<ProjectReference Include="..\AnimationMod\AnimationMod.csproj">
<CopyLocal>False</CopyLocal>
<Private>False</Private>
</Reference>
<PackageReference Include="Krafs.Rimworld.Ref">
<Version>1.4.3901</Version>
</PackageReference>
<ExcludeAssets>all</ExcludeAssets>
</ProjectReference>
</ItemGroup>

<PropertyGroup Condition="'$(Configuration)'=='v1.4'">
<DebugType>none</DebugType>
<OutputPath>..\..\Patch_AlienRaces\1.4\Assemblies\</OutputPath>
<Optimize>true</Optimize>
<DefineConstants>TRACE;V14</DefineConstants>
</PropertyGroup>

<!-- _____ 1.5 _____ -->
<ItemGroup Condition="'$(Configuration)'=='v1.5'">
<Reference Include="AlienRace">
<HintPath>refs/1.4/AlienRace14.dll</HintPath> <!-- TODO CHANGE ME ONCE HAR UPDATES! -->
<ItemGroup>
<Reference Include="AlienRace">
<HintPath>refs\AlienRace.dll</HintPath>
<CopyLocal>False</CopyLocal>
<Private>False</Private>
</Reference>
<PackageReference Include="Krafs.Rimworld.Ref">
<Version>1.5.4033-beta</Version>
</PackageReference>
</ItemGroup>
<ExcludeAssets>runtime</ExcludeAssets>
</Reference>
</ItemGroup>

<PropertyGroup Condition="'$(Configuration)'=='v1.5'">
<PropertyGroup>
<DebugType>none</DebugType>
<OutputPath>..\..\Patch_AlienRaces\1.5\Assemblies\</OutputPath>
<OutputPath>..\..\Patch_AlienRaces\$(RimworldVersion)\Assemblies\</OutputPath>
<Optimize>true</Optimize>
<DefineConstants>TRACE;V15</DefineConstants>
<DefineConstants>TRACE</DefineConstants>
</PropertyGroup>

</Project>
File renamed without changes.
102 changes: 51 additions & 51 deletions Source/AnimationMod.sln
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31717.71
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AnimationMod", "ThingGenerator\AnimationMod.csproj", "{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AnimationMod", "AnimationMod\AnimationMod.csproj", "{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "LightsaberPatch", "LightsaberPatch\LightsaberPatch.csproj", "{D9B99467-57BB-4DE7-8147-F5D47554D1CB}"
EndProject
Expand Down Expand Up @@ -32,58 +32,58 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TacticowlPatch", "Tacticowl
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
v1.4|Any CPU = v1.4|Any CPU
v1.5|Any CPU = v1.5|Any CPU
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.v1.4|Any CPU.ActiveCfg = Release|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.v1.4|Any CPU.Build.0 = Release|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.v1.5|Any CPU.ActiveCfg = Debug|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.v1.5|Any CPU.Build.0 = Debug|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.v1.4|Any CPU.ActiveCfg = Debug|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.v1.4|Any CPU.Build.0 = Debug|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.v1.5|Any CPU.ActiveCfg = Release|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.v1.5|Any CPU.Build.0 = Release|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.v1.4|Any CPU.ActiveCfg = Debug|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.v1.4|Any CPU.Build.0 = Debug|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.v1.5|Any CPU.ActiveCfg = Release|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.v1.5|Any CPU.Build.0 = Release|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.v1.4|Any CPU.ActiveCfg = Debug|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.v1.4|Any CPU.Build.0 = Debug|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.v1.5|Any CPU.ActiveCfg = Release|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.v1.5|Any CPU.Build.0 = Release|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.v1.4|Any CPU.ActiveCfg = v1.4|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.v1.4|Any CPU.Build.0 = v1.4|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.v1.5|Any CPU.ActiveCfg = v1.5|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.v1.5|Any CPU.Build.0 = v1.5|Any CPU
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0CB2DDBC-ECE8-46B4-A8E9-9BF2239BE82B}.Release|Any CPU.Build.0 = Release|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D9B99467-57BB-4DE7-8147-F5D47554D1CB}.Release|Any CPU.Build.0 = Release|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{15189C13-7D5D-4F8D-AE17-1CA9F4A744EB}.Release|Any CPU.Build.0 = Release|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{603ACB32-6730-4BAF-8E0A-A0E3399D634F}.Release|Any CPU.Build.0 = Release|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3802FB86-C860-4F98-A6F6-5E9AA47AF564}.Release|Any CPU.Build.0 = Release|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{67701E3B-9094-4CA2-9DD8-42EBAFCB9F4A}.Release|Any CPU.Build.0 = Release|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0B91E675-3505-4587-94BB-6FEFC5ADB24D}.Release|Any CPU.Build.0 = Release|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.Debug|Any CPU.Build.0 = Debug|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.Release|Any CPU.ActiveCfg = Release|Any CPU
{BBB0D084-8A32-458E-8A7F-48E7D90F0489}.Release|Any CPU.Build.0 = Release|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DB0FEE4E-5DF7-4DD3-B876-7FC20D310C8E}.Release|Any CPU.Build.0 = Release|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{06C481CC-E8D0-46D6-B02B-127DD9E3A1AA}.Release|Any CPU.Build.0 = Release|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7B881968-1527-40FC-9FB3-85A5A01BEE88}.Release|Any CPU.Build.0 = Release|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DEC2223C-6DD4-48EF-9438-8F4E97B6C542}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
using System.Linq;
using UnityEngine;
using Verse;
#if !V14
using LudeonTK;
#endif

namespace AM.AMSettings;

Expand Down Expand Up @@ -429,11 +427,7 @@ float DrawAnim(AnimDef def)
checkbox.x += 110;
checkbox.width = 200;

#if V14
def.SData.Probability = Widgets.HorizontalSlider_NewTemp(checkbox, def.SData.Probability, 0f, 10f, label: $"Relative Probability: {def.SData.Probability * 100f:F0}%", roundTo: 0.05f);
#else
def.SData.Probability = Widgets.HorizontalSlider(checkbox, def.SData.Probability, 0f, 10f, label: $"Relative Probability: {def.SData.Probability * 100f:F0}%", roundTo: 0.05f);
#endif
}

return rect.height;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,21 +1,18 @@
using System;
using AM.UI;
using AM.Video;
using ColourPicker;
using LudeonTK;
using RimWorld;
using System;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Runtime.Remoting.Messaging;
using System.Security;
using System.Text;
using AM.UI;
using AM.Video;
using ColourPicker;
using RimWorld;
using UnityEngine;
using Verse;
#if !V14
using LudeonTK;
#endif

namespace AM.AMSettings;

Expand Down Expand Up @@ -604,11 +601,8 @@ private static float DrawNumeric(SimpleSettingsBase settings, MemberWrapper memb
float step = member.TryGetCustomAttribute<StepAttribute>()?.Step ?? -1;

// Simple slider for now.
#if V14
float changed = Widgets.HorizontalSlider_NewTemp(sliderArea, value, min.Value, max.Value, roundTo: step);
#else
float changed = Widgets.HorizontalSlider(sliderArea, value, min.Value, max.Value, roundTo: step);
#endif

if (Math.Abs(changed - value) > 0.0001f)
{
Type type = member.MemberType;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,5 @@ static AM_DefOf()

public static HediffDef AM_KnockedOut;

#if !V14
public static RenderSkipFlagDef Body;
#endif
}
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@
using RimWorld;
using UnityEngine;
using Verse;
#if !V14
using LudeonTK;
#endif

namespace AM;

Expand Down
Loading

0 comments on commit e078794

Please sign in to comment.