1
0
mirror of https://github.com/soarqin/DSP_Mods_TO.git synced 2025-12-11 00:43:28 +08:00

update XianTu to support latest patch

This commit is contained in:
2025-10-05 22:46:06 +08:00
parent bf383de76d
commit d8ab2163de
3 changed files with 51 additions and 35 deletions

View File

@@ -14,10 +14,18 @@
<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>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\AssemblyFromGame\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\AssemblyFromGame\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework.TrimEnd(`0123456789`))' == 'net'">
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />

View File

@@ -156,25 +156,27 @@ namespace XianTu.Scripts.DataController
private void Build(BuildTool_BlueprintPaste bp)
{
PlayerController.cmd.stage = 1;
bp.GenerateBlueprintGratBoxes();
bp.DeterminePreviewsPrestage(true);
bp.ActiveColliders(_actionBuild.model);
bp.buildCondition = bp.CheckBuildConditions();
bp.DeterminePreviews();
bp.DeactiveColliders(_actionBuild.model);
var buildCondition = bp.buildCondition;
if (buildCondition)
if (bp.CheckBuildConditionsPrestage())
{
bp.CreatePrebuilds();
bp.ResetStates();
}
else
{
bp.isDragging = false;
bp.startGroundPosSnapped = bp.castGroundPosSnapped;
_BuildTool_BluePrint_OnTick();
PlayerController.cmd.stage = 1;
bp.GenerateBlueprintGratBoxes();
bp.DeterminePreviewsPrestage(true, false);
bp.ActiveColliders(_actionBuild.model);
var buildCondition = bp.CheckBuildConditions();
bp.DeterminePreviews();
bp.result = (buildCondition ? (bp.result & ~EBlueprintPasteResult.HasError) : (bp.result | EBlueprintPasteResult.HasError));
bp.DeactiveColliders(_actionBuild.model);
bp.CalculateReformData();
if (buildCondition && bp.quickPaste && (bp.result & EBlueprintPasteResult.HasReform) == EBlueprintPasteResult.None)
{
bp.CreatePrebuilds();
bp.ResetStates();
}
}
bp.isDragging = false;
bp.startGroundPosSnapped = bp.castGroundPosSnapped;
bp.ErrorGridClustering();
_BuildTool_BluePrint_OnTick();
}
private void OnUserChangeData()
@@ -372,20 +374,18 @@ namespace XianTu.Scripts.DataController
{
buildToolBlueprintPaste.ClearErrorMessage();
buildToolBlueprintPaste.UpdateRaycast();
var flag2 = PlayerController.cmd.stage == 0;
if (flag2)
{
buildToolBlueprintPaste.OperatingPrestage();
}
else
{
var flag3 = PlayerController.cmd.stage == 1;
if (flag3)
{
buildToolBlueprintPaste.Operating();
}
}
buildToolBlueprintPaste.UpdatePreviewModels(_actionBuild.model);
buildToolBlueprintPaste.CheckBuildConditionsPrestage();
switch (PlayerController.cmd.stage)
{
case 0:
buildToolBlueprintPaste.OperatingPrestage();
break;
case 1:
buildToolBlueprintPaste.Operating();
break;
}
buildToolBlueprintPaste.UpdatePreviewModels(_actionBuild.model);
buildToolBlueprintPaste.ErrorGridClustering();
}
}

View File

@@ -15,9 +15,17 @@
<ItemGroup>
<PackageReference Include="BepInEx.Core" Version="5.*" />
<PackageReference Include="BepInEx.PluginInfoProps" Version="1.*" />
<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.*" />
<PackageReference Include="UnityEngine.Modules" Version="2018.4.12" IncludeAssets="compile" />
<PackageReference Include="UnityEngine.Modules" Version="2022.3.53" IncludeAssets="compile" />
<!--<PackageReference Include="DysonSphereProgram.GameLibs" Version="*-r.*" />-->
<!--<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.*" />-->
</ItemGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\AssemblyFromGame\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\AssemblyFromGame\UnityEngine.UI.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework.TrimEnd(`0123456789`))' == 'net'">