1
0
mirror of https://github.com/soarqin/DSP_Mods.git synced 2025-12-08 22:13:30 +08:00

fix #15: UniverseGenTweaks support for stars greater than 256 now

This commit is contained in:
2023-12-16 16:20:34 +08:00
parent d0fff3f375
commit 947d3e4d20
17 changed files with 17 additions and 175 deletions

View File

@@ -16,7 +16,7 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
</ItemGroup>
@@ -28,27 +28,6 @@
<ProjectReference Include="..\UXAssist\UXAssist.csproj" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
<Exec Command="del /F /Q package\$(ProjectName)-$(Version).zip&#xA;zip -9 -j package/$(ProjectName)-$(Version).zip $(TargetPath) package/icon.png package/manifest.json README.md" />
</Target>

View File

@@ -15,7 +15,7 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
</ItemGroup>
@@ -24,27 +24,6 @@
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
<Exec Command="del /F /Q package\$(ProjectName)-$(Version).zip&#xA;zip -9 -j package/$(ProjectName)-$(Version).zip package/icon.png package/manifest.json README.md&#xA;copy /y &quot;$(TargetPath)&quot; package\plugins\&#xA;copy /y &quot;$(TargetDir)\System.Runtime.CompilerServices.Unsafe.dll&quot; package\plugins\&#xA;cd package&#xA;zip -9 -r $(ProjectName)-$(Version).zip plugins" />
</Target>

View File

@@ -16,7 +16,7 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="DysonSphereProgram.Modding.DSPModSave" Version="1.*" />
<PackageReference Include="DysonSphereProgram.Modding.NebulaMultiplayerModApi" Version="1.3.1" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
@@ -30,21 +30,6 @@
<Reference Include="Assembly-CSharp">
<HintPath>GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<Target Name="PostBuild" AfterTargets="PostBuildEvent">

View File

@@ -14,31 +14,10 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework.TrimEnd(`0123456789`))' == 'net'">
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />
</ItemGroup>

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -15,7 +15,7 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
</ItemGroup>
@@ -23,27 +23,6 @@
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
<Exec Command="del /F /Q package\$(ProjectName)-$(Version).zip&#xA;IF NOT EXIST package\plugins (mkdir package\plugins)&#xA;copy /y $(TargetPath) package\plugins\&#xA;zip -9 -j package/$(ProjectName)-$(Version).zip package/icon.png package/manifest.json README.md&#xA;cd package&#xA;zip -9 -r $(ProjectName)-$(Version).zip patchers plugins" />
</Target>

View File

@@ -14,34 +14,13 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework.TrimEnd(`0123456789`))' == 'net'">
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
<Exec Command="IF NOT EXIST ..\LabOpt\package\patchers (mkdir ..\LabOpt\package\patchers)&#xA;copy /y $(TargetPath) ..\LabOpt\package\patchers\" />

View File

@@ -15,7 +15,7 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
</ItemGroup>
@@ -23,27 +23,6 @@
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
<Exec Command="del /F /Q package\$(ProjectName)-$(Version).zip&#xA;zip -9 -j package/$(ProjectName)-$(Version).zip $(TargetPath) package/icon.png package/manifest.json README.md" />
</Target>

View File

@@ -243,13 +243,13 @@ public class MoreSettings
var matcher = new CodeMatcher(instructions, generator);
matcher.MatchForward(false,
new CodeMatch(ci => ci.opcode == OpCodes.Ldc_I4 && ci.OperandIs(25700))
).SetAndAdvance(OpCodes.Ldsfld, AccessTools.Field(typeof(MoreSettings), nameof(MoreSettings.MaxStarCount))).Insert(
).Repeat(m => m.SetAndAdvance(OpCodes.Ldsfld, AccessTools.Field(typeof(MoreSettings), nameof(MoreSettings.MaxStarCount))).Insert(
new CodeInstruction(OpCodes.Call, AccessTools.PropertyGetter(typeof(ConfigEntry<int>), nameof(ConfigEntry<int>.Value))),
new CodeInstruction(OpCodes.Ldc_I4_1),
new CodeInstruction(OpCodes.Add),
new CodeInstruction(OpCodes.Ldc_I4_S, 100),
new CodeInstruction(OpCodes.Mul)
);
));
return matcher.InstructionEnumeration();
}

View File

@@ -4,6 +4,8 @@
#### 宇宙生成参数调节
## Changelog
* 1.2.3
+ Fix a crash while setting star count greater than 256
* 1.2.2
+ Support game version 0.10.28.20759
* 1.2.1
@@ -33,6 +35,8 @@
* High luminosity for birth star
## 更新日志
* 1.2.3
+ 修复了设置星系数大于256时崩溃的问题
* 1.2.2
+ 支持游戏版本0.10.28.20759
* 1.2.1

View File

@@ -6,7 +6,7 @@
<AssemblyName>UniverseGenTweaks</AssemblyName>
<BepInExPluginGuid>org.soardev.universegentweaks</BepInExPluginGuid>
<Description>DSP MOD - UniverseGenTweaks</Description>
<Version>1.2.2</Version>
<Version>1.2.3</Version>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<LangVersion>latest</LangVersion>
<RestoreAdditionalProjectSources>https://nuget.bepinex.dev/v3/index.json</RestoreAdditionalProjectSources>
@@ -15,7 +15,7 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
</ItemGroup>
@@ -27,27 +27,6 @@
<ProjectReference Include="..\UXAssist\UXAssist.csproj" />
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\GameAssembly\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Unity.TextMeshPro">
<HintPath>..\GameAssembly\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\GameAssembly\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.SpatialTracking">
<HintPath>..\GameAssembly\UnityEngine.SpatialTracking.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Timeline">
<HintPath>..\GameAssembly\UnityEngine.Timeline.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\GameAssembly\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
<Exec Command="del /F /Q package\$(ProjectName)-$(Version).zip&#xA;zip -9 -j package/$(ProjectName)-$(Version).zip $(TargetPath) package/icon.png package/manifest.json README.md" />
</Target>

View File

@@ -1,10 +1,10 @@
{
"name": "UniverseGenTweaks",
"version_number": "1.2.2",
"version_number": "1.2.3",
"website_url": "https://github.com/soarqin/DSP_Mods/tree/master/UniverseGenTweaks",
"description": "Universe Generation Tweaks / 宇宙生成参数调节",
"dependencies": [
"xiaoye97-BepInEx-5.4.17",
"soarqin-UXAssist-1.0.2"
"soarqin-UXAssist-1.0.5"
]
}