Compare commits
13 Commits
v1.0.16-ma
...
v1.0.28-ma
Author | SHA1 | Date | |
---|---|---|---|
![]() |
ba5b611994 | ||
![]() |
2bcf79efdd | ||
![]() |
d5c101bf19 | ||
![]() |
e9841b4de1 | ||
![]() |
aea0011683 | ||
![]() |
d10528f9fe | ||
![]() |
66ea4d7307 | ||
![]() |
f6ce40a854 | ||
![]() |
bd62d31298 | ||
![]() |
b1cf5fb638 | ||
![]() |
1d6a2a9a60 | ||
![]() |
455be2393e | ||
![]() |
6131a9003b |
17
Dockerfile
17
Dockerfile
@@ -1,17 +0,0 @@
|
|||||||
FROM mcr.microsoft.com/windows/servercore:ltsc2022
|
|
||||||
|
|
||||||
USER ContainerAdministrator
|
|
||||||
ADD https://aka.ms/highdpimfc2013x64enu vc_redist2013.exe
|
|
||||||
ADD https://aka.ms/vs/16/release/vc_redist.x64.exe vc_redist.exe
|
|
||||||
|
|
||||||
RUN vc_redist2013.exe /passive /norestart
|
|
||||||
RUN vc_redist.exe /passive /norestart
|
|
||||||
RUN del vc_redist2013.exe && del vc_redist.exe
|
|
||||||
|
|
||||||
USER ContainerUser
|
|
||||||
COPY . .
|
|
||||||
ENV TORCH_GAME_PATH="c:\dedi"
|
|
||||||
ENV TORCH_INSTANCE="c:\instance"
|
|
||||||
ENV TORCH_SERVICE="true"
|
|
||||||
ENTRYPOINT ["Torch.Server.exe"]
|
|
||||||
CMD ["-noupdate"]
|
|
@@ -7,6 +7,7 @@ namespace Torch.Server
|
|||||||
{
|
{
|
||||||
internal static class Program
|
internal static class Program
|
||||||
{
|
{
|
||||||
|
[STAThread]
|
||||||
public static void Main(string[] args)
|
public static void Main(string[] args)
|
||||||
{
|
{
|
||||||
var isService = Environment.GetEnvironmentVariable("TORCH_SERVICE")
|
var isService = Environment.GetEnvironmentVariable("TORCH_SERVICE")
|
||||||
@@ -23,8 +24,6 @@ namespace Torch.Server
|
|||||||
File.Delete(file);
|
File.Delete(file);
|
||||||
}
|
}
|
||||||
|
|
||||||
TorchLauncher.Launch(workingDir, binDir);
|
|
||||||
|
|
||||||
// Breaks on Windows Server 2019
|
// Breaks on Windows Server 2019
|
||||||
#if TORCH_SERVICE
|
#if TORCH_SERVICE
|
||||||
if (!new ComputerInfo().OSFullName.Contains("Server 2019") && !Environment.UserInteractive)
|
if (!new ComputerInfo().OSFullName.Contains("Server 2019") && !Environment.UserInteractive)
|
||||||
@@ -45,7 +44,7 @@ namespace Torch.Server
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
instancePath = Path.GetFullPath(instanceName);
|
instancePath = Directory.CreateDirectory(instanceName).FullName;
|
||||||
}
|
}
|
||||||
|
|
||||||
var oldTorchCfg = Path.Combine(workingDir, "Torch.cfg");
|
var oldTorchCfg = Path.Combine(workingDir, "Torch.cfg");
|
||||||
@@ -70,6 +69,8 @@ namespace Torch.Server
|
|||||||
if (!initializer.Initialize(args))
|
if (!initializer.Initialize(args))
|
||||||
Environment.Exit(1);
|
Environment.Exit(1);
|
||||||
|
|
||||||
|
TorchLauncher.Launch(workingDir, binDir);
|
||||||
|
|
||||||
CopyNative(binDir);
|
CopyNative(binDir);
|
||||||
initializer.Run(isService, instanceName, instancePath);
|
initializer.Run(isService, instanceName, instancePath);
|
||||||
}
|
}
|
||||||
|
@@ -161,6 +161,5 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Page Remove="Views\WorldSelectControl.xaml" />
|
<Page Remove="Views\WorldSelectControl.xaml" />
|
||||||
<None Include="..\NLog.config" Visible="false" CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="Always" />
|
<None Include="..\NLog.config" Visible="false" CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="Always" />
|
||||||
<None Include="..\Dockerfile" Visible="false" CopyToPublishDirectory="Always" />
|
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
@@ -17,6 +17,7 @@ internal static class GcCollectPatch
|
|||||||
{
|
{
|
||||||
// FUCK YO KEEN
|
// FUCK YO KEEN
|
||||||
// every call results in freeze for seconds
|
// every call results in freeze for seconds
|
||||||
|
|
||||||
private static readonly MethodBase[] _targets =
|
private static readonly MethodBase[] _targets =
|
||||||
{
|
{
|
||||||
Info.OfMethod<MyPlanetTextureMapProvider>(nameof(MyPlanetTextureMapProvider.GetHeightmap)),
|
Info.OfMethod<MyPlanetTextureMapProvider>(nameof(MyPlanetTextureMapProvider.GetHeightmap)),
|
||||||
|
23
appveyor.yml
23
appveyor.yml
@@ -11,7 +11,7 @@ platform: x64
|
|||||||
shallow_clone: true
|
shallow_clone: true
|
||||||
assembly_info:
|
assembly_info:
|
||||||
patch: true
|
patch: true
|
||||||
file: '**\AssemblyInfo.*'
|
file: '**\AssemblyVersion.*'
|
||||||
assembly_version: '{version}'
|
assembly_version: '{version}'
|
||||||
assembly_file_version: '{version}'
|
assembly_file_version: '{version}'
|
||||||
assembly_informational_version: v{version}
|
assembly_informational_version: v{version}
|
||||||
@@ -37,24 +37,21 @@ install:
|
|||||||
|
|
||||||
& "$steamCMDPath/steamcmd.exe" "+login anonymous" "+force_install_dir $steamData" "+app_update 298740" "+quit"
|
& "$steamCMDPath/steamcmd.exe" "+login anonymous" "+force_install_dir $steamData" "+app_update 298740" "+quit"
|
||||||
|
|
||||||
$dataPath = $steamData.Replace("/", "\")
|
$dataPath = $steamData.Replace("/", "\");
|
||||||
|
$contentPath = "$dataPath\Content";
|
||||||
Remove-Item -LiteralPath $dataPath\Content -Force -Recurse
|
if (Test-Path $contentPath) {
|
||||||
|
Remove-Item -LiteralPath $contentPath -Force -Recurse
|
||||||
|
}
|
||||||
|
|
||||||
cmd /S /C mklink /J .\GameBinaries $dataPath\DedicatedServer64
|
cmd /S /C mklink /J .\GameBinaries $dataPath\DedicatedServer64
|
||||||
cache:
|
cache:
|
||||||
- c:\steam\dedi\
|
- c:\steam\dedi\
|
||||||
- c:\steam\cmd\
|
- c:\steam\cmd\
|
||||||
before_build:
|
build_script:
|
||||||
- pwsh: dotnet restore .\Torch.Server\Torch.Server.csproj
|
|
||||||
build:
|
|
||||||
project: Torch.Server/Torch.Server.csproj
|
|
||||||
verbosity: minimal
|
|
||||||
after_build:
|
|
||||||
- pwsh: >-
|
- pwsh: >-
|
||||||
dotnet publish .\Torch.Server\Torch.Server.csproj --self-contained -c Release -o .\publish\ --no-build
|
dotnet publish .\Torch.Server\Torch.Server.csproj --self-contained -f net6-windows -r win-x64 -c Release -o .\publish\
|
||||||
|
|
||||||
Compress-Archive -Path .\publish\ -DestinationPath torch-server.zip
|
Compress-Archive -Path .\publish\* -DestinationPath .\torch-server.zip
|
||||||
artifacts:
|
artifacts:
|
||||||
- path: torch-server.zip
|
- path: torch-server.zip
|
||||||
deploy:
|
deploy:
|
||||||
|
Reference in New Issue
Block a user