feat: SK backlog from test through 2026.11.22.48 (Trade Shop + inventory/loot/chat/nav)
Squash of test/main-merge-2026-10-25 onto aelrynth main 2026.11.19.1 for the standing sk PR. Includes Trade Shop Storefront, loot checklist editor, chat routing, window placements, and related engine work. See Changelog/2026-11-22-sk-backlog-test-merge.md.
This commit is contained in:
parent
3fafd29133
commit
c6e8bb8dbf
438 changed files with 39545 additions and 1271 deletions
|
|
@ -1,38 +1,82 @@
|
|||
#Requires -Version 5.1
|
||||
<#
|
||||
.SYNOPSIS
|
||||
Builds all RynthCore components and produces RynthCore-Setup.exe via Inno Setup.
|
||||
Builds RynthCore + RynthSuite from source and produces the full installer
|
||||
(RynthCore-Setup-<version>.exe) via Inno Setup.
|
||||
|
||||
.DESCRIPTION
|
||||
0. Makes sure a .NET 10 SDK is available; installs one per-user when missing (see -NoDotNetInstall)
|
||||
1. Publishes the Avalonia launcher (self-contained, x86)
|
||||
2+3. The engine and the loader. By default the unloadable engine
|
||||
(docs/UNLOADABLE_ENGINE_PLAN.md): scripts\Publish-EngineCoreClr.ps1 stages the native
|
||||
loader (native\Loader), RynthCore.Shim, the CoreCLR engine (ReadyToRun) and the
|
||||
app-local .NET runtime (Runtime\dotnet) straight into staging\app\Runtime.
|
||||
-NativeAot builds the old NativeAOT engine + loader instead.
|
||||
4. Publishes RynthCore.Plugin.RynthAi (NativeAOT, x86: the release plugins stay NativeAOT
|
||||
- the CoreCLR engine loads them - until the update feed can carry a managed plugin's
|
||||
dependency DLLs)
|
||||
5. Publishes the Loot Editor
|
||||
5b. The headless client (docs/HEADLESS.md, experimental): rynth-headless.exe, a self-contained
|
||||
win-x64 publish of src\RynthCore.Headless.Cli, into {app}\Headless, and the 64-bit managed
|
||||
RynthAi it runs into {app}\Headless\plugins\RynthAi (with its dependencies beside it). The
|
||||
launcher loads those when its HeadlessPluginPaths list is empty. Nothing here touches the
|
||||
x86 plugins in C:\Games\RynthSuite.
|
||||
6. Stages all output under installer\staging\app\, plus the hand-built
|
||||
RynthCore.SehTrampoline.dll and the Decal bridge (DecalBridge\RynthCore.DecalBridge.dll,
|
||||
built here against Decal's reference assemblies), and checks every required file is there
|
||||
7. Invokes ISCC.exe to produce installer\Output\RynthCore-Setup.exe
|
||||
2+3. The engine and the loader (the DLL the launcher injects). By default the unloadable
|
||||
engine (docs/UNLOADABLE_ENGINE_PLAN.md): scripts\Publish-EngineCoreClr.ps1 stages the
|
||||
native loader (native\Loader), RynthCore.Shim, the CoreCLR engine (ReadyToRun) and the
|
||||
app-local .NET runtime (Runtime\dotnet) into staging\core\Runtime; needs Visual Studio's
|
||||
C++ tools. -NativeAot publishes the NativeAOT engine + loader instead (~2 min).
|
||||
4. Publishes RynthCore.Plugin.RynthAi (NativeAOT, x86) from RynthSuite
|
||||
5. Publishes the Loot Editor (self-contained, x86)
|
||||
6. Publishes the Monster Editor (self-contained, x86) from RynthSuite
|
||||
7. Publishes the experimental plugins (RynthChat, RynthJuice, RynthNav, RynthTracker,
|
||||
RynthVision, UbRythai; NativeAOT, x86) -- optional components in the installer
|
||||
8. Stages RynthCore under installer\staging\core\ and RynthSuite under
|
||||
installer\staging\suite\, plus the hand-built RynthCore.SehTrampoline.dll and the
|
||||
Decal bridge (staging\core\DecalBridge, built against Decal's reference assemblies when
|
||||
Decal is installed), and checks every required runtime file is there
|
||||
9. Archives the previous installer (installer\previous-release\) when -Version changes
|
||||
10. Invokes ISCC.exe to produce installer\Output\RynthCore-Setup-<version>.exe
|
||||
(and a RynthCore-Setup.exe copy)
|
||||
11. With -Version: assembles the deployment package installer\Output\Release-<version>\
|
||||
(installer, SHA256SUMS.txt, release-manifest.json with commits + component versions,
|
||||
RELEASE-NOTES.md built from both repos' Changelog folders) and zips it to
|
||||
installer\Output\RynthCore-<version>-deploy.zip, then re-verifies the hashes.
|
||||
Release builds refuse uncommitted changes (see -AllowDirty) so a package always maps
|
||||
to exact commits.
|
||||
|
||||
The installer lets the user choose both the RynthCore and the RynthSuite folders; the
|
||||
code resolves them at runtime from HKA\Software\Rynth (see src\RynthCore.App\RynthInstallPaths.cs).
|
||||
|
||||
.PARAMETER Configuration
|
||||
Build configuration. Default: Release
|
||||
|
||||
.PARAMETER IsccPath
|
||||
Path to ISCC.exe (Inno Setup compiler). Default looks in the standard Inno Setup 6 location.
|
||||
Path to ISCC.exe (Inno Setup compiler). Default looks in the standard Inno Setup 6 locations.
|
||||
Install Inno Setup from: https://jrsoftware.org/isdl.php
|
||||
|
||||
.PARAMETER RynthSuiteRoot
|
||||
RynthSuite repo root. Default: the sibling ..\RynthSuite next to this RynthCore repo.
|
||||
|
||||
.PARAMETER Version
|
||||
Release version yyyy.m.d.n (e.g. 2026.10.4.2). Stamped into the launcher/engine/tools,
|
||||
release.txt and the installer. Omit for a dev build.
|
||||
|
||||
.PARAMETER SkipBuild
|
||||
Skip dotnet publish steps and just re-run ISCC against the existing staging directory.
|
||||
Skip dotnet publish steps and just re-stage + re-run ISCC against existing publish output.
|
||||
|
||||
.PARAMETER NoDotNetInstall
|
||||
Fail instead of auto-installing when no .NET 10 SDK is found. By default a missing SDK is
|
||||
installed per-user (no admin) to %LOCALAPPDATA%\Microsoft\dotnet via Microsoft's signed
|
||||
dotnet-install.ps1, and used for this build.
|
||||
|
||||
.PARAMETER AllowDirty
|
||||
Build a -Version release even when RynthCore or RynthSuite has uncommitted changes to tracked
|
||||
files. The package is still produced but its manifest and notes are flagged "dirty".
|
||||
|
||||
.PARAMETER NoPackage
|
||||
With -Version, stop after the installer .exe (skip the Release-<version> package and zip).
|
||||
|
||||
.PARAMETER NativeAot
|
||||
Build the NativeAOT engine + loader instead of the default unloadable CoreCLR engine.
|
||||
|
||||
.PARAMETER SkipDecalBridge
|
||||
Leave the Decal bridge out even when Decal is installed.
|
||||
|
||||
.PARAMETER IncludeDecalBridge
|
||||
Require the Decal bridge: a missing Decal install fails the build instead of skipping it.
|
||||
|
||||
.PARAMETER DecalDir
|
||||
Decal's install folder, when not the default C:\Program Files (x86)\Decal 3.0.
|
||||
|
||||
.EXAMPLE
|
||||
.\Build-Installer.ps1 -Version 2026.10.4.7
|
||||
#>
|
||||
param(
|
||||
[string]$Configuration = "Release",
|
||||
|
|
@ -40,19 +84,25 @@ param(
|
|||
# Explicit path to the RynthSuite repo root. When omitted, defaults to the
|
||||
# sibling directory of RynthCore (i.e. ..\RynthSuite relative to this repo).
|
||||
[string]$RynthSuiteRoot = "",
|
||||
# Version string injected into the installer (e.g. "0.3"). When omitted,
|
||||
# Explicit path to the RynthServers repo root (rynth's server plugins: RynthILT and one per
|
||||
# server). When omitted, defaults to the sibling directory ..\RynthServers.
|
||||
[string]$RynthServersRoot = "",
|
||||
# Version string injected into the installer (yyyy.m.d.n). When omitted,
|
||||
# the version defined in RynthCore.iss is used as-is.
|
||||
[string]$Version = "",
|
||||
[switch]$SkipBuild,
|
||||
[switch]$NoDotNetInstall,
|
||||
[switch]$AllowDirty,
|
||||
[switch]$NoPackage,
|
||||
# The old NativeAOT engine + loader (a hot reload leaks every engine generation).
|
||||
[switch]$NativeAot,
|
||||
# The Decal bridge (src\RynthCore.DecalBridge, docs/DECAL_BRIDGE_PLAN.md) is staged into
|
||||
# {app}\DecalBridge by default: every release ships it (experimental, opt-in per account;
|
||||
# nothing registers it unless the player picks "Decal + RynthCore"). Building it needs
|
||||
# Decal installed (its public reference assemblies); without Decal this script fails.
|
||||
# -SkipDecalBridge leaves it out (dev builds on a machine without Decal; never a release).
|
||||
# {app}\DecalBridge when Decal is installed (experimental, opt-in per account; nothing
|
||||
# registers it unless the player picks "Decal + RynthCore"). Building it needs Decal's
|
||||
# public reference assemblies; without Decal it is skipped with a warning.
|
||||
# -SkipDecalBridge leaves it out even when Decal is present.
|
||||
[switch]$SkipDecalBridge,
|
||||
# Old opt-in switch, kept so existing command lines still work; the bridge is the default now.
|
||||
# Makes the bridge mandatory: no Decal means a failed build rather than a skipped bridge.
|
||||
[switch]$IncludeDecalBridge,
|
||||
# Decal's install folder, when not the default C:\Program Files (x86)\Decal 3.0.
|
||||
[string]$DecalDir = "",
|
||||
|
|
@ -80,11 +130,66 @@ if ($Version) {
|
|||
$release = [int]$p[0] * 1000000 + [int]$p[1] * 10000 + [int]$p[2] * 100 + [int]$p[3]
|
||||
}
|
||||
|
||||
# Stamp every build with the release, so the launcher, the engine log and the in-game
|
||||
# Status panel show it (RynthCore.App.BuildVersion); the SDK appends the git commit.
|
||||
# Stamp the core builds and tools with the release, so the launcher, the engine log and the
|
||||
# in-game Status panel show it (RynthCore.App.BuildVersion); the SDK appends the git commit.
|
||||
# The RynthAi plugin keeps its own semantic version (RynthCore.Plugin.RynthAi.csproj), so it
|
||||
# is published WITHOUT these args.
|
||||
$VersionArgs = @()
|
||||
if ($Version) { $VersionArgs = @("-p:Version=$Version") }
|
||||
|
||||
# ── .NET 10 SDK check (auto-install when missing) ───────────────────────────
|
||||
# Every project targets net10.0, so publishing needs a .NET 10 SDK. Returns $true when the
|
||||
# 'dotnet' on PATH lists a 10.x SDK.
|
||||
function Test-DotNet10Sdk {
|
||||
$cmd = Get-Command dotnet -ErrorAction SilentlyContinue
|
||||
if (-not $cmd) { return $false }
|
||||
$sdks = & $cmd.Source --list-sdks 2>$null
|
||||
return [bool]($sdks | Where-Object { $_ -match '^10\.' })
|
||||
}
|
||||
|
||||
# Makes a .NET 10 SDK available for this build: uses the one on PATH, else a previous per-user
|
||||
# auto-install, else installs one per-user (no admin) with Microsoft's dotnet-install.ps1, whose
|
||||
# Authenticode signature must verify as Microsoft before it is run.
|
||||
function Initialize-DotNet10Sdk {
|
||||
if (Test-DotNet10Sdk) { Write-Host ".NET 10 SDK: found ($((Get-Command dotnet).Source))"; return }
|
||||
|
||||
$userDotNet = Join-Path $env:LOCALAPPDATA "Microsoft\dotnet"
|
||||
if (Test-Path (Join-Path $userDotNet "dotnet.exe")) {
|
||||
$env:DOTNET_ROOT = $userDotNet
|
||||
$env:PATH = "$userDotNet;$env:PATH"
|
||||
if (Test-DotNet10Sdk) { Write-Host ".NET 10 SDK: found per-user install ($userDotNet)"; return }
|
||||
}
|
||||
|
||||
if ($NoDotNetInstall) {
|
||||
throw "No .NET 10 SDK found. Install it from https://dotnet.microsoft.com/download/dotnet/10.0 or re-run without -NoDotNetInstall."
|
||||
}
|
||||
|
||||
Write-Host ""
|
||||
Write-Host ".NET 10 SDK not found -- installing it per-user to $userDotNet ..." -ForegroundColor Yellow
|
||||
$installScript = Join-Path $env:TEMP "dotnet-install.ps1"
|
||||
[Net.ServicePointManager]::SecurityProtocol = [Net.ServicePointManager]::SecurityProtocol -bor [Net.SecurityProtocolType]::Tls12
|
||||
Invoke-WebRequest -Uri "https://dot.net/v1/dotnet-install.ps1" -OutFile $installScript -UseBasicParsing
|
||||
$sig = Get-AuthenticodeSignature $installScript
|
||||
if ($sig.Status -ne 'Valid' -or $sig.SignerCertificate.Subject -notmatch 'O=Microsoft Corporation') {
|
||||
Remove-Item $installScript -Force -ErrorAction SilentlyContinue
|
||||
throw "dotnet-install.ps1 signature check failed ($($sig.Status)); not running it."
|
||||
}
|
||||
|
||||
# Separate process so the script runs under Bypass regardless of this session's execution policy.
|
||||
& powershell -NoProfile -ExecutionPolicy Bypass -File $installScript -Channel 10.0 -InstallDir $userDotNet
|
||||
$installExit = $LASTEXITCODE
|
||||
Remove-Item $installScript -Force -ErrorAction SilentlyContinue
|
||||
if ($installExit -ne 0) { throw "dotnet-install.ps1 failed (exit $installExit)" }
|
||||
|
||||
$env:DOTNET_ROOT = $userDotNet
|
||||
$env:PATH = "$userDotNet;$env:PATH"
|
||||
if (-not (Test-DotNet10Sdk)) { throw ".NET 10 SDK install finished but 'dotnet --list-sdks' still shows no 10.x SDK." }
|
||||
Write-Host ".NET 10 SDK: installed ($userDotNet)" -ForegroundColor Green
|
||||
}
|
||||
|
||||
# Only the publish steps need the SDK; -SkipBuild just re-stages and re-runs ISCC.
|
||||
if (-not $SkipBuild) { Initialize-DotNet10Sdk }
|
||||
|
||||
$ScriptDir = $PSScriptRoot
|
||||
$RepoRoot = Split-Path $ScriptDir -Parent # e.g. C:\Projects\RynthCore
|
||||
$ProjectsRoot = Split-Path $RepoRoot -Parent # e.g. C:\Projects
|
||||
|
|
@ -93,31 +198,95 @@ $ProjectsRoot = Split-Path $RepoRoot -Parent # e.g. C:\Projects
|
|||
if (-not $RynthSuiteRoot) {
|
||||
$RynthSuiteRoot = "$ProjectsRoot\RynthSuite"
|
||||
}
|
||||
# RynthServers root (server plugins since 2026-10-21): explicit param, else the sibling convention.
|
||||
if (-not $RynthServersRoot) {
|
||||
$RynthServersRoot = "$ProjectsRoot\RynthServers"
|
||||
}
|
||||
|
||||
$LauncherProject = "$RepoRoot\src\RynthCore.App.Avalonia\RynthCore.App.Avalonia.csproj"
|
||||
$EngineProject = "$RepoRoot\src\RynthCore.Engine\RynthCore.Engine.csproj"
|
||||
$LoaderProject = "$RepoRoot\src\RynthCore.Loader\RynthCore.Loader.csproj"
|
||||
$PluginProject = "$RynthSuiteRoot\Plugins\RynthCore.Plugin.RynthAi\RynthCore.Plugin.RynthAi.csproj"
|
||||
$LootEditorProject = "$RynthSuiteRoot\Tools\RynthCore.LootEditor\RynthCore.LootEditor.csproj"
|
||||
$HeadlessProject = "$RepoRoot\src\RynthCore.Headless.Cli\RynthCore.Headless.Cli.csproj"
|
||||
# ── Source state (release builds) ───────────────────────────────────────────
|
||||
# A deployment package must map to exact commits. Tracked changes outside
|
||||
# installer\previous-release\ (whose version marker this script rewrites) block a -Version
|
||||
# build unless -AllowDirty; untracked files are ignored, as in Publish-Update.ps1.
|
||||
function Get-RepoState([string]$Repo) {
|
||||
$ErrorActionPreference = 'Continue' # native stderr must not become a terminating error on 5.1
|
||||
$dirty = @(git -C $Repo status --porcelain --untracked-files=no 2>$null |
|
||||
Where-Object { $_ -and $_.Substring(3) -notlike 'installer/previous-release/*' })
|
||||
[ordered]@{
|
||||
path = $Repo
|
||||
branch = (git -C $Repo rev-parse --abbrev-ref HEAD 2>$null)
|
||||
commit = (git -C $Repo rev-parse HEAD 2>$null)
|
||||
dirty = ($dirty.Count -gt 0)
|
||||
changes = $dirty
|
||||
}
|
||||
}
|
||||
$CoreState = Get-RepoState $RepoRoot
|
||||
$SuiteState = Get-RepoState $RynthSuiteRoot
|
||||
if ($Version -and -not $NoPackage) {
|
||||
foreach ($s in $CoreState, $SuiteState) {
|
||||
if (-not $s.commit) { throw "Not a git checkout: $($s.path) (a release package records exact commits)." }
|
||||
if ($s.dirty -and -not $AllowDirty) {
|
||||
throw "$($s.path) has uncommitted changes -- commit them or pass -AllowDirty:`n $($s.changes -join "`n ")"
|
||||
}
|
||||
}
|
||||
Write-Host "Source: RynthCore $($CoreState.branch)@$($CoreState.commit.Substring(0,7)), RynthSuite $($SuiteState.branch)@$($SuiteState.commit.Substring(0,7))$(if ($CoreState.dirty -or $SuiteState.dirty) { ' (DIRTY)' })"
|
||||
}
|
||||
|
||||
$LauncherPublish = "$RepoRoot\src\RynthCore.App.Avalonia\bin\$Configuration\net10.0-windows7.0\win-x86\publish"
|
||||
$EnginePublish = "$RepoRoot\src\RynthCore.Engine\bin\$Configuration\net10.0-windows\win-x86\publish"
|
||||
$LoaderPublish = "$RepoRoot\src\RynthCore.Loader\bin\$Configuration\net10.0-windows\win-x86\publish"
|
||||
$PluginPublish = "$RynthSuiteRoot\Plugins\RynthCore.Plugin.RynthAi\bin\$Configuration\net10.0-windows\win-x86\publish"
|
||||
$LootEditorPublish = "$RynthSuiteRoot\Tools\RynthCore.LootEditor\bin\$Configuration\net10.0\win-x86\publish"
|
||||
# The headless builds (x64) keep their intermediates in their own artifacts folders, apart from the
|
||||
# x86 builds of the same projects (RynthCore.PluginSdk, RynthAi), and publish here (artifacts\ is ignored).
|
||||
$HeadlessBuildRoot = "$RepoRoot\artifacts\headless"
|
||||
$HeadlessPublish = "$HeadlessBuildRoot\rynth-headless"
|
||||
$HeadlessPluginsPublish = "$HeadlessBuildRoot\plugins"
|
||||
# The 64-bit plugins the headless client gets: <Name> -> project. Only RynthAi for now.
|
||||
$HeadlessPlugins = [ordered]@{ RynthAi = $PluginProject }
|
||||
$LauncherProject = "$RepoRoot\src\RynthCore.App.Avalonia\RynthCore.App.Avalonia.csproj"
|
||||
$EngineProject = "$RepoRoot\src\RynthCore.Engine\RynthCore.Engine.csproj"
|
||||
$LoaderProject = "$RepoRoot\src\RynthCore.Loader\RynthCore.Loader.csproj"
|
||||
$PluginProject = "$RynthSuiteRoot\Plugins\RynthCore.Plugin.RynthAi\RynthCore.Plugin.RynthAi.csproj"
|
||||
$LootEditorProject = "$RynthSuiteRoot\Tools\RynthCore.LootEditor\RynthCore.LootEditor.csproj"
|
||||
$MonsterEditorProject = "$RynthSuiteRoot\Tools\RynthCore.MonsterEditor\RynthCore.MonsterEditor.csproj"
|
||||
|
||||
$StagingDir = "$ScriptDir\staging\app"
|
||||
$LauncherPublish = "$RepoRoot\src\RynthCore.App.Avalonia\bin\$Configuration\net10.0-windows7.0\win-x86\publish"
|
||||
$EnginePublish = "$RepoRoot\src\RynthCore.Engine\bin\$Configuration\net10.0-windows\win-x86\publish"
|
||||
$LoaderPublish = "$RepoRoot\src\RynthCore.Loader\bin\$Configuration\net10.0-windows\win-x86\publish"
|
||||
$PluginPublish = "$RynthSuiteRoot\Plugins\RynthCore.Plugin.RynthAi\bin\$Configuration\net10.0-windows\win-x86\publish"
|
||||
$LootEditorPublish = "$RynthSuiteRoot\Tools\RynthCore.LootEditor\bin\$Configuration\net10.0\win-x86\publish"
|
||||
$MonsterEditorPublish = "$RynthSuiteRoot\Tools\RynthCore.MonsterEditor\bin\$Configuration\net10.0\win-x86\publish"
|
||||
|
||||
# Experimental RynthSuite plugins (optional installer components). Each installs to
|
||||
# <RynthSuite>\<Name>\RynthCore.Plugin.<Name>.dll. One with a <Version> in its csproj keeps that
|
||||
# semantic version; the rest take the release calver (Test-OwnVersion).
|
||||
$ExperimentalPlugins = @('RynthChat', 'RynthJuice', 'RynthNav', 'RynthTracker', 'RynthVision', 'UbRythai')
|
||||
# Project folders that don't follow Plugins\RynthCore.Plugin.<Name>\ (ub-Rythai keeps its own sub-tree).
|
||||
$ExperimentalProjectDirs = @{ 'UbRythai' = "$RynthSuiteRoot\Plugins\ub-Rythai\RynthCore.Plugin.UbRythai" }
|
||||
function Get-ExperimentalDir([string]$Name) {
|
||||
if ($ExperimentalProjectDirs.ContainsKey($Name)) { return $ExperimentalProjectDirs[$Name] }
|
||||
# RynthILT and the per-server plugins live in RynthServers (rynth, 2026-10-21).
|
||||
if ($Name -eq 'RynthILT' -or $ServerPlugins -contains $Name) { return "$RynthServersRoot\Plugins\RynthCore.Plugin.$Name" }
|
||||
return "$RynthSuiteRoot\Plugins\RynthCore.Plugin.$Name"
|
||||
}
|
||||
function Get-ExperimentalProject([string]$Name) { "$(Get-ExperimentalDir $Name)\RynthCore.Plugin.$Name.csproj" }
|
||||
# Only a plugin whose csproj sets its own <Version> (RynthJuice, UbRythai) keeps it; the others
|
||||
# (RynthNav, RynthChat, RynthTracker, RynthVision) would read 1.0.0, so they get the release calver.
|
||||
function Test-OwnVersion([string]$Name) { [bool](Select-String -Path (Get-ExperimentalProject $Name) -Pattern '<Version>' -Quiet) }
|
||||
function Get-ExperimentalPublish([string]$Name) { "$(Get-ExperimentalDir $Name)\bin\$Configuration\net10.0-windows\win-x86\publish" }
|
||||
|
||||
# RynthSuite companion plugins (installer components, on in a Full install). Same layout as the
|
||||
# experimental ones: <RynthSuite>\<Name>\RynthCore.Plugin.<Name>.dll, from Plugins\RynthCore.Plugin.<Name>\.
|
||||
# They carry no <Version> of their own, so they get the release calver (-p:Version) like the engine.
|
||||
# Server plugins (RynthServers): installed with the suite and registered with the launcher; RynthCore
|
||||
# loads only the one for the server you connect to (PluginManifestGate), so each one's features show
|
||||
# only on its own server. RynthILT is the Infinite Leaftide one.
|
||||
$ServerPlugins = @('RynthAChard', 'RynthAelrynth', 'RynthColdeve', 'RynthConquest', 'RynthDerptide', 'RynthDreamWeave', 'RynthEversong', 'RynthFrostACE', 'RynthFrostcull', 'RynthLeafDawn', 'RynthLeafdawning', 'RynthLevistras', 'RynthPortalStorm', 'RynthReefcull', 'RynthSundering', 'RynthThistlecrown', 'RynthThreads')
|
||||
$SuitePlugins = @('RynthOracle', 'RynthILT', 'RynthInventory', 'RynthSort') + $ServerPlugins
|
||||
# RynthNav's starter portal list (shipped into <RynthCore>\NavData, never overwritten).
|
||||
$NavPortalsTsv = "$RynthSuiteRoot\Tools\RynthNav.PortalGraph\Data\portals.tsv"
|
||||
|
||||
# staging\core → {app} (user-chosen RynthCore folder)
|
||||
# staging\suite → {code:GetSuiteDir} (user-chosen RynthSuite folder)
|
||||
$StagingRoot = "$ScriptDir\staging"
|
||||
$CoreStaging = "$StagingRoot\core"
|
||||
$SuiteStaging = "$StagingRoot\suite"
|
||||
|
||||
# ── Validate projects ───────────────────────────────────────────────────────
|
||||
foreach ($p in @($LauncherProject, $EngineProject, $PluginProject, $LootEditorProject, $HeadlessProject) + @(if ($NativeAot) { $LoaderProject })) {
|
||||
# The managed loader project is only built for -NativeAot; the default uses the native C loader.
|
||||
$allProjects = @($LauncherProject, $EngineProject, $PluginProject, $LootEditorProject, $MonsterEditorProject) +
|
||||
@(if ($NativeAot) { $LoaderProject }) +
|
||||
@($ExperimentalPlugins | ForEach-Object { Get-ExperimentalProject $_ }) +
|
||||
@($SuitePlugins | ForEach-Object { Get-ExperimentalProject $_ })
|
||||
foreach ($p in $allProjects) {
|
||||
if (-not (Test-Path $p)) {
|
||||
throw "Project not found: $p`nUpdate paths in Build-Installer.ps1 if your repo layout differs."
|
||||
}
|
||||
|
|
@ -126,54 +295,71 @@ foreach ($p in @($LauncherProject, $EngineProject, $PluginProject, $LootEditorPr
|
|||
if (-not $SkipBuild) {
|
||||
# ── 1. Launcher (self-contained Avalonia WinExe) ─────────────────────────
|
||||
Write-Host ""
|
||||
Write-Host "[1/5] Publishing Launcher (self-contained, x86)..." -ForegroundColor Cyan
|
||||
Write-Host "[1/7] Publishing Launcher (self-contained, x86)..." -ForegroundColor Cyan
|
||||
dotnet publish $LauncherProject -c $Configuration -r win-x86 --self-contained true @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Launcher publish failed (exit $LASTEXITCODE)" }
|
||||
|
||||
if ($NativeAot) {
|
||||
# ── 2. Engine (NativeAOT — the slow one) ──────────────────────────────
|
||||
Write-Host ""
|
||||
Write-Host "[2/5] Publishing Engine (NativeAOT, ~2 min)..." -ForegroundColor Cyan
|
||||
Write-Host "[2/7] Publishing Engine (NativeAOT, ~2 min)..." -ForegroundColor Cyan
|
||||
dotnet publish $EngineProject -c $Configuration @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Engine publish failed (exit $LASTEXITCODE)" }
|
||||
|
||||
# ── 3. Loader (NativeAOT, small) ──────────────────────────────────────
|
||||
Write-Host ""
|
||||
Write-Host "[3/5] Publishing Loader (NativeAOT)..." -ForegroundColor Cyan
|
||||
Write-Host "[3/7] Publishing Loader (NativeAOT)..." -ForegroundColor Cyan
|
||||
dotnet publish $LoaderProject -c $Configuration @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Loader publish failed (exit $LASTEXITCODE)" }
|
||||
}
|
||||
# (Default: the CoreCLR engine and native loader are built straight into staging below.)
|
||||
|
||||
# ── 4. Plugin (NativeAOT; a managed RynthAi from Publish-Update replaces it) ──
|
||||
# ── 4. RynthAi plugin (NativeAOT; keeps its own version; a managed RynthAi from Publish-Update replaces it) ──
|
||||
if (-not $RynthAiDll) {
|
||||
Write-Host ""
|
||||
Write-Host "[4/5] Publishing Plugin (NativeAOT)..." -ForegroundColor Cyan
|
||||
Write-Host "[4/7] Publishing RynthAi plugin (NativeAOT)..." -ForegroundColor Cyan
|
||||
# Its plugin version is RynthAiVersionCommand.HandWrittenVersion; the DLL's ProductVersion
|
||||
# takes the release calver so an installed file never reads 1.0.0.
|
||||
dotnet publish $PluginProject -c $Configuration @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Plugin publish failed (exit $LASTEXITCODE)" }
|
||||
}
|
||||
|
||||
# ── 5. Loot Editor (self-contained Avalonia tool) ─────────────────────────
|
||||
Write-Host ""
|
||||
Write-Host "[5/5] Publishing Loot Editor (self-contained, x86)..." -ForegroundColor Cyan
|
||||
Write-Host "[5/7] Publishing Loot Editor (self-contained, x86)..." -ForegroundColor Cyan
|
||||
dotnet publish $LootEditorProject -c $Configuration -r win-x86 --self-contained true @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Loot Editor publish failed (exit $LASTEXITCODE)" }
|
||||
|
||||
# ── 5b. Headless client (self-contained x64) + its 64-bit plugins ─────────
|
||||
# rynth-headless is a 64-bit process with its own .NET runtime (Runtime\dotnet is x86). The
|
||||
# plugins it hosts are managed x64 builds of the release plugins, made with command-line
|
||||
# overrides only (docs/HEADLESS.md, "Running RynthAi"); each gets its dependencies beside it.
|
||||
# ── 6. Monster Editor (self-contained Avalonia tool) ──────────────────────
|
||||
Write-Host ""
|
||||
Write-Host "[5b/5] Publishing the headless client (self-contained, x64) and its x64 plugins..." -ForegroundColor Cyan
|
||||
if (Test-Path $HeadlessBuildRoot) { Remove-Item $HeadlessBuildRoot -Recurse -Force }
|
||||
dotnet publish $HeadlessProject -c $Configuration -r win-x64 --self-contained true `
|
||||
--artifacts-path "$HeadlessBuildRoot\art-cli" -o $HeadlessPublish -nologo -v q @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Headless client publish failed (exit $LASTEXITCODE)" }
|
||||
foreach ($name in $HeadlessPlugins.Keys) {
|
||||
dotnet publish $HeadlessPlugins[$name] -c $Configuration "-p:PublishAot=false" "-p:NativeLib=" "-p:SelfContained=false" `
|
||||
"-p:PlatformTarget=x64" "-p:RuntimeIdentifier=win-x64" "-p:Platforms=x64" "-p:GenerateRuntimeConfigurationFiles=false" `
|
||||
"-p:RynthPluginSharedSdk=true" --artifacts-path "$HeadlessBuildRoot\art-$name" -o "$HeadlessPluginsPublish\$name" -nologo -v q @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Headless (x64) $name publish failed (exit $LASTEXITCODE)" }
|
||||
Write-Host "[6/7] Publishing Monster Editor (self-contained, x86)..." -ForegroundColor Cyan
|
||||
dotnet publish $MonsterEditorProject -c $Configuration -r win-x86 --self-contained true @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Monster Editor publish failed (exit $LASTEXITCODE)" }
|
||||
|
||||
# ── 7. Experimental plugins (NativeAOT; optional components) ──────────────
|
||||
# RynthJuice/RynthNav/RynthVision set <PublishDir> to the live C:\Games\RynthSuite\<Name>\
|
||||
# folder for dev hot-reload; override it so an installer build never touches a live install.
|
||||
# A trailing '/' (not '\') keeps the argument intact when the path contains spaces.
|
||||
Write-Host ""
|
||||
Write-Host "[7/7] Publishing experimental plugins (NativeAOT)..." -ForegroundColor Cyan
|
||||
foreach ($name in $ExperimentalPlugins) {
|
||||
$ownVersion = Test-OwnVersion $name
|
||||
Write-Host " $name$(if ($ownVersion) { ' (own version)' } else { '' })"
|
||||
$publishDir = (Get-ExperimentalPublish $name) + '/'
|
||||
# @(...) keeps it an array: a bare if/else unrolls one item to a string, which splats char by char.
|
||||
$pluginVersionArgs = @(if (-not $ownVersion) { $VersionArgs })
|
||||
dotnet publish (Get-ExperimentalProject $name) -c $Configuration "-p:PublishDir=$publishDir" @pluginVersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "$name publish failed (exit $LASTEXITCODE)" }
|
||||
}
|
||||
|
||||
# ── 7b. RynthSuite companion plugins (NativeAOT; release calver) ──────────
|
||||
Write-Host ""
|
||||
Write-Host "[7b/7] Publishing RynthSuite plugins (NativeAOT)..." -ForegroundColor Cyan
|
||||
foreach ($name in $SuitePlugins) {
|
||||
Write-Host " $name"
|
||||
$publishDir = (Get-ExperimentalPublish $name) + '/'
|
||||
dotnet publish (Get-ExperimentalProject $name) -c $Configuration "-p:PublishDir=$publishDir" @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "$name publish failed (exit $LASTEXITCODE)" }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -181,32 +367,38 @@ if (-not $SkipBuild) {
|
|||
Write-Host ""
|
||||
Write-Host "Staging files..." -ForegroundColor Cyan
|
||||
|
||||
if (Test-Path "$ScriptDir\staging") {
|
||||
Remove-Item "$ScriptDir\staging" -Recurse -Force
|
||||
if (Test-Path $StagingRoot) {
|
||||
Remove-Item $StagingRoot -Recurse -Force
|
||||
}
|
||||
New-Item -ItemType Directory -Path "$CoreStaging\Runtime\Native" -Force | Out-Null
|
||||
New-Item -ItemType Directory -Path "$CoreStaging\Tools\LootEditor" -Force | Out-Null
|
||||
New-Item -ItemType Directory -Path "$SuiteStaging\RynthAi\MonsterEditor" -Force | Out-Null
|
||||
|
||||
# Copies a publish folder (files + subfolders) without .pdb files.
|
||||
function Copy-PublishTree([string]$Source, [string]$Dest) {
|
||||
if (-not (Test-Path $Source)) { throw "Publish output not found: $Source" }
|
||||
foreach ($file in (Get-ChildItem $Source -File)) {
|
||||
if ($file.Extension -eq '.pdb') { continue }
|
||||
Copy-Item $file.FullName (Join-Path $Dest $file.Name) -Force
|
||||
}
|
||||
foreach ($dir in (Get-ChildItem $Source -Directory)) {
|
||||
Copy-Item $dir.FullName $Dest -Recurse -Force
|
||||
Get-ChildItem (Join-Path $Dest $dir.Name) -Recurse -File -Filter '*.pdb' | Remove-Item -Force
|
||||
}
|
||||
}
|
||||
New-Item -ItemType Directory -Path "$StagingDir\Runtime\Native" -Force | Out-Null
|
||||
New-Item -ItemType Directory -Path "$StagingDir\Tools\LootEditor" -Force | Out-Null
|
||||
# Plugin DLLs are staged into a separate top-level folder (not under
|
||||
# Runtime\) because the engine no longer auto-scans Runtime\Plugins\.
|
||||
# The .iss file installs this folder to C:\Games\RynthSuite\<PluginName>\
|
||||
# (an absolute destination outside {app}) so the plugin lives next to its
|
||||
# data dirs and the user adds the path via the launcher's Plugins tab.
|
||||
$pluginStagingDir = "$ScriptDir\staging\plugins"
|
||||
if (Test-Path $pluginStagingDir) { Remove-Item $pluginStagingDir -Recurse -Force }
|
||||
New-Item -ItemType Directory -Path "$pluginStagingDir\RynthAi" -Force | Out-Null
|
||||
|
||||
# Launcher root files (rename .exe → RynthCore.exe; drop .pdb)
|
||||
foreach ($file in (Get-ChildItem "$LauncherPublish" -File)) {
|
||||
if ($file.Extension -eq '.pdb') { continue }
|
||||
$destName = if ($file.Name -eq 'RynthCore.App.Avalonia.exe') { 'RynthCore.exe' } else { $file.Name }
|
||||
Copy-Item $file.FullName "$StagingDir\$destName" -Force
|
||||
Copy-Item $file.FullName "$CoreStaging\$destName" -Force
|
||||
}
|
||||
|
||||
if ($NativeAot) {
|
||||
# Engine runtime files (into Runtime\, skip .pdb)
|
||||
foreach ($file in (Get-ChildItem "$EnginePublish" -File)) {
|
||||
if ($file.Extension -eq '.pdb') { continue }
|
||||
Copy-Item $file.FullName "$StagingDir\Runtime\$($file.Name)" -Force
|
||||
Copy-Item $file.FullName "$CoreStaging\Runtime\$($file.Name)" -Force
|
||||
}
|
||||
|
||||
# Loader — the DLL the launcher injects (EngineInjectionService.EngineDllName); it
|
||||
|
|
@ -214,17 +406,17 @@ if ($NativeAot) {
|
|||
# launcher can't auto-find an engine to inject.
|
||||
$loaderDll = "$LoaderPublish\RynthCore.Loader.dll"
|
||||
if (-not (Test-Path $loaderDll)) { throw "Loader DLL not found at: $loaderDll" }
|
||||
Copy-Item $loaderDll "$StagingDir\Runtime\" -Force
|
||||
Copy-Item $loaderDll "$CoreStaging\Runtime\" -Force
|
||||
} else {
|
||||
# The unloadable engine: native loader (same RynthCoreInit contract with the launcher's
|
||||
# injector), RynthCore.Shim, the CoreCLR engine (ReadyToRun) + its dependencies, and
|
||||
# Runtime\dotnet (the app-local x86 .NET runtime). Needs Visual Studio's C++ tools (cl.exe)
|
||||
# for the loader, like the SEH trampoline.
|
||||
Write-Host ""
|
||||
Write-Host "[2+3/5] Building the unloadable engine + native loader into staging..." -ForegroundColor Cyan
|
||||
& "$RepoRoot\scripts\Publish-EngineCoreClr.ps1" -Target "$StagingDir\Runtime" -Configuration $Configuration -MsBuildArgs $VersionArgs
|
||||
Write-Host "[2+3/7] Building the unloadable engine + native loader into staging..." -ForegroundColor Cyan
|
||||
& "$RepoRoot\scripts\Publish-EngineCoreClr.ps1" -Target "$CoreStaging\Runtime" -Configuration $Configuration -MsBuildArgs $VersionArgs
|
||||
# Keep the engine's pdb (its stack traces get line numbers); drop the loader's and shim's.
|
||||
Remove-Item "$StagingDir\Runtime\RynthCore.Loader.pdb", "$StagingDir\Runtime\RynthCore.Shim.pdb" -Force -ErrorAction SilentlyContinue
|
||||
Remove-Item "$CoreStaging\Runtime\RynthCore.Loader.pdb", "$CoreStaging\Runtime\RynthCore.Shim.pdb" -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
# SEH trampoline — hand-built native DLL (native\SehTrampoline\Build-SehTrampoline.ps1),
|
||||
|
|
@ -235,82 +427,113 @@ if ($NativeAot) {
|
|||
$sehDll = "$RepoRoot\native\SehTrampoline\bin\RynthCore.SehTrampoline.dll"
|
||||
$sehSrc = "$RepoRoot\native\SehTrampoline\SehTrampoline.c"
|
||||
if (-not (Test-Path $sehDll)) { throw "SEH trampoline not found at: $sehDll`nBuild it with native\SehTrampoline\Build-SehTrampoline.ps1" }
|
||||
if ((Test-Path $sehSrc) -and (Get-Item $sehSrc).LastWriteTime -gt (Get-Item $sehDll).LastWriteTime) {
|
||||
# Source "age": checkouts and merges rewrite SehTrampoline.c and bump its mtime without changing it,
|
||||
# so when the file matches HEAD its last commit time is used; local edits fall back to the mtime.
|
||||
function Get-SehSourceTime {
|
||||
$ErrorActionPreference = 'Continue'
|
||||
$srcTime = (Get-Item $sehSrc).LastWriteTime
|
||||
git -C $RepoRoot diff --quiet HEAD -- "native/SehTrampoline/SehTrampoline.c" 2>$null
|
||||
if ($LASTEXITCODE -eq 0) {
|
||||
$ct = git -C $RepoRoot log -1 --format=%ct -- "native/SehTrampoline/SehTrampoline.c" 2>$null
|
||||
if ($ct -match '^\d+$') { $srcTime = [DateTimeOffset]::FromUnixTimeSeconds([long]$ct).LocalDateTime }
|
||||
}
|
||||
$srcTime
|
||||
}
|
||||
if ((Test-Path $sehSrc) -and (Get-SehSourceTime) -gt (Get-Item $sehDll).LastWriteTime) {
|
||||
throw "RynthCore.SehTrampoline.dll is STALE (SehTrampoline.c is newer). Rebuild with native\SehTrampoline\Build-SehTrampoline.ps1"
|
||||
}
|
||||
Copy-Item $sehDll "$StagingDir\Runtime\" -Force
|
||||
Copy-Item $sehDll "$CoreStaging\Runtime\" -Force
|
||||
|
||||
# DXVK x32 cache (optional launcher "Enable DXVK"): seed Runtime\dxvk so a fresh
|
||||
# install can toggle without GitHub. Prefer a local drop-in stage, else fetch latest.
|
||||
$dxvkDest = "$CoreStaging\Runtime\dxvk"
|
||||
$dxvkBuild = "C:\Games\RynthCore\build\dxvk-dropin\extract"
|
||||
Write-Host "Seeding Runtime\dxvk (x32 d3d9 for launcher Enable DXVK)..." -ForegroundColor Cyan
|
||||
New-Item -ItemType Directory -Force -Path $dxvkDest | Out-Null
|
||||
$seeded = $false
|
||||
if (Test-Path "$dxvkBuild") {
|
||||
$localDll = Get-ChildItem $dxvkBuild -Recurse -Filter "d3d9.dll" -ErrorAction SilentlyContinue |
|
||||
Where-Object { $_.Directory.Name -eq "x32" } | Select-Object -First 1
|
||||
if ($localDll) {
|
||||
$verFile = Join-Path $localDll.Directory.Parent.FullName ".." # unused; read from folder name
|
||||
$folderVer = if ($localDll.Directory.Parent.Name -match 'dxvk-(\d+\.\d+\.\d+)') { $Matches[1] } else { "local" }
|
||||
Copy-Item $localDll.FullName "$dxvkDest\d3d9.dll" -Force
|
||||
$utf8 = New-Object System.Text.UTF8Encoding $false
|
||||
[IO.File]::WriteAllText("$dxvkDest\version.txt", $folderVer, $utf8)
|
||||
$seeded = $true
|
||||
Write-Host " Seeded from build drop-in ($folderVer)."
|
||||
}
|
||||
}
|
||||
if (-not $seeded -and (Test-Path "C:\Games\RynthCore\Runtime\dxvk\d3d9.dll")) {
|
||||
Copy-Item "C:\Games\RynthCore\Runtime\dxvk\*" $dxvkDest -Force
|
||||
$seeded = $true
|
||||
Write-Host " Seeded from live Runtime\dxvk."
|
||||
}
|
||||
if (-not $seeded) {
|
||||
try {
|
||||
& "$RepoRoot\scripts\Fetch-Dxvk.ps1" -Target $dxvkDest
|
||||
$seeded = $true
|
||||
}
|
||||
catch {
|
||||
Write-Warning "DXVK seed skipped (fetch failed): $($_.Exception.Message). Launcher can still Fetch at runtime."
|
||||
}
|
||||
}
|
||||
|
||||
# Engine Native subfolder (NativeAOT layout)
|
||||
if ($NativeAot -and (Test-Path "$EnginePublish\Native")) {
|
||||
foreach ($file in (Get-ChildItem "$EnginePublish\Native" -File)) {
|
||||
if ($file.Extension -eq '.pdb') { continue }
|
||||
Copy-Item $file.FullName "$StagingDir\Runtime\Native\$($file.Name)" -Force
|
||||
Copy-Item $file.FullName "$CoreStaging\Runtime\Native\$($file.Name)" -Force
|
||||
}
|
||||
}
|
||||
|
||||
# Plugin DLL only — staged separately so the .iss file can install it to an
|
||||
# absolute path outside {app}. The engine no longer auto-scans Runtime\Plugins\;
|
||||
# the user explicitly adds the plugin path via the launcher's Plugins tab.
|
||||
# Loot Editor → <RynthCore>\Tools\LootEditor (the launcher/engine look for it there)
|
||||
Copy-PublishTree $LootEditorPublish "$CoreStaging\Tools\LootEditor"
|
||||
|
||||
# RynthAi plugin DLL → <RynthSuite>\RynthAi (next to its data dirs; the installer hands the
|
||||
# path to the launcher via HKA\Software\Rynth\PendingPluginRegistration).
|
||||
$pluginDll = if ($RynthAiDll) { $RynthAiDll } else { "$PluginPublish\RynthCore.Plugin.RynthAi.dll" }
|
||||
if (-not (Test-Path $pluginDll)) { throw "Plugin DLL not found at: $pluginDll" }
|
||||
Copy-Item $pluginDll "$pluginStagingDir\RynthAi\" -Force
|
||||
Copy-Item $pluginDll "$SuiteStaging\RynthAi\" -Force
|
||||
|
||||
# The managed plugins' common dependencies (engine API 88: ManagedPlugins looks in Runtime\PluginShared).
|
||||
if ($PluginSharedDir) {
|
||||
if (-not (Test-Path $PluginSharedDir)) { throw "PluginShared folder not found at: $PluginSharedDir" }
|
||||
New-Item -ItemType Directory -Path "$StagingDir\Runtime\PluginShared" -Force | Out-Null
|
||||
Copy-Item "$PluginSharedDir\*" "$StagingDir\Runtime\PluginShared\" -Force
|
||||
Write-Host " Runtime\PluginShared: $((Get-ChildItem "$StagingDir\Runtime\PluginShared" -File).Count) file(s)"
|
||||
New-Item -ItemType Directory -Path "$CoreStaging\Runtime\PluginShared" -Force | Out-Null
|
||||
Copy-Item "$PluginSharedDir\*" "$CoreStaging\Runtime\PluginShared\" -Force
|
||||
Write-Host " Runtime\PluginShared: $((Get-ChildItem "$CoreStaging\Runtime\PluginShared" -File).Count) file(s)"
|
||||
}
|
||||
|
||||
# Loot Editor (self-contained — copy everything from publish, drop pdbs)
|
||||
if (-not (Test-Path $LootEditorPublish)) { throw "Loot Editor publish not found at: $LootEditorPublish" }
|
||||
foreach ($file in (Get-ChildItem "$LootEditorPublish" -File)) {
|
||||
if ($file.Extension -eq '.pdb') { continue }
|
||||
Copy-Item $file.FullName "$StagingDir\Tools\LootEditor\$($file.Name)" -Force
|
||||
}
|
||||
foreach ($dir in (Get-ChildItem "$LootEditorPublish" -Directory)) {
|
||||
Copy-Item $dir.FullName "$StagingDir\Tools\LootEditor\" -Recurse -Force
|
||||
# Drop pdbs from copied subdirs
|
||||
Get-ChildItem "$StagingDir\Tools\LootEditor\$($dir.Name)" -Recurse -File -Filter '*.pdb' | Remove-Item -Force
|
||||
# Monster Editor → <RynthSuite>\RynthAi\MonsterEditor (RynthAi's dashboard launches it from there)
|
||||
Copy-PublishTree $MonsterEditorPublish "$SuiteStaging\RynthAi\MonsterEditor"
|
||||
|
||||
# Experimental plugins → <RynthSuite>\<Name>\RynthCore.Plugin.<Name>.dll (the NativeAOT DLL is self-contained;
|
||||
# cimgui.dll is provided by the engine's Runtime folder).
|
||||
foreach ($name in @($ExperimentalPlugins) + @($SuitePlugins)) {
|
||||
$dll = Join-Path (Get-ExperimentalPublish $name) "RynthCore.Plugin.$name.dll"
|
||||
if (-not (Test-Path $dll)) { throw "$name DLL not found at: $dll" }
|
||||
New-Item -ItemType Directory -Path "$SuiteStaging\$name" -Force | Out-Null
|
||||
Copy-Item $dll "$SuiteStaging\$name\" -Force
|
||||
}
|
||||
|
||||
# Headless client (experimental, docs/HEADLESS.md): {app}\Headless\rynth-headless.exe with its own
|
||||
# x64 runtime, and {app}\Headless\plugins\<Name>\ (RynthCore.Plugin.<Name>.dll and its dependencies),
|
||||
# which the launcher's HeadlessLaunch.DefaultPluginPaths finds. The publish folders are copied whole
|
||||
# (the plugins' Data\ subfolders too); pdbs stay, for line numbers in the headless logs.
|
||||
if (-not (Test-Path "$HeadlessPublish\rynth-headless.exe")) { throw "Headless client publish not found at: $HeadlessPublish" }
|
||||
New-Item -ItemType Directory -Path "$StagingDir\Headless\plugins" -Force | Out-Null
|
||||
Copy-Item "$HeadlessPublish\*" "$StagingDir\Headless\" -Recurse -Force
|
||||
foreach ($name in $HeadlessPlugins.Keys) {
|
||||
$src = "$HeadlessPluginsPublish\$name"
|
||||
if (-not (Test-Path "$src\RynthCore.Plugin.$name.dll")) { throw "Headless (x64) $name publish not found at: $src" }
|
||||
Copy-Item $src "$StagingDir\Headless\plugins\" -Recurse -Force
|
||||
}
|
||||
# The plugin builds must really be 64-bit: an x86 one (wrong overrides, a stale publish) fails to load
|
||||
# in rynth-headless with BadImageFormatException, only once a player launches.
|
||||
# The PE header's machine field: an IL assembly built for x64 says AMD64 (0x8664); x86 and AnyCPU say I386 (0x14C).
|
||||
function Get-PeMachine([string]$path) {
|
||||
$b = [System.IO.File]::ReadAllBytes($path)
|
||||
return [BitConverter]::ToUInt16($b, [BitConverter]::ToInt32($b, 0x3C) + 4)
|
||||
}
|
||||
foreach ($name in $HeadlessPlugins.Keys) {
|
||||
$machine = Get-PeMachine "$StagingDir\Headless\plugins\$name\RynthCore.Plugin.$name.dll"
|
||||
if ($machine -ne 0x8664) { throw ("Headless plugin {0} is not an x64 build (PE machine 0x{1:X})" -f $name, $machine) }
|
||||
}
|
||||
if ((Get-PeMachine "$StagingDir\Headless\rynth-headless.exe") -ne 0x8664) { throw "rynth-headless.exe is not an x64 build" }
|
||||
# The players' guide to Headless mode, beside the exe.
|
||||
Copy-Item "$ScriptDir\HEADLESS-README.md" "$StagingDir\Headless\README.md" -Force
|
||||
$headlessMb = [math]::Round((Get-ChildItem "$StagingDir\Headless" -Recurse -File | Measure-Object Length -Sum).Sum / 1MB, 1)
|
||||
Write-Host " Headless: $((Get-ChildItem "$StagingDir\Headless" -Recurse -File).Count) file(s), ${headlessMb} MB (plugins: $($HeadlessPlugins.Keys -join ', '))"
|
||||
# RynthNav starter data → <RynthCore>\NavData (staged apart from core so it is only installed with RynthNav).
|
||||
if (-not (Test-Path $NavPortalsTsv)) { throw "RynthNav portals.tsv not found at: $NavPortalsTsv" }
|
||||
New-Item -ItemType Directory -Path "$StagingRoot\navdata" -Force | Out-Null
|
||||
Copy-Item $NavPortalsTsv "$StagingRoot\navdata\" -Force
|
||||
|
||||
# Decal bridge (docs/DECAL_BRIDGE_PLAN.md, experimental): the net48 x86 Decal network filter
|
||||
# goes to {app}\DecalBridge\, the folder the launcher registers for "Decal + RynthCore"
|
||||
# accounts (and only for those). Built against Decal's public reference assemblies, so the
|
||||
# build machine needs Decal; -p:RequireDecal=true turns "no Decal" into a build error rather
|
||||
# than the empty assembly a plain solution build makes. Never ships any Decal file.
|
||||
# Same probe as the bridge csproj (DecalAvailable): Decal.Adapter.dll in the Decal folder.
|
||||
$decalProbeDir = if ($DecalDir) { $DecalDir } else { "${env:ProgramFiles(x86)}\Decal 3.0" }
|
||||
$decalInstalled = Test-Path (Join-Path $decalProbeDir "Decal.Adapter.dll")
|
||||
$buildDecalBridge = -not $SkipDecalBridge -and ($decalInstalled -or $IncludeDecalBridge)
|
||||
if ($SkipDecalBridge) {
|
||||
Write-Warning "-SkipDecalBridge: this build has no Decal bridge; 'Decal + RynthCore' accounts can't launch with it. Not for a release."
|
||||
Write-Warning "-SkipDecalBridge: this build has no Decal bridge; 'Decal + RynthCore' accounts can't launch with it."
|
||||
} elseif (-not $buildDecalBridge) {
|
||||
Write-Warning "Decal not found in '$decalProbeDir': this build has no Decal bridge; 'Decal + RynthCore' accounts can't launch with it. (-DecalDir for another folder, -IncludeDecalBridge to make this an error.)"
|
||||
} else {
|
||||
Write-Host ""
|
||||
Write-Host "Building the Decal bridge (net48 x86, against Decal's reference assemblies)..." -ForegroundColor Cyan
|
||||
|
|
@ -322,22 +545,22 @@ if ($SkipDecalBridge) {
|
|||
Remove-Item $bridgeDll -Force -ErrorAction SilentlyContinue
|
||||
if (Test-Path $bridgeDll) { throw "Could not remove the old $bridgeDll (in use by a Decal client?)" }
|
||||
dotnet build $bridgeProject -c $Configuration -nologo -v q @decalArgs @VersionArgs
|
||||
if ($LASTEXITCODE -ne 0) { throw "Decal bridge build failed (exit $LASTEXITCODE). Is Decal 3.0 installed? (-DecalDir for another folder, -SkipDecalBridge for a dev build)" }
|
||||
if ($LASTEXITCODE -ne 0) { throw "Decal bridge build failed (exit $LASTEXITCODE). Is Decal 3.0 installed? (-DecalDir for another folder, -SkipDecalBridge to leave it out)" }
|
||||
if (-not (Test-Path $bridgeDll)) { throw "Decal bridge not built at $bridgeDll" }
|
||||
# The real bridge has its filter type; the no-Decal build is an empty assembly.
|
||||
$bridgeBytes = [System.IO.File]::ReadAllBytes($bridgeDll)
|
||||
if ([System.Text.Encoding]::ASCII.GetString($bridgeBytes).IndexOf("BridgeFilter") -lt 0) {
|
||||
throw "$bridgeDll has no BridgeFilter type - it was built without Decal's reference assemblies."
|
||||
}
|
||||
New-Item -ItemType Directory -Path "$StagingDir\DecalBridge" -Force | Out-Null
|
||||
Copy-Item $bridgeDll "$StagingDir\DecalBridge\" -Force
|
||||
$staleDecal = @(Get-ChildItem "$StagingDir\DecalBridge" -File | Where-Object { $_.Name -ne "RynthCore.DecalBridge.dll" })
|
||||
New-Item -ItemType Directory -Path "$CoreStaging\DecalBridge" -Force | Out-Null
|
||||
Copy-Item $bridgeDll "$CoreStaging\DecalBridge\" -Force
|
||||
$staleDecal = @(Get-ChildItem "$CoreStaging\DecalBridge" -File | Where-Object { $_.Name -ne "RynthCore.DecalBridge.dll" })
|
||||
if ($staleDecal.Count -gt 0) { throw "Unexpected files in the staged DecalBridge folder: $($staleDecal.Name -join ', ')" }
|
||||
Write-Host " RynthCore.DecalBridge.dll $((Get-Item $bridgeDll).VersionInfo.FileVersion)"
|
||||
}
|
||||
|
||||
# release.txt — which core release this install is ($release, from -Version at the top).
|
||||
Set-Content -Path "$StagingDir\release.txt" -Value @($release, $Version) -Encoding ASCII
|
||||
Set-Content -Path "$CoreStaging\release.txt" -Value @($release, $Version) -Encoding ASCII
|
||||
|
||||
# The PE machine field of a DLL (e_lfanew at 0x3C, then the COFF Machine at PE offset + 4). The game is
|
||||
# 32-bit, so the web panel's native loader must be the x86 one (0x14C): the NuGet package also carries
|
||||
|
|
@ -353,46 +576,86 @@ function Assert-PeMachine([string]$Path, [int]$Expected) {
|
|||
# Everything a working install needs. The 2026-09-25 public installer went out
|
||||
# without the Loader and the SEH trampoline because nothing checked.
|
||||
$required = @(
|
||||
"$StagingDir\RynthCore.exe",
|
||||
"$StagingDir\Runtime\RynthCore.Loader.dll",
|
||||
"$StagingDir\Runtime\RynthCore.Engine.dll",
|
||||
"$StagingDir\Runtime\RynthCore.SehTrampoline.dll",
|
||||
"$StagingDir\Runtime\minhook.x86.dll",
|
||||
"$StagingDir\Runtime\cimgui.dll",
|
||||
"$pluginStagingDir\RynthAi\RynthCore.Plugin.RynthAi.dll",
|
||||
"$StagingDir\Headless\rynth-headless.exe",
|
||||
"$StagingDir\Headless\rynth-headless.dll",
|
||||
"$StagingDir\Headless\coreclr.dll",
|
||||
"$StagingDir\Headless\RynthCore.Headless.dll"
|
||||
)
|
||||
foreach ($name in $HeadlessPlugins.Keys) { $required += "$StagingDir\Headless\plugins\$name\RynthCore.Plugin.$name.dll" }
|
||||
"$CoreStaging\RynthCore.exe",
|
||||
"$CoreStaging\RynthCore.App.Avalonia.dll",
|
||||
"$CoreStaging\RynthCore.App.Avalonia.deps.json",
|
||||
"$CoreStaging\RynthCore.App.Avalonia.runtimeconfig.json",
|
||||
"$CoreStaging\Runtime\RynthCore.Loader.dll",
|
||||
"$CoreStaging\Runtime\RynthCore.Engine.dll",
|
||||
"$CoreStaging\Runtime\RynthCore.SehTrampoline.dll",
|
||||
"$CoreStaging\Runtime\minhook.x86.dll",
|
||||
"$CoreStaging\Runtime\cimgui.dll",
|
||||
"$CoreStaging\Tools\LootEditor\RynthCore.LootEditor.exe",
|
||||
"$SuiteStaging\RynthAi\RynthCore.Plugin.RynthAi.dll",
|
||||
"$SuiteStaging\RynthAi\MonsterEditor\RynthCore.MonsterEditor.exe",
|
||||
"$StagingRoot\navdata\portals.tsv"
|
||||
) + @(@($ExperimentalPlugins) + @($SuitePlugins) | ForEach-Object { "$SuiteStaging\$_\RynthCore.Plugin.$_.dll" })
|
||||
# The unloadable engine also needs its shim and the app-local CoreCLR runtime.
|
||||
if (-not $NativeAot) {
|
||||
$required += @(
|
||||
"$StagingDir\Runtime\RynthCore.Shim.dll",
|
||||
"$StagingDir\Runtime\dotnet\coreclr.dll",
|
||||
"$StagingDir\Runtime\dotnet\System.Private.CoreLib.dll",
|
||||
"$StagingDir\Runtime\Microsoft.Web.WebView2.Core.dll",
|
||||
"$StagingDir\Runtime\WebView2Loader.dll"
|
||||
"$CoreStaging\Runtime\RynthCore.Shim.dll",
|
||||
"$CoreStaging\Runtime\dotnet\coreclr.dll",
|
||||
"$CoreStaging\Runtime\dotnet\System.Private.CoreLib.dll",
|
||||
"$CoreStaging\Runtime\Microsoft.Web.WebView2.Core.dll",
|
||||
"$CoreStaging\Runtime\WebView2Loader.dll"
|
||||
)
|
||||
}
|
||||
if (-not $SkipDecalBridge) {
|
||||
$required += "$StagingDir\DecalBridge\RynthCore.DecalBridge.dll"
|
||||
if ($buildDecalBridge) {
|
||||
$required += "$CoreStaging\DecalBridge\RynthCore.DecalBridge.dll"
|
||||
}
|
||||
$missing = @($required | Where-Object { -not (Test-Path $_) })
|
||||
if ($missing.Count -gt 0) { throw "Staging is missing required files:`n $($missing -join "`n ")" }
|
||||
if (-not $NativeAot) {
|
||||
Assert-PeMachine "$StagingDir\Runtime\WebView2Loader.dll" 0x14C
|
||||
Assert-PeMachine "$CoreStaging\Runtime\WebView2Loader.dll" 0x14C
|
||||
}
|
||||
|
||||
# Every assembly the launcher's deps.json lists must be staged next to it — a launcher DLL whose
|
||||
# deps.json doesn't match is exactly the "Could not load RynthCore.DesktopLog" failure of 2026-10-04.
|
||||
$depsJson = Get-Content "$CoreStaging\RynthCore.App.Avalonia.deps.json" -Raw | ConvertFrom-Json
|
||||
$projectLibs = $depsJson.libraries.PSObject.Properties | Where-Object { $_.Value.type -eq 'project' } | ForEach-Object { ($_.Name -split '/')[0] }
|
||||
$missingLibs = @($projectLibs | Where-Object { -not (Test-Path "$CoreStaging\$_.dll") })
|
||||
if ($missingLibs.Count -gt 0) { throw "Launcher deps.json references project assemblies that were not staged:`n $($missingLibs -join "`n ")" }
|
||||
|
||||
# Report staged sizes
|
||||
$engineDll = "$StagingDir\Runtime\RynthCore.Engine.dll"
|
||||
$engineDll = "$CoreStaging\Runtime\RynthCore.Engine.dll"
|
||||
if (Test-Path $engineDll) {
|
||||
$sizeMb = [math]::Round((Get-Item $engineDll).Length / 1MB, 1)
|
||||
Write-Host " Engine.dll: ${sizeMb} MB"
|
||||
}
|
||||
$totalMb = [math]::Round((Get-ChildItem "$StagingDir" -Recurse -File | Measure-Object Length -Sum).Sum / 1MB, 1)
|
||||
Write-Host " Total staged: ${totalMb} MB"
|
||||
$coreMb = [math]::Round((Get-ChildItem $CoreStaging -Recurse -File | Measure-Object Length -Sum).Sum / 1MB, 1)
|
||||
$suiteMb = [math]::Round((Get-ChildItem $SuiteStaging -Recurse -File | Measure-Object Length -Sum).Sum / 1MB, 1)
|
||||
Write-Host " Staged: RynthCore ${coreMb} MB, RynthSuite ${suiteMb} MB"
|
||||
|
||||
Write-Host "Staging complete: $StagingDir" -ForegroundColor Green
|
||||
Write-Host "Staging complete: $StagingRoot" -ForegroundColor Green
|
||||
|
||||
# ── Archive the previous installer when -Version bumps ─────────────────────
|
||||
# installer\previous-release\last-built-version.txt records the last version built; when a new
|
||||
# -Version is built, that version's installer is copied to previous-release\ first.
|
||||
# Inno stamps AppVersion as the setup exe's ProductVersion, padded with spaces/NULs.
|
||||
function Get-InstallerVersion([string]$Exe) { "$((Get-Item $Exe).VersionInfo.ProductVersion)".Trim([char[]]" `0") }
|
||||
|
||||
$previousReleaseDir = Join-Path $ScriptDir "previous-release"
|
||||
$lastVersionFile = Join-Path $previousReleaseDir "last-built-version.txt"
|
||||
if ($Version) {
|
||||
New-Item -ItemType Directory -Path $previousReleaseDir -Force | Out-Null
|
||||
$lastVer = if (Test-Path $lastVersionFile) { (Get-Content $lastVersionFile -Raw).Trim() } else { "" }
|
||||
if ($lastVer -and $lastVer -ne $Version) {
|
||||
$prevExe = Join-Path $ScriptDir "Output\RynthCore-Setup-$lastVer.exe"
|
||||
if (-not (Test-Path $prevExe)) {
|
||||
# The canonical copy may be an older build (e.g. the previous version was built in
|
||||
# another checkout); only archive it when its stamped ProductVersion really is $lastVer.
|
||||
$canonical = Join-Path $ScriptDir "Output\RynthCore-Setup.exe"
|
||||
$prevExe = $null
|
||||
if ((Test-Path $canonical) -and ((Get-InstallerVersion $canonical) -eq $lastVer)) { $prevExe = $canonical }
|
||||
elseif (Test-Path $canonical) { Write-Warning "Previous installer $lastVer not found in Output\ (RynthCore-Setup.exe is $(Get-InstallerVersion $canonical)); nothing archived." }
|
||||
}
|
||||
if ($prevExe -and (Test-Path $prevExe)) {
|
||||
$archive = Join-Path $previousReleaseDir "RynthCore-Setup-$lastVer.exe"
|
||||
Write-Host "Archiving previous installer ($lastVer) -> $archive" -ForegroundColor Cyan
|
||||
Copy-Item $prevExe $archive -Force
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# No file we ship may carry the ReadOnly attribute (a read-only source - a git checkout on a
|
||||
# read-only share, a file copied off an ISO - would otherwise land read-only on the player's PC,
|
||||
|
|
@ -429,8 +692,13 @@ $issSource = "$ScriptDir\RynthCore.iss"
|
|||
# Source, staging\) still resolve from the installer\ directory.
|
||||
$issTmp = "$ScriptDir\RynthCore.tmp.iss"
|
||||
$issContent = Get-Content $issSource -Raw
|
||||
$outputName = "RynthCore-Setup"
|
||||
if ($Version) {
|
||||
# Versioned .exe avoids Inno error 32 when Output\RynthCore-Setup.exe is open in Explorer or AV.
|
||||
$outputName = "RynthCore-Setup-$Version"
|
||||
$issContent = $issContent -replace 'AppVersion=0\.0\.0', "AppVersion=$Version"
|
||||
$issContent = $issContent -replace 'AppVerName=RynthCore \+ RynthSuite 0\.0\.0', "AppVerName=RynthCore + RynthSuite $Version"
|
||||
$issContent = $issContent -replace 'OutputBaseFilename=RynthCore-Setup', "OutputBaseFilename=$outputName"
|
||||
Write-Host " Version override: $Version"
|
||||
}
|
||||
Set-Content -Path $issTmp -Value $issContent -Encoding UTF8
|
||||
|
|
@ -442,6 +710,203 @@ try {
|
|||
Remove-Item $issTmp -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
$builtInstaller = "$ScriptDir\Output\$outputName.exe"
|
||||
if ($Version) {
|
||||
# Canonical name for the launcher updater / docs; best effort if the file is locked.
|
||||
try { Copy-Item $builtInstaller "$ScriptDir\Output\RynthCore-Setup.exe" -Force }
|
||||
catch { Write-Warning "Could not refresh Output\RynthCore-Setup.exe (in use?). Primary artifact: $builtInstaller" }
|
||||
}
|
||||
|
||||
# ── Deployment package (-Version builds) ────────────────────────────────────
|
||||
# installer\Output\Release-<version>\ holds everything a deployment needs, and
|
||||
# RynthCore-<version>-deploy.zip is that folder zipped:
|
||||
# RynthCore-Setup-<version>.exe the installer
|
||||
# release-manifest.json version, commits, component versions, installer hash
|
||||
# RELEASE-NOTES.md install steps + Changelog entries since the previous release
|
||||
# SHA256SUMS.txt hashes of the three files above (sha256sum format)
|
||||
# previous-release\last-release-manifest.json keeps the manifest so the next build can list only
|
||||
# the Changelog files added or changed since this release's commits.
|
||||
|
||||
# UTF-8 without BOM (Windows PowerShell's Set-Content -Encoding UTF8 writes a BOM).
|
||||
function Write-Utf8([string]$Path, [string]$Text) {
|
||||
[IO.File]::WriteAllText($Path, $Text, (New-Object System.Text.UTF8Encoding($false)))
|
||||
}
|
||||
function Get-Sha256([string]$Path) { (Get-FileHash $Path -Algorithm SHA256).Hash.ToLowerInvariant() }
|
||||
|
||||
# Changelog\*.md files added/modified in $Repo since $SinceCommit (when that commit exists),
|
||||
# else since $SinceDate (yyyy-mm-dd). Returns repo-relative paths that still exist.
|
||||
function Get-ChangelogFiles([string]$Repo, [string]$SinceCommit, [string]$SinceDate) {
|
||||
$ErrorActionPreference = 'Continue' # git writes "fatal:" to stderr for unknown commits
|
||||
$names = @()
|
||||
$known = $false
|
||||
if ($SinceCommit) {
|
||||
git -C $Repo cat-file -e "$SinceCommit^{commit}" 2>$null
|
||||
$known = ($LASTEXITCODE -eq 0)
|
||||
}
|
||||
if ($known) {
|
||||
$names = @(git -C $Repo diff --name-only --diff-filter=AM $SinceCommit HEAD -- Changelog 2>$null)
|
||||
} elseif ($SinceDate) {
|
||||
$names = @(git -C $Repo log "--since=$SinceDate 00:00" --name-only --diff-filter=AM --format= -- Changelog 2>$null)
|
||||
}
|
||||
@($names | Where-Object { $_ -like '*.md' -and (Test-Path (Join-Path $Repo $_)) } | Sort-Object -Unique)
|
||||
}
|
||||
|
||||
if ($Version -and -not $NoPackage) {
|
||||
Write-Host ""
|
||||
Write-Host "Assembling deployment package..." -ForegroundColor Cyan
|
||||
|
||||
# The installer must carry this release's version (Inno stamps AppVersion as ProductVersion).
|
||||
$stamped = Get-InstallerVersion $builtInstaller
|
||||
if ($stamped -ne $Version) { throw "Installer ProductVersion is '$stamped', expected '$Version'." }
|
||||
|
||||
$pkgName = "Release-$Version"
|
||||
$pkgDir = Join-Path $ScriptDir "Output\$pkgName"
|
||||
$zipPath = Join-Path $ScriptDir "Output\RynthCore-$Version-deploy.zip"
|
||||
if (Test-Path $pkgDir) { Remove-Item $pkgDir -Recurse -Force }
|
||||
if (Test-Path $zipPath) { Remove-Item $zipPath -Force }
|
||||
New-Item -ItemType Directory -Path $pkgDir -Force | Out-Null
|
||||
|
||||
$setupName = "RynthCore-Setup-$Version.exe"
|
||||
Copy-Item $builtInstaller (Join-Path $pkgDir $setupName) -Force
|
||||
$setupHash = Get-Sha256 (Join-Path $pkgDir $setupName)
|
||||
|
||||
# Versions of what the installer ships, read from the staged files' version resources.
|
||||
$componentFiles = [ordered]@{
|
||||
'Launcher (RynthCore.exe)' = "$CoreStaging\RynthCore.exe"
|
||||
'Engine' = "$CoreStaging\Runtime\RynthCore.Engine.dll"
|
||||
'Loader' = "$CoreStaging\Runtime\RynthCore.Loader.dll"
|
||||
'Loot Editor' = "$CoreStaging\Tools\LootEditor\RynthCore.LootEditor.exe"
|
||||
'RynthAi plugin' = "$SuiteStaging\RynthAi\RynthCore.Plugin.RynthAi.dll"
|
||||
'Monster Editor' = "$SuiteStaging\RynthAi\MonsterEditor\RynthCore.MonsterEditor.exe"
|
||||
}
|
||||
foreach ($name in $SuitePlugins) { $componentFiles["$name plugin"] = "$SuiteStaging\$name\RynthCore.Plugin.$name.dll" }
|
||||
foreach ($name in $ExperimentalPlugins) { $componentFiles["$name (experimental)"] = "$SuiteStaging\$name\RynthCore.Plugin.$name.dll" }
|
||||
$components = foreach ($kv in $componentFiles.GetEnumerator()) {
|
||||
$vi = (Get-Item $kv.Value).VersionInfo
|
||||
$ver = if ($vi.ProductVersion) { $vi.ProductVersion } else { $vi.FileVersion }
|
||||
[ordered]@{ name = $kv.Key; file = $kv.Value.Substring($StagingRoot.Length + 1); version = "$ver".Trim([char[]]" `0") }
|
||||
}
|
||||
|
||||
# Changelog entries since the previous release (its manifest's commits, else its build date).
|
||||
$lastManifestFile = Join-Path $previousReleaseDir "last-release-manifest.json"
|
||||
$prevManifest = $null
|
||||
if (Test-Path $lastManifestFile) {
|
||||
try { $prevManifest = Get-Content $lastManifestFile -Raw | ConvertFrom-Json } catch { $prevManifest = $null }
|
||||
}
|
||||
# Baseline for "changes since": a rebuild of the same version reuses that build's baseline;
|
||||
# otherwise the previous release's commits, or (no manifest yet) the previous version's date.
|
||||
function ConvertTo-SinceDate([string]$Ver) {
|
||||
$vp = "$Ver".Split('.')
|
||||
if ($vp.Count -eq 4) { return '{0:D4}-{1:D2}-{2:D2}' -f [int]$vp[0], [int]$vp[1], [int]$vp[2] }
|
||||
return ""
|
||||
}
|
||||
$prevRelease = if ($lastVer -ne $Version) { $lastVer } else { "" }
|
||||
$coreSince = ""; $suiteSince = ""; $sinceDate = ""
|
||||
if ($prevManifest -and $prevManifest.version -eq $Version) {
|
||||
$prevRelease = "$($prevManifest.previous)"
|
||||
if ($prevManifest.changelogSince) {
|
||||
$coreSince = "$($prevManifest.changelogSince.rynthCore)"
|
||||
$suiteSince = "$($prevManifest.changelogSince.rynthSuite)"
|
||||
$sinceDate = "$($prevManifest.changelogSince.date)"
|
||||
} else { $sinceDate = ConvertTo-SinceDate $prevRelease }
|
||||
} elseif ($prevManifest) {
|
||||
$coreSince = "$($prevManifest.source.rynthCore.commit)"
|
||||
$suiteSince = "$($prevManifest.source.rynthSuite.commit)"
|
||||
} else {
|
||||
$sinceDate = ConvertTo-SinceDate $prevRelease
|
||||
}
|
||||
$notesFrom = @(
|
||||
@{ Repo = 'RynthCore'; Root = $RepoRoot; Files = (Get-ChangelogFiles $RepoRoot $coreSince $sinceDate) },
|
||||
@{ Repo = 'RynthSuite'; Root = $RynthSuiteRoot; Files = (Get-ChangelogFiles $RynthSuiteRoot $suiteSince $sinceDate) }
|
||||
)
|
||||
|
||||
$manifest = [ordered]@{
|
||||
schema = 1
|
||||
product = 'RynthCore + RynthSuite'
|
||||
version = $Version
|
||||
release = $release
|
||||
builtUtc = (Get-Date).ToUniversalTime().ToString('yyyy-MM-ddTHH:mm:ssZ')
|
||||
previous = $prevRelease
|
||||
installer = [ordered]@{ file = $setupName; size = (Get-Item (Join-Path $pkgDir $setupName)).Length; sha256 = $setupHash }
|
||||
source = [ordered]@{
|
||||
rynthCore = [ordered]@{ branch = $CoreState.branch; commit = $CoreState.commit; dirty = $CoreState.dirty }
|
||||
rynthSuite = [ordered]@{ branch = $SuiteState.branch; commit = $SuiteState.commit; dirty = $SuiteState.dirty }
|
||||
}
|
||||
components = @($components)
|
||||
changelog = @($notesFrom | ForEach-Object { $r = $_.Repo; $_.Files | ForEach-Object { "$r/$_" } })
|
||||
# Baseline the notes were built from (reused when this version is rebuilt).
|
||||
changelogSince = [ordered]@{ rynthCore = $coreSince; rynthSuite = $suiteSince; date = $sinceDate }
|
||||
}
|
||||
$manifestJson = $manifest | ConvertTo-Json -Depth 6
|
||||
Write-Utf8 (Join-Path $pkgDir 'release-manifest.json') $manifestJson
|
||||
|
||||
# RELEASE-NOTES.md: install/verify steps, component table, then the Changelog entries
|
||||
# (their headings demoted two levels so they nest under "Changes").
|
||||
$sb = New-Object System.Text.StringBuilder
|
||||
$short = { param($s) if ($s.commit) { "$($s.branch)@$($s.commit.Substring(0,7))$(if ($s.dirty) { ' (uncommitted changes!)' })" } else { 'unknown' } }
|
||||
[void]$sb.AppendLine("# RynthCore + RynthSuite $Version")
|
||||
[void]$sb.AppendLine()
|
||||
[void]$sb.AppendLine("Release $release, built $($manifest.builtUtc). Previous release: $(if ($prevRelease) { $prevRelease } else { 'none recorded' }).")
|
||||
[void]$sb.AppendLine("Source: RynthCore $(& $short $CoreState), RynthSuite $(& $short $SuiteState).")
|
||||
[void]$sb.AppendLine()
|
||||
[void]$sb.AppendLine("## Install")
|
||||
[void]$sb.AppendLine("- Close Asheron's Call clients and the RynthCore launcher, then run ``$setupName``. It upgrades earlier RynthCore / RynthBundle installs in place.")
|
||||
[void]$sb.AppendLine("- The installer asks for the RynthCore and RynthSuite folders; RynthAi, the Loot Editor and the Monster Editor are included, experimental plugins are optional components.")
|
||||
[void]$sb.AppendLine("- When the .NET 10 Desktop Runtime (x86) is missing it is downloaded from Microsoft during setup.")
|
||||
[void]$sb.AppendLine("- Silent install: ``$setupName /VERYSILENT /DIR=""C:\Games\RynthCore"" /SUITEDIR=""C:\Games\RynthSuite""``")
|
||||
[void]$sb.AppendLine("- Verify the download: ``(Get-FileHash .\$setupName).Hash`` must equal ``$setupHash`` (also in SHA256SUMS.txt).")
|
||||
[void]$sb.AppendLine()
|
||||
[void]$sb.AppendLine("## Components")
|
||||
[void]$sb.AppendLine("| Component | Version |")
|
||||
[void]$sb.AppendLine("|---|---|")
|
||||
foreach ($c in $components) { [void]$sb.AppendLine("| $($c.name) | $($c.version) |") }
|
||||
[void]$sb.AppendLine()
|
||||
[void]$sb.AppendLine("## Changes$(if ($prevRelease) { " since $prevRelease" })")
|
||||
$anyNotes = $false
|
||||
foreach ($src in $notesFrom) {
|
||||
foreach ($rel in $src.Files) {
|
||||
$anyNotes = $true
|
||||
[void]$sb.AppendLine()
|
||||
[void]$sb.AppendLine("### $($src.Repo): $([IO.Path]::GetFileName($rel))")
|
||||
$text = [IO.File]::ReadAllText((Join-Path $src.Root $rel)) # UTF-8 (Get-Content would read ANSI on 5.1)
|
||||
foreach ($line in ($text -split "`r?`n")) {
|
||||
if ($line -match '^#') { [void]$sb.AppendLine("##$line") } else { [void]$sb.AppendLine($line) }
|
||||
}
|
||||
}
|
||||
}
|
||||
if (-not $anyNotes) { [void]$sb.AppendLine(); [void]$sb.AppendLine("_No Changelog entries were added since the previous release._") }
|
||||
Write-Utf8 (Join-Path $pkgDir 'RELEASE-NOTES.md') $sb.ToString()
|
||||
|
||||
# SHA256SUMS.txt in sha256sum format ("<hash> *<file>"), covering every other package file.
|
||||
$sumLines = Get-ChildItem $pkgDir -File | Sort-Object Name | ForEach-Object { "$(Get-Sha256 $_.FullName) *$($_.Name)" }
|
||||
Write-Utf8 (Join-Path $pkgDir 'SHA256SUMS.txt') (($sumLines -join "`n") + "`n")
|
||||
|
||||
Compress-Archive -Path (Join-Path $pkgDir '*') -DestinationPath $zipPath -CompressionLevel Optimal
|
||||
|
||||
# Re-verify: extract the zip and check every file against SHA256SUMS.txt.
|
||||
$verifyDir = Join-Path $env:TEMP "RynthCore-deploy-verify-$([guid]::NewGuid().ToString('N'))"
|
||||
try {
|
||||
Expand-Archive -Path $zipPath -DestinationPath $verifyDir -Force
|
||||
foreach ($line in $sumLines) {
|
||||
$expected, $file = $line -split ' \*', 2
|
||||
$actual = Get-Sha256 (Join-Path $verifyDir $file)
|
||||
if ($actual -ne $expected) { throw "Deployment zip verification failed for ${file}: $actual != $expected" }
|
||||
}
|
||||
} finally {
|
||||
Remove-Item $verifyDir -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
Write-Utf8 $lastManifestFile $manifestJson
|
||||
$zipMb = [math]::Round((Get-Item $zipPath).Length / 1MB, 1)
|
||||
Write-Host " Package: $pkgDir" -ForegroundColor Green
|
||||
Write-Host " Zip: $zipPath (${zipMb} MB, verified)" -ForegroundColor Green
|
||||
Write-Host " Changelog entries: $($manifest.changelog.Count)"
|
||||
}
|
||||
|
||||
# Record the version last, so a failed package step is retried (not skipped) on the next run.
|
||||
if ($Version) { [IO.File]::WriteAllText($lastVersionFile, $Version) }
|
||||
|
||||
Write-Host ""
|
||||
Write-Host "SUCCESS" -ForegroundColor Green
|
||||
Write-Host "Installer: $ScriptDir\Output\RynthCore-Setup.exe"
|
||||
Write-Host "Installer: $builtInstaller"
|
||||
if ($Version -and -not $NoPackage) { Write-Host "Deploy: $zipPath" }
|
||||
|
|
|
|||
|
|
@ -362,28 +362,27 @@ if (-not $NativeAotPlugins) {
|
|||
}
|
||||
& (Join-Path $ScriptDir "Build-Installer.ps1") @installerArgs
|
||||
if (-not $?) { throw "Build-Installer.ps1 failed" }
|
||||
# The Decal bridge ships in every release (experimental, opt-in per account): the installer
|
||||
# carries it, so a launcher that updates through this feed gets it as a fresh install does.
|
||||
# Build-Installer.ps1 fails without Decal; this guards against a -SkipDecalBridge staging.
|
||||
$bridgeStaged = Join-Path $ScriptDir "staging\app\DecalBridge\RynthCore.DecalBridge.dll"
|
||||
if (-not (Test-Path $bridgeStaged)) { throw "The installer was built without the Decal bridge ($bridgeStaged missing) - not publishing." }
|
||||
Write-Host " Decal bridge in the installer: $((Get-Item $bridgeStaged).VersionInfo.FileVersion)"
|
||||
# The headless client ships in every release too (experimental, opt-in per account): rynth-headless with its
|
||||
# own x64 runtime, and the x64 RynthAi it loads when the launcher's HeadlessPluginPaths is empty. Its
|
||||
# plugins come with the core installer only; the feed's plugin entries stay the x86 game-client builds.
|
||||
foreach ($f in "Headless\rynth-headless.exe", "Headless\plugins\RynthAi\RynthCore.Plugin.RynthAi.dll") {
|
||||
if (-not (Test-Path (Join-Path $ScriptDir "staging\app\$f"))) { throw "The installer was built without $f - not publishing." }
|
||||
# The Decal bridge (experimental, opt-in per account) is only in installers built where Decal is
|
||||
# installed; a launcher updating through this feed without it can't run "Decal + RynthCore" accounts.
|
||||
$bridgeStaged = Join-Path $ScriptDir "staging\core\DecalBridge\RynthCore.DecalBridge.dll"
|
||||
if (Test-Path $bridgeStaged) {
|
||||
Write-Host " Decal bridge in the installer: $((Get-Item $bridgeStaged).VersionInfo.FileVersion)"
|
||||
} else {
|
||||
Write-Warning "This installer has no Decal bridge ($bridgeStaged missing); 'Decal + RynthCore' accounts won't work from it."
|
||||
}
|
||||
foreach ($f in "Headless\rynth-headless.dll", "Headless\plugins\RynthAi\RynthCore.Plugin.RynthAi.dll") {
|
||||
$fv = (Get-Item (Join-Path $ScriptDir "staging\app\$f")).VersionInfo.FileVersion
|
||||
if ($fv -ne $Version) { throw "The installer's $f is version $fv, not $Version (stale build?) - not publishing." }
|
||||
}
|
||||
Write-Host " headless client in the installer: rynth-headless and the x64 RynthAi, both $Version"
|
||||
Copy-Item (Join-Path $ScriptDir "Output\RynthCore-Setup.exe") "$rel\RynthCore-Setup.exe"
|
||||
Copy-Item (Join-Path $ScriptDir "staging\plugins\RynthAi\RynthCore.Plugin.RynthAi.dll") "$rel\plugins\"
|
||||
# The versioned installer is the primary artifact (the RynthCore-Setup.exe copy is best effort).
|
||||
Copy-Item (Join-Path $ScriptDir "Output\RynthCore-Setup-$Version.exe") "$rel\RynthCore-Setup.exe"
|
||||
# RynthAi: the managed build when plugins are managed, else the NativeAOT one Build-Installer.ps1
|
||||
# staged under staging\suite\RynthAi\.
|
||||
$rynthAiFeed = if ($NativeAotPlugins) { Join-Path $ScriptDir "staging\suite\RynthAi\RynthCore.Plugin.RynthAi.dll" }
|
||||
else { "$rel\build\RynthAi\RynthCore.Plugin.RynthAi.dll" }
|
||||
Copy-Item $rynthAiFeed "$rel\plugins\"
|
||||
foreach ($name in $suitePlugins + $serverPlugins) {
|
||||
Copy-Item "$rel\build\$name\RynthCore.Plugin.$name.dll" "$rel\plugins\"
|
||||
}
|
||||
# Server plugins also go in RynthSuite-Plugins.zip: RynthCore loads only the one whose manifest hosts
|
||||
# claim the client's connect host, so installing all of them costs disk, not memory.
|
||||
$suitePlugins += $serverPlugins
|
||||
|
||||
Step "Packing RynthSuite-Plugins.zip"
|
||||
$zipRoot = "$rel\build\zip"
|
||||
|
|
@ -559,10 +558,27 @@ $pluginDescriptions = @{
|
|||
RynthOracle = "Quests, character and titles."
|
||||
RynthInventory = "Search every character's items."
|
||||
RynthSort = "Keeps your packs sorted: new loot goes to the pack its rule names."
|
||||
RynthILT = "Infinite Leaftide only: the ILT Hub (the Mini Remote's banking, gear, charms and games tabs), the Guardian, bounty tracking and progression planning."
|
||||
RynthILT = "Infinite Leaftide only: the ILT Hub (the Mini Remote's banking, gear, charms and games tabs), the Guardian, bounty tracking, progression planning, ILT settings and the /fship fellowship commands."
|
||||
RynthThreads = "DreamWeave only: records Fragment Press results and works out what each component brings."
|
||||
RynthNet = "Links your characters on this PC: broadcast commands (/ub bc), shared vitals and the Characters panel."
|
||||
RynthDefective = "A shortcut bar with AC's own keys, buttons for AC's panels and the Selection, in place of the retail toolbar."
|
||||
# Server plugins: only the one for the server you connect to loads.
|
||||
RynthAChard = "AChard's server plugin: server facts, PvP rules and commands. Loads only on AChard."
|
||||
RynthAelrynth = "Aelrynth's server plugin: server facts, mods and commands. Loads only on Aelrynth."
|
||||
RynthColdeve = "Coldeve's server plugin: server facts, rules and commands. Loads only on Coldeve."
|
||||
RynthConquest = "Conquest's server plugin: server facts, rules and commands. Loads only on Conquest."
|
||||
RynthDerptide = "Derptide's server plugin: server facts, rules and commands. Loads only on Derptide."
|
||||
RynthDreamWeave = "DreamWeave's server plugin: server facts, rules, commands and wiki link. Loads only on DreamWeave."
|
||||
RynthEversong = "Eversong's server plugin: server facts, rules and commands. Loads only on Eversong."
|
||||
RynthFrostACE = "FrostACE's server plugin: server facts, rules and commands. Loads only on FrostACE."
|
||||
RynthFrostcull = "Frostcull's server plugin: server facts, rates and commands. Loads only on Frostcull."
|
||||
RynthLeafDawn = "LeafDawn's server plugin: server facts, rules and commands. Loads only on LeafDawn."
|
||||
RynthLeafdawning = "Leafdawning's server plugin: server facts, account limit and commands. Loads only on Leafdawning."
|
||||
RynthLevistras = "Levistras's server plugin: server facts and rules (botting is not allowed there). Loads only on Levistras."
|
||||
RynthPortalStorm = "PortalStorm's server plugin: server facts, rules and commands. Loads only on PortalStorm."
|
||||
RynthReefcull = "Reefcull's server plugin (GDLE): server facts, rules and commands. Loads only on Reefcull."
|
||||
RynthSundering = "Sundering's server plugin: server facts, character limit and commands. Loads only on Sundering."
|
||||
RynthThistlecrown = "Thistlecrown's server plugin: server facts, account limit and commands. Loads only on Thistlecrown."
|
||||
}
|
||||
# Plugin manifests (embedded in each DLL by the SDK's build targets): each plugin's minEngineApi
|
||||
# goes into its feed entry, and the core entry says its engine's API ("engineApi"), so launchers
|
||||
|
|
|
|||
|
|
@ -1,7 +1,18 @@
|
|||
; RynthCore + RynthAi Installer
|
||||
; Build with: Build-Installer.ps1 (requires Inno Setup 6)
|
||||
; RynthCore + RynthSuite full installer
|
||||
; Build with: Build-Installer.ps1 (requires Inno Setup 6) — it builds every component from source
|
||||
; (launcher, engine, loader, RynthAi plugin, Loot Editor, Monster Editor) and stages them under
|
||||
; installer\staging\core and installer\staging\suite before invoking ISCC on this file.
|
||||
; Source: https://jrsoftware.org/isdl.php
|
||||
;
|
||||
; Install locations are user-defined:
|
||||
; * RynthCore folder ({app}) — the standard "Select Destination Location" page
|
||||
; * RynthSuite folder ({code:GetSuiteDir}) — a second folder page right after it
|
||||
; Both are recorded under HKA\Software\Rynth (CoreDir / SuiteDir); the engine, launcher and plugins
|
||||
; resolve every path from there (RynthInstallPaths.cs), so neither folder has to be under C:\Games.
|
||||
; Silent installs: /DIR="<core folder>" /SUITEDIR="<suite folder>".
|
||||
; Prerequisite: when the .NET 10 Desktop Runtime (x86) is missing, the "installdotnet" task (on by default)
|
||||
; downloads it from Microsoft and installs it before the files are copied. A failure is reported, never fatal.
|
||||
;
|
||||
; NOTE: No ISPP (#define / {#...}) macros are used in this file.
|
||||
; Build-Installer.ps1 replaces the AppVersion placeholder via text substitution
|
||||
; before invoking ISCC, so the preprocessor has nothing to expand.
|
||||
|
|
@ -9,13 +20,17 @@
|
|||
; APPVERSION_PLACEHOLDER=0.0.0
|
||||
|
||||
[Setup]
|
||||
; Same AppId as every earlier RynthCore / RynthBundle installer, so this upgrades them in place.
|
||||
AppId={{A8B4C2D1-E3F5-4678-9ABC-DEF012345678}
|
||||
AppName=RynthCore
|
||||
AppVerName=RynthCore + RynthSuite 0.0.0
|
||||
AppVersion=0.0.0
|
||||
AppPublisher=RynthCore
|
||||
AppPublisherURL=https://aelrynth.com/git/rynth/RynthCore
|
||||
AppPublisherURL=https://aelrynth.com/rynth.html
|
||||
UninstallDisplayName=RynthCore + RynthSuite
|
||||
DefaultDirName=C:\Games\RynthCore
|
||||
DisableDirPage=no
|
||||
UsePreviousAppDir=yes
|
||||
DefaultGroupName=RynthCore
|
||||
DisableProgramGroupPage=yes
|
||||
OutputDir=Output
|
||||
|
|
@ -28,62 +43,172 @@ WizardStyle=modern
|
|||
; the chosen install folder requires it (e.g. C:\Games\).
|
||||
PrivilegesRequired=lowest
|
||||
PrivilegesRequiredOverridesAllowed=dialog
|
||||
; 32-bit app; works on 32/64-bit Windows
|
||||
ArchitecturesAllowed=x86 x64 arm64
|
||||
; Close a running launcher / editors before replacing their files.
|
||||
CloseApplications=yes
|
||||
; 32-bit app; works on 32/64-bit Windows (HKA registry writes land in the 32-bit view,
|
||||
; which is exactly where RynthInstallPaths reads HKLM from).
|
||||
ArchitecturesAllowed=x86compatible
|
||||
ArchitecturesInstallIn64BitMode=
|
||||
|
||||
[Languages]
|
||||
Name: "english"; MessagesFile: "compiler:Default.isl"
|
||||
|
||||
[Types]
|
||||
Name: "full"; Description: "Full install (RynthCore + RynthSuite)"
|
||||
Name: "core"; Description: "RynthCore only"
|
||||
Name: "custom"; Description: "Custom"; Flags: iscustom
|
||||
|
||||
[Components]
|
||||
Name: "core"; Description: "RynthCore launcher, engine and Loot Editor"; Types: full core custom; Flags: fixed
|
||||
Name: "rynthai"; Description: "RynthSuite: RynthAi plugin (installed and registered with the launcher)"; Types: full
|
||||
Name: "monstereditor"; Description: "RynthSuite: Monster Editor"; Types: full
|
||||
; RynthSuite companion plugins: on in a Full install, each registered with the launcher like RynthAi.
|
||||
Name: "suite"; Description: "RynthSuite: Companion plugins"; Types: full
|
||||
Name: "suite\rynthoracle"; Description: "RynthOracle - quests, quest timers, markers, character, fellowship"; Types: full
|
||||
Name: "suite\rynthilt"; Description: "RynthILT - Infinite Leaftide features (hub, progression, banking, bounties)"; Types: full
|
||||
Name: "suite\rynthinventory"; Description: "RynthInventory - inventory, item counts and global manage"; Types: full
|
||||
Name: "suite\rynthsort"; Description: "RynthSort - inventory sorting"; Types: full
|
||||
; Server plugins (RynthServers): RynthCore loads only the one for the server you connect to.
|
||||
Name: "suite\rynthachard"; Description: "RynthAChard - server plugin for AChard (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthaelrynth"; Description: "RynthAelrynth - server plugin for Aelrynth (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthcoldeve"; Description: "RynthColdeve - server plugin for Coldeve (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthconquest"; Description: "RynthConquest - server plugin for Conquest (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthderptide"; Description: "RynthDerptide - server plugin for Derptide (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthdreamweave"; Description: "RynthDreamWeave - server plugin for DreamWeave (loads only on that server)"; Types: full
|
||||
Name: "suite\ryntheversong"; Description: "RynthEversong - server plugin for Eversong (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthfrostace"; Description: "RynthFrostACE - server plugin for FrostACE (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthfrostcull"; Description: "RynthFrostcull - server plugin for Frostcull (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthleafdawn"; Description: "RynthLeafDawn - server plugin for LeafDawn (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthleafdawning"; Description: "RynthLeafdawning - server plugin for Leafdawning (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthlevistras"; Description: "RynthLevistras - server plugin for Levistras (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthportalstorm"; Description: "RynthPortalStorm - server plugin for PortalStorm (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthreefcull"; Description: "RynthReefcull - server plugin for Reefcull (loads only on that server)"; Types: full
|
||||
Name: "suite\rynthsundering"; Description: "RynthSundering - server plugin for Sundering (loads only on that server)"; Types: full
|
||||
Name: "suite\rynththistlecrown"; Description: "RynthThistlecrown - server plugin for Thistlecrown (loads only on that server)"; Types: full
|
||||
Name: "suite\rynththreads"; Description: "RynthThreads - server plugin for DreamWeave's Threads (loads only on that server)"; Types: full
|
||||
; Experimental plugins: unchecked by default in every install type (ticking one switches to Custom).
|
||||
Name: "experimental"; Description: "RynthSuite: Experimental plugins (work in progress)"
|
||||
Name: "experimental\rynthchat"; Description: "RynthChat - replacement chat window (classifies and owns game chat)"
|
||||
Name: "experimental\rynthjuice"; Description: "RynthJuice - floating damage/heal numbers and kill bursts"
|
||||
Name: "experimental\rynthnav"; Description: "RynthNav - navmesh pathing and portal routing (needs baked NavData tiles)"
|
||||
Name: "experimental\rynthtracker"; Description: "RynthTracker - per-session kill tracker"
|
||||
Name: "experimental\rynthvision"; Description: "RynthVision - unclimbable slope, water and radar-range overlays"
|
||||
Name: "experimental\ubrythai"; Description: "ub-Rythai - Utility Belt tools ported to RynthCore (XP meter, portal gems, chat automation)"
|
||||
|
||||
[Tasks]
|
||||
Name: desktopicon; Description: "Create a &desktop shortcut"; GroupDescription: "Additional icons:"
|
||||
; Only offered when the runtime is missing. RynthCore and its tools are self-contained / NativeAOT and run
|
||||
; without it; it is installed for framework-dependent add-ons and tools. Skip silently with /MERGETASKS="!installdotnet".
|
||||
Name: installdotnet; Description: "Download and install the Microsoft .NET 10 Desktop Runtime (x86, about 55 MB; may ask for administrator approval)"; GroupDescription: "Prerequisites:"; Check: DotNet10DesktopMissing
|
||||
|
||||
; Files left by older layouts (the 0.4.x RynthBundle put a framework-dependent launcher, the engine
|
||||
; and plugins straight into {app}). Mixing those with a newer launcher is what broke 2026-10-04's
|
||||
; reinstall (RynthCore.App.Avalonia.dll from 0.4.7 + a newer deps.json → missing DesktopLog).
|
||||
; Only loose top-level binaries/metadata are removed; every file the new build needs is copied back
|
||||
; by [Files] right after. User data (Logs, AcClient, NavData, DecalBridge, ...) is never touched.
|
||||
[InstallDelete]
|
||||
Type: files; Name: "{app}\*.dll"
|
||||
Type: files; Name: "{app}\*.json"
|
||||
Type: files; Name: "{app}\*.pdb"
|
||||
Type: files; Name: "{app}\*.exp"
|
||||
Type: files; Name: "{app}\*.lib"
|
||||
Type: files; Name: "{app}\*.previous"
|
||||
Type: files; Name: "{app}\RynthCore.App.Avalonia.exe"
|
||||
Type: files; Name: "{app}\RynthCore-Prerequisites.txt"
|
||||
Type: files; Name: "{app}\Runtime\*.dll"
|
||||
Type: files; Name: "{app}\Runtime\*.json"
|
||||
Type: files; Name: "{app}\Runtime\*.pdb"
|
||||
Type: files; Name: "{app}\Runtime\RynthCore.Injector.exe"
|
||||
Type: filesandordirs; Name: "{app}\Runtime\Plugins"
|
||||
|
||||
; Program files
|
||||
[Files]
|
||||
; Launcher + engine runtime + Loot Editor go to {app} (default C:\Games\RynthCore\)
|
||||
; overwritereadonly: a file left read-only on the player's PC is replaced without a question
|
||||
; (a /SILENT update can't answer one); the build clears ReadOnly on everything staged, and Setup
|
||||
; doesn't give installed files any attributes, so nothing lands read-only.
|
||||
; This includes {app}\Headless (experimental): rynth-headless.exe with its own 64-bit .NET runtime and
|
||||
; Headless\plugins\<Name>\ (the 64-bit plugin builds it runs), staged by Build-Installer.ps1. Nothing
|
||||
; there is ever loaded by a game client; the x86 plugins below are unchanged.
|
||||
Source: "staging\app\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs overwritereadonly
|
||||
; overwritereadonly (every line): a file left read-only on the player's PC is replaced without a
|
||||
; question (a /SILENT update can't answer one); the build clears ReadOnly on everything staged, and
|
||||
; Setup doesn't give installed files any attributes, so nothing lands read-only.
|
||||
; RynthCore: launcher, Runtime\ (engine, loader, native deps), Tools\LootEditor, release.txt
|
||||
Source: "staging\core\*"; DestDir: "{app}"; Components: core; Flags: ignoreversion recursesubdirs createallsubdirs overwritereadonly
|
||||
|
||||
; Plugin DLL goes to its canonical home next to plugin data dirs.
|
||||
; Engine does NOT auto-scan this folder — user adds the full DLL path in the
|
||||
; launcher's Plugins tab to enable the plugin. See BUILD.md "Deploy RynthAi Plugin".
|
||||
Source: "staging\plugins\RynthAi\RynthCore.Plugin.RynthAi.dll"; DestDir: "C:\Games\RynthSuite\RynthAi"; Flags: ignoreversion overwritereadonly
|
||||
; RynthSuite: the RynthAi plugin lives next to its data folders in the chosen Suite folder.
|
||||
Source: "staging\suite\RynthAi\RynthCore.Plugin.RynthAi.dll"; DestDir: "{code:GetSuiteDir}\RynthAi"; Components: rynthai; Flags: ignoreversion overwritereadonly
|
||||
; Monster Editor: RynthAi's dashboard launches it from <RynthAi>\MonsterEditor\.
|
||||
Source: "staging\suite\RynthAi\MonsterEditor\*"; DestDir: "{code:GetSuiteDir}\RynthAi\MonsterEditor"; Components: monstereditor; Flags: ignoreversion recursesubdirs createallsubdirs overwritereadonly
|
||||
|
||||
; Data directories (created once; never removed on uninstall)
|
||||
; Companion plugins: each in its own <RynthSuite>\<Name>\ folder, like the experimental ones below.
|
||||
Source: "staging\suite\RynthOracle\RynthCore.Plugin.RynthOracle.dll"; DestDir: "{code:GetSuiteDir}\RynthOracle"; Components: suite\rynthoracle; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthILT\RynthCore.Plugin.RynthILT.dll"; DestDir: "{code:GetSuiteDir}\RynthILT"; Components: suite\rynthilt; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthInventory\RynthCore.Plugin.RynthInventory.dll"; DestDir: "{code:GetSuiteDir}\RynthInventory"; Components: suite\rynthinventory; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthSort\RynthCore.Plugin.RynthSort.dll"; DestDir: "{code:GetSuiteDir}\RynthSort"; Components: suite\rynthsort; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthAChard\RynthCore.Plugin.RynthAChard.dll"; DestDir: "{code:GetSuiteDir}\RynthAChard"; Components: suite\rynthachard; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthAelrynth\RynthCore.Plugin.RynthAelrynth.dll"; DestDir: "{code:GetSuiteDir}\RynthAelrynth"; Components: suite\rynthaelrynth; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthColdeve\RynthCore.Plugin.RynthColdeve.dll"; DestDir: "{code:GetSuiteDir}\RynthColdeve"; Components: suite\rynthcoldeve; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthConquest\RynthCore.Plugin.RynthConquest.dll"; DestDir: "{code:GetSuiteDir}\RynthConquest"; Components: suite\rynthconquest; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthDerptide\RynthCore.Plugin.RynthDerptide.dll"; DestDir: "{code:GetSuiteDir}\RynthDerptide"; Components: suite\rynthderptide; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthDreamWeave\RynthCore.Plugin.RynthDreamWeave.dll"; DestDir: "{code:GetSuiteDir}\RynthDreamWeave"; Components: suite\rynthdreamweave; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthEversong\RynthCore.Plugin.RynthEversong.dll"; DestDir: "{code:GetSuiteDir}\RynthEversong"; Components: suite\ryntheversong; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthFrostACE\RynthCore.Plugin.RynthFrostACE.dll"; DestDir: "{code:GetSuiteDir}\RynthFrostACE"; Components: suite\rynthfrostace; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthFrostcull\RynthCore.Plugin.RynthFrostcull.dll"; DestDir: "{code:GetSuiteDir}\RynthFrostcull"; Components: suite\rynthfrostcull; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthLeafDawn\RynthCore.Plugin.RynthLeafDawn.dll"; DestDir: "{code:GetSuiteDir}\RynthLeafDawn"; Components: suite\rynthleafdawn; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthLeafdawning\RynthCore.Plugin.RynthLeafdawning.dll"; DestDir: "{code:GetSuiteDir}\RynthLeafdawning"; Components: suite\rynthleafdawning; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthLevistras\RynthCore.Plugin.RynthLevistras.dll"; DestDir: "{code:GetSuiteDir}\RynthLevistras"; Components: suite\rynthlevistras; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthPortalStorm\RynthCore.Plugin.RynthPortalStorm.dll"; DestDir: "{code:GetSuiteDir}\RynthPortalStorm"; Components: suite\rynthportalstorm; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthReefcull\RynthCore.Plugin.RynthReefcull.dll"; DestDir: "{code:GetSuiteDir}\RynthReefcull"; Components: suite\rynthreefcull; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthSundering\RynthCore.Plugin.RynthSundering.dll"; DestDir: "{code:GetSuiteDir}\RynthSundering"; Components: suite\rynthsundering; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthThistlecrown\RynthCore.Plugin.RynthThistlecrown.dll"; DestDir: "{code:GetSuiteDir}\RynthThistlecrown"; Components: suite\rynththistlecrown; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthThreads\RynthCore.Plugin.RynthThreads.dll"; DestDir: "{code:GetSuiteDir}\RynthThreads"; Components: suite\rynththreads; Flags: ignoreversion overwritereadonly
|
||||
|
||||
; Experimental plugins: each in its own <RynthSuite>\<Name>\ folder (the layout the launcher already uses).
|
||||
Source: "staging\suite\RynthChat\RynthCore.Plugin.RynthChat.dll"; DestDir: "{code:GetSuiteDir}\RynthChat"; Components: experimental\rynthchat; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthJuice\RynthCore.Plugin.RynthJuice.dll"; DestDir: "{code:GetSuiteDir}\RynthJuice"; Components: experimental\rynthjuice; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthNav\RynthCore.Plugin.RynthNav.dll"; DestDir: "{code:GetSuiteDir}\RynthNav"; Components: experimental\rynthnav; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthTracker\RynthCore.Plugin.RynthTracker.dll"; DestDir: "{code:GetSuiteDir}\RynthTracker"; Components: experimental\rynthtracker; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\RynthVision\RynthCore.Plugin.RynthVision.dll"; DestDir: "{code:GetSuiteDir}\RynthVision"; Components: experimental\rynthvision; Flags: ignoreversion overwritereadonly
|
||||
Source: "staging\suite\UbRythai\RynthCore.Plugin.UbRythai.dll"; DestDir: "{code:GetSuiteDir}\UbRythai"; Components: experimental\ubrythai; Flags: ignoreversion overwritereadonly
|
||||
; RynthNav reads <RynthCore>\NavData. Starter portal list only; a newer one from RynthNav.PortalGraph is kept.
|
||||
Source: "staging\navdata\portals.tsv"; DestDir: "{app}\NavData"; Components: experimental\rynthnav; Flags: onlyifdoesntexist uninsneveruninstall
|
||||
|
||||
; RynthAi data directories (created once; never removed on uninstall - they hold user profiles)
|
||||
;
|
||||
; Permissions: users-modify (2026-10-13). The game client never runs elevated, and RynthAi saves
|
||||
; Permissions: users-modify (upstream 2026-10-13). The game client never runs elevated, and RynthAi saves
|
||||
; metas, navs, loot and settings profiles in these folders. An "install for all users" (elevated)
|
||||
; Setup creates them as an administrator; on a PC whose C:\ permissions aren't Windows' defaults,
|
||||
; such folders are read-only for everyone else and RynthAi's saves failed. users-modify gives the
|
||||
; Users group Modify, inherited by everything inside, every time Setup runs (also on an update, so
|
||||
; it repairs older installs when that update runs elevated). A non-elevated Setup can only change
|
||||
; folders its user owns; where it can't, Setup logs "Failed to set permissions" and carries on
|
||||
; (not an error), and the launcher's Recovery Actions > Fix folder permissions does it instead.
|
||||
; Users group Modify, inherited by everything inside, every time Setup runs. A non-elevated Setup
|
||||
; can only change folders its user owns; where it can't, Setup logs "Failed to set permissions"
|
||||
; and carries on, and the launcher's Recovery Actions > Fix folder permissions does it instead.
|
||||
[Dirs]
|
||||
Name: "{app}"; Permissions: users-modify
|
||||
Name: "C:\Games\RynthSuite"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\NavProfiles"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\LootProfiles"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\MetaFiles"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\MetaProfiles"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\SettingsProfiles"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\SettingsProfiles\ACEmulator"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\LuaScripts"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\Logs"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\pvars"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "C:\Games\RynthSuite\RynthAi\ItemGiver"; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{app}"; Permissions: users-modify
|
||||
Name: "{code:GetSuiteDir}"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\NavProfiles"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\LootProfiles"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\MetaFiles"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\MetaProfiles"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\SettingsProfiles"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\SettingsProfiles\ACEmulator"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\MonsterProfiles"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\LuaScripts"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\Logs"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\pvars"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\ItemGiver"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
Name: "{code:GetSuiteDir}\RynthAi\AutoVendor"; Components: rynthai; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
; RynthNav tiles baked by RynthNav.Baker (default --out) go here; kept on uninstall.
|
||||
Name: "{app}\NavData"; Components: experimental\rynthnav; Permissions: users-modify; Flags: uninsneveruninstall
|
||||
|
||||
; Install locations for the engine / launcher / plugins (see RynthInstallPaths.cs), plus a one-shot
|
||||
; hand-off the launcher consumes on next start to add the plugin to its Plugins list.
|
||||
; HKA = HKCU for a per-user install, HKLM for an all-users (elevated) install.
|
||||
[Registry]
|
||||
Root: HKA; Subkey: "Software\Rynth"; ValueType: string; ValueName: "CoreDir"; ValueData: "{app}"; Flags: uninsdeletevalue uninsdeletekeyifempty
|
||||
Root: HKA; Subkey: "Software\Rynth"; ValueType: string; ValueName: "SuiteDir"; ValueData: "{code:GetSuiteDir}"; Flags: uninsdeletevalue uninsdeletekeyifempty
|
||||
Root: HKA; Subkey: "Software\Rynth"; ValueType: string; ValueName: "PendingPluginRegistration"; ValueData: "{code:GetPendingPlugins}"; Check: HasPendingPlugins; Flags: uninsdeletevalue
|
||||
|
||||
; Shortcuts
|
||||
[Icons]
|
||||
; Start Menu
|
||||
Name: "{group}\RynthCore"; Filename: "{app}\RynthCore.exe"; WorkingDir: "{app}"; Comment: "Launch RynthCore and inject into Asheron's Call"
|
||||
Name: "{group}\Loot Editor"; Filename: "{app}\Tools\LootEditor\RynthCore.LootEditor.exe"; WorkingDir: "{app}\Tools\LootEditor"; Comment: "Edit VTank-style loot profiles"
|
||||
Name: "{group}\Monster Editor"; Filename: "{code:GetSuiteDir}\RynthAi\MonsterEditor\RynthCore.MonsterEditor.exe"; WorkingDir: "{code:GetSuiteDir}\RynthAi\MonsterEditor"; Components: monstereditor; Comment: "Edit RynthAi monster profiles"
|
||||
Name: "{group}\RynthSuite Folder"; Filename: "{code:GetSuiteDir}"; Components: rynthai
|
||||
Name: "{group}\Uninstall RynthCore"; Filename: "{uninstallexe}"
|
||||
|
||||
; Optional Desktop shortcut (created only when the desktopicon task is checked)
|
||||
|
|
@ -112,6 +237,28 @@ Filename: "{app}\RynthCore.exe"; WorkingDir: "{app}"; Flags: nowait runasorigina
|
|||
Filename: "{app}\RynthCore.exe"; Parameters: "--decal-bridge-unregister"; Flags: runhidden waituntilterminated; RunOnceId: "RynthCoreDecalBridgeUnregister"
|
||||
|
||||
[Code]
|
||||
const
|
||||
DefaultSuiteDir = 'C:\Games\RynthSuite';
|
||||
{ One pinned .NET 10 Desktop Runtime build (x86 to match RynthCore's x86 binaries), checked against its
|
||||
SHA-256 before it runs: a download swapped on the way (or at a mirror) is refused, not run elevated.
|
||||
A moving "latest" link can't be pinned. To move to a newer build, take the url from
|
||||
https://builds.dotnet.microsoft.com/dotnet/release-metadata/10.0/releases.json (windowsdesktop,
|
||||
win-x86 .exe), check the download against the SHA-512 listed there, and put its SHA-256 here.
|
||||
Any 10.x already installed is kept (IsDotNet10DesktopX86Installed); Microsoft Update patches it later. }
|
||||
DotNetDesktopUrl = 'https://builds.dotnet.microsoft.com/dotnet/WindowsDesktop/10.0.12/windowsdesktop-runtime-10.0.12-win-x86.exe';
|
||||
DotNetDesktopSha256 = '57c1d40967b73785b9ef95de5f0878e9264423228971a71eb362c03ae01937f5';
|
||||
DotNetDesktopFile = 'windowsdesktop-runtime-10.0.12-win-x86.exe';
|
||||
DotNetManualUrl = 'https://dotnet.microsoft.com/download/dotnet/10.0';
|
||||
|
||||
var
|
||||
SuiteDirPage: TInputDirWizardPage;
|
||||
DotNetDownloadPage: TDownloadWizardPage;
|
||||
{ Set once the .NET step ran (interactive: on leaving the Ready page; silent: in PrepareToInstall). }
|
||||
DotNetHandled: Boolean;
|
||||
{ True once the user (or /SUITEDIR / a previous install) chose the Suite folder explicitly;
|
||||
until then it follows the RynthCore folder as a sibling "RynthSuite" folder. }
|
||||
SuiteDirPinned: Boolean;
|
||||
|
||||
function CmdLineParamExists(const Value: string): Boolean;
|
||||
var
|
||||
I: Integer;
|
||||
|
|
@ -125,6 +272,353 @@ begin
|
|||
end;
|
||||
end;
|
||||
|
||||
{ Returns the value of a /NAME=value command-line switch, or '' when absent. }
|
||||
function CmdLineParamValue(const Name: string): string;
|
||||
var
|
||||
I: Integer;
|
||||
Prefix: string;
|
||||
begin
|
||||
Result := '';
|
||||
Prefix := '/' + Name + '=';
|
||||
for I := 1 to ParamCount do
|
||||
if CompareText(Copy(ParamStr(I), 1, Length(Prefix)), Prefix) = 0 then
|
||||
begin
|
||||
Result := RemoveQuotes(Copy(ParamStr(I), Length(Prefix) + 1, MaxInt));
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
{ Suite folder recorded by an earlier install in the SAME install mode (HKA: HKCU per-user, HKLM all-users),
|
||||
or ''. Never adopt the other mode's folder: two installs sharing a Suite folder would delete each other's
|
||||
files on uninstall. }
|
||||
function RegisteredSuiteDir: string;
|
||||
begin
|
||||
Result := '';
|
||||
if not RegQueryStringValue(HKA, 'Software\Rynth', 'SuiteDir', Result) then
|
||||
Result := '';
|
||||
end;
|
||||
|
||||
{ Default Suite folder for a given RynthCore folder: its sibling "RynthSuite". }
|
||||
function SiblingSuiteDir(const CoreDir: string): string;
|
||||
begin
|
||||
Result := AddBackslash(ExtractFileDir(RemoveBackslashUnlessRoot(CoreDir))) + 'RynthSuite';
|
||||
end;
|
||||
|
||||
// {code:GetSuiteDir}: the chosen RynthSuite folder, without a trailing backslash.
|
||||
function GetSuiteDir(Param: string): string;
|
||||
begin
|
||||
if SuiteDirPage = nil then
|
||||
Result := DefaultSuiteDir
|
||||
else if WizardSilent and not SuiteDirPinned then
|
||||
{ Silent installs never run NextButtonClick: follow /DIR= with a sibling RynthSuite folder. }
|
||||
Result := SiblingSuiteDir(WizardDirValue)
|
||||
else
|
||||
Result := RemoveBackslashUnlessRoot(Trim(SuiteDirPage.Values[0]));
|
||||
end;
|
||||
|
||||
// Number of entries in ExperimentalPluginName; keep in sync with the [Components]/[Files] experimental rows.
|
||||
const
|
||||
ExperimentalCount = 6;
|
||||
|
||||
// Experimental plugin names; component "experimental\<lowercase name>" installs <Suite>\<Name>\RynthCore.Plugin.<Name>.dll.
|
||||
function ExperimentalPluginName(Index: Integer): string;
|
||||
begin
|
||||
case Index of
|
||||
0: Result := 'RynthChat';
|
||||
1: Result := 'RynthJuice';
|
||||
2: Result := 'RynthNav';
|
||||
3: Result := 'RynthTracker';
|
||||
4: Result := 'RynthVision';
|
||||
5: Result := 'UbRythai';
|
||||
else
|
||||
Result := '';
|
||||
end;
|
||||
end;
|
||||
|
||||
function ExperimentalSelected(Index: Integer): Boolean;
|
||||
begin
|
||||
Result := WizardIsComponentSelected('experimental\' + Lowercase(ExperimentalPluginName(Index)));
|
||||
end;
|
||||
|
||||
// Number of entries in SuitePluginName; keep in sync with the [Components]/[Files] suite rows.
|
||||
const
|
||||
SuitePluginCount = 21;
|
||||
|
||||
// Companion plugin names; component "suite\<lowercase name>" installs <Suite>\<Name>\RynthCore.Plugin.<Name>.dll.
|
||||
function SuitePluginName(Index: Integer): string;
|
||||
begin
|
||||
case Index of
|
||||
0: Result := 'RynthOracle';
|
||||
1: Result := 'RynthILT';
|
||||
2: Result := 'RynthInventory';
|
||||
3: Result := 'RynthSort';
|
||||
4: Result := 'RynthAChard';
|
||||
5: Result := 'RynthAelrynth';
|
||||
6: Result := 'RynthColdeve';
|
||||
7: Result := 'RynthConquest';
|
||||
8: Result := 'RynthDerptide';
|
||||
9: Result := 'RynthDreamWeave';
|
||||
10: Result := 'RynthEversong';
|
||||
11: Result := 'RynthFrostACE';
|
||||
12: Result := 'RynthFrostcull';
|
||||
13: Result := 'RynthLeafDawn';
|
||||
14: Result := 'RynthLeafdawning';
|
||||
15: Result := 'RynthLevistras';
|
||||
16: Result := 'RynthPortalStorm';
|
||||
17: Result := 'RynthReefcull';
|
||||
18: Result := 'RynthSundering';
|
||||
19: Result := 'RynthThistlecrown';
|
||||
20: Result := 'RynthThreads';
|
||||
else
|
||||
Result := '';
|
||||
end;
|
||||
end;
|
||||
|
||||
function SuitePluginSelected(Index: Integer): Boolean;
|
||||
begin
|
||||
Result := WizardIsComponentSelected('suite\' + Lowercase(SuitePluginName(Index)));
|
||||
end;
|
||||
|
||||
{ True when anything is going into the RynthSuite folder (controls the Suite folder page / memo line). }
|
||||
function AnySuiteComponentSelected: Boolean;
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
Result := WizardIsComponentSelected('rynthai') or WizardIsComponentSelected('monstereditor');
|
||||
for I := 0 to SuitePluginCount - 1 do
|
||||
if SuitePluginSelected(I) then
|
||||
Result := True;
|
||||
for I := 0 to ExperimentalCount - 1 do
|
||||
if ExperimentalSelected(I) then
|
||||
Result := True;
|
||||
end;
|
||||
|
||||
// {code:GetPendingPlugins}: ';'-separated plugin DLLs for the launcher to add to its Plugins list on next start.
|
||||
function GetPendingPlugins(Param: string): string;
|
||||
var
|
||||
I: Integer;
|
||||
Name: string;
|
||||
begin
|
||||
Result := '';
|
||||
if WizardIsComponentSelected('rynthai') then
|
||||
Result := GetSuiteDir('') + '\RynthAi\RynthCore.Plugin.RynthAi.dll';
|
||||
for I := 0 to SuitePluginCount - 1 do
|
||||
if SuitePluginSelected(I) then
|
||||
begin
|
||||
Name := SuitePluginName(I);
|
||||
if Result <> '' then
|
||||
Result := Result + ';';
|
||||
Result := Result + GetSuiteDir('') + '\' + Name + '\RynthCore.Plugin.' + Name + '.dll';
|
||||
end;
|
||||
for I := 0 to ExperimentalCount - 1 do
|
||||
if ExperimentalSelected(I) then
|
||||
begin
|
||||
Name := ExperimentalPluginName(I);
|
||||
if Result <> '' then
|
||||
Result := Result + ';';
|
||||
Result := Result + GetSuiteDir('') + '\' + Name + '\RynthCore.Plugin.' + Name + '.dll';
|
||||
end;
|
||||
end;
|
||||
|
||||
function HasPendingPlugins: Boolean;
|
||||
begin
|
||||
Result := GetPendingPlugins('') <> '';
|
||||
end;
|
||||
|
||||
{ ── .NET 10 Desktop Runtime (x86) ─────────────────────────────────────────── }
|
||||
|
||||
{ True when Root (a ...\shared\Microsoft.WindowsDesktop.App folder) holds a 10.x version folder. }
|
||||
function HasVersion10Folder(const Root: string): Boolean;
|
||||
var
|
||||
FindRec: TFindRec;
|
||||
begin
|
||||
Result := False;
|
||||
if FindFirst(AddBackslash(Root) + '10.*', FindRec) then
|
||||
try
|
||||
repeat
|
||||
if FindRec.Attributes and FILE_ATTRIBUTE_DIRECTORY <> 0 then
|
||||
begin
|
||||
Result := True;
|
||||
Exit;
|
||||
end;
|
||||
until not FindNext(FindRec);
|
||||
finally
|
||||
FindClose(FindRec);
|
||||
end;
|
||||
end;
|
||||
|
||||
{ Detects the x86 Desktop Runtime 10.x the way the .NET host does: the shared framework folder under
|
||||
Program Files (x86)\dotnet, or the installer's registration in the 32-bit registry view. }
|
||||
function IsDotNet10DesktopX86Installed: Boolean;
|
||||
var
|
||||
Names: TArrayOfString;
|
||||
I: Integer;
|
||||
begin
|
||||
Result := HasVersion10Folder(ExpandConstant('{commonpf32}\dotnet\shared\Microsoft.WindowsDesktop.App'));
|
||||
if Result then Exit;
|
||||
if RegGetValueNames(HKLM32, 'SOFTWARE\dotnet\Setup\InstalledVersions\x86\sharedfx\Microsoft.WindowsDesktop.App', Names) then
|
||||
for I := 0 to GetArrayLength(Names) - 1 do
|
||||
if Copy(Names[I], 1, 3) = '10.' then
|
||||
begin
|
||||
Result := True;
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
// Check function for the installdotnet task: offer it only when the runtime is missing.
|
||||
function DotNet10DesktopMissing: Boolean;
|
||||
begin
|
||||
Result := not IsDotNet10DesktopX86Installed;
|
||||
end;
|
||||
|
||||
function OnDotNetDownloadProgress(const Url, FileName: String; const Progress, ProgressMax: Int64): Boolean;
|
||||
begin
|
||||
Result := True; { never cancel from code; the download page has its own Abort button }
|
||||
end;
|
||||
|
||||
{ Downloads and runs the .NET 10 Desktop Runtime installer when the task is selected and the runtime is
|
||||
still missing. Returns '' on success / nothing to do, else a reason. Never blocks the RynthCore install. }
|
||||
function InstallDotNetRuntime(UsePage: Boolean): string;
|
||||
var
|
||||
SetupPath: string;
|
||||
ResultCode: Integer;
|
||||
begin
|
||||
Result := '';
|
||||
DotNetHandled := True;
|
||||
if not WizardIsTaskSelected('installdotnet') or IsDotNet10DesktopX86Installed then
|
||||
Exit;
|
||||
|
||||
Log('.NET 10 Desktop Runtime (x86) missing; downloading ' + DotNetDesktopUrl);
|
||||
try
|
||||
if UsePage then
|
||||
begin
|
||||
DotNetDownloadPage.Clear;
|
||||
DotNetDownloadPage.Add(DotNetDesktopUrl, DotNetDesktopFile, DotNetDesktopSha256);
|
||||
DotNetDownloadPage.Show;
|
||||
try
|
||||
DotNetDownloadPage.Download;
|
||||
finally
|
||||
DotNetDownloadPage.Hide;
|
||||
end;
|
||||
end
|
||||
else
|
||||
DownloadTemporaryFile(DotNetDesktopUrl, DotNetDesktopFile, DotNetDesktopSha256, @OnDotNetDownloadProgress);
|
||||
except
|
||||
Result := 'the download failed (' + GetExceptionMessage + ')';
|
||||
Exit;
|
||||
end;
|
||||
|
||||
{ The runtime's own bundle asks for elevation (UAC) itself when this setup is not elevated. }
|
||||
SetupPath := ExpandConstant('{tmp}\' + DotNetDesktopFile);
|
||||
Log('Running ' + SetupPath + ' /install /quiet /norestart');
|
||||
if not ShellExec('', SetupPath, '/install /quiet /norestart', '', SW_SHOW, ewWaitUntilTerminated, ResultCode) then
|
||||
Result := 'its installer could not be started (' + SysErrorMessage(ResultCode) + ')'
|
||||
{ 0 = installed, 3010/1641 = installed (restart pending/started), 1638 = a newer version is already installed }
|
||||
else if (ResultCode <> 0) and (ResultCode <> 3010) and (ResultCode <> 1641) and (ResultCode <> 1638) then
|
||||
Result := 'its installer exited with code ' + IntToStr(ResultCode) + ' (1602 = cancelled)'
|
||||
else
|
||||
Log('.NET 10 Desktop Runtime installer finished, exit code ' + IntToStr(ResultCode));
|
||||
end;
|
||||
|
||||
{ Runs the .NET step and reports (but never fails on) a problem. }
|
||||
procedure HandleDotNetRuntime(UsePage: Boolean);
|
||||
var
|
||||
Problem: string;
|
||||
begin
|
||||
Problem := InstallDotNetRuntime(UsePage);
|
||||
if Problem = '' then Exit;
|
||||
Log('.NET 10 Desktop Runtime was not installed: ' + Problem);
|
||||
if not WizardSilent then
|
||||
MsgBox('The Microsoft .NET 10 Desktop Runtime could not be installed: ' + Problem + '.' + #13#10#13#10 +
|
||||
'RynthCore will still be installed and works without it (it is self-contained). ' +
|
||||
'You can install the runtime later from:' + #13#10 + DotNetManualUrl, mbInformation, MB_OK);
|
||||
end;
|
||||
|
||||
procedure InitializeWizard;
|
||||
var
|
||||
Initial: string;
|
||||
begin
|
||||
{ After the Components page, so ShouldSkipPage knows whether any Suite component was picked. }
|
||||
SuiteDirPage := CreateInputDirPage(wpSelectComponents,
|
||||
'Select RynthSuite Location',
|
||||
'Where should the RynthSuite plugins and their data be installed?',
|
||||
'RynthAi, the Monster Editor, the companion plugins and any experimental plugins you picked will be installed into the RynthSuite folder below, and your ' +
|
||||
'profiles (nav, loot, meta, settings) are kept there. To continue, click Next. ' +
|
||||
'If you would like to select a different folder, click Browse.',
|
||||
False, 'RynthSuite');
|
||||
SuiteDirPage.Add('');
|
||||
|
||||
{ Priority: /SUITEDIR= → previous install of this setup → registry → C:\Games\RynthSuite. }
|
||||
Initial := CmdLineParamValue('SUITEDIR');
|
||||
if Initial = '' then Initial := GetPreviousData('SuiteDir', '');
|
||||
if Initial = '' then Initial := RegisteredSuiteDir;
|
||||
SuiteDirPinned := Initial <> '';
|
||||
if Initial = '' then Initial := DefaultSuiteDir;
|
||||
SuiteDirPage.Values[0] := Initial;
|
||||
|
||||
{ Progress page for the optional .NET 10 Desktop Runtime download (shown only when that task runs). }
|
||||
DotNetDownloadPage := CreateDownloadPage('Downloading Prerequisites',
|
||||
'Downloading the Microsoft .NET 10 Desktop Runtime (x86)...', @OnDotNetDownloadProgress);
|
||||
end;
|
||||
|
||||
procedure RegisterPreviousData(PreviousDataKey: Integer);
|
||||
begin
|
||||
SetPreviousData(PreviousDataKey, 'SuiteDir', GetSuiteDir(''));
|
||||
end;
|
||||
|
||||
function ShouldSkipPage(PageID: Integer): Boolean;
|
||||
begin
|
||||
{ No Suite components selected → no Suite folder to choose. }
|
||||
Result := (SuiteDirPage <> nil) and (PageID = SuiteDirPage.ID) and not AnySuiteComponentSelected;
|
||||
end;
|
||||
|
||||
function NextButtonClick(CurPageID: Integer): Boolean;
|
||||
var
|
||||
Dir: string;
|
||||
begin
|
||||
Result := True;
|
||||
|
||||
{ Leaving the RynthCore folder page: keep an un-pinned Suite folder beside the chosen Core folder. }
|
||||
if (CurPageID = wpSelectDir) and not SuiteDirPinned then
|
||||
SuiteDirPage.Values[0] := SiblingSuiteDir(WizardDirValue);
|
||||
|
||||
if (SuiteDirPage <> nil) and (CurPageID = SuiteDirPage.ID) then
|
||||
begin
|
||||
Dir := GetSuiteDir('');
|
||||
{ Require an absolute local or UNC path (e.g. D:\Games\RynthSuite or \\server\share\RynthSuite). }
|
||||
if (Length(Dir) < 3) or not ((Copy(Dir, 2, 2) = ':\') or (Copy(Dir, 1, 2) = '\\')) then
|
||||
begin
|
||||
MsgBox('Please choose a full folder path for RynthSuite, for example D:\Games\RynthSuite.', mbError, MB_OK);
|
||||
Result := False;
|
||||
Exit;
|
||||
end;
|
||||
SuiteDirPinned := True;
|
||||
end;
|
||||
|
||||
{ Leaving the Ready page: fetch/install the .NET runtime first (with a progress page) if that task is on. }
|
||||
if CurPageID = wpReady then
|
||||
HandleDotNetRuntime(True);
|
||||
end;
|
||||
|
||||
// Silent installs skip the wizard pages, so the .NET step runs here instead (no progress page). Never blocks.
|
||||
function PrepareToInstall(var NeedsRestart: Boolean): String;
|
||||
begin
|
||||
if not DotNetHandled then
|
||||
HandleDotNetRuntime(False);
|
||||
Result := '';
|
||||
end;
|
||||
|
||||
function UpdateReadyMemo(Space, NewLine, MemoUserInfoInfo, MemoDirInfo, MemoTypeInfo,
|
||||
MemoComponentsInfo, MemoGroupInfo, MemoTasksInfo: String): String;
|
||||
begin
|
||||
Result := MemoDirInfo + NewLine;
|
||||
if AnySuiteComponentSelected then
|
||||
Result := Result + 'RynthSuite location:' + NewLine + Space + GetSuiteDir('') + NewLine;
|
||||
Result := Result + NewLine + MemoComponentsInfo;
|
||||
if MemoTasksInfo <> '' then
|
||||
Result := Result + NewLine + MemoTasksInfo;
|
||||
end;
|
||||
|
||||
(* -------------------------------------------------------------------------------------
|
||||
Decal + RynthCore (experimental), strictly opt-in (since 2026-10-10): on install and on
|
||||
every update (the launcher's updater runs this installer with /SILENT), the RynthCore
|
||||
|
|
|
|||
1
installer/previous-release/last-built-version.txt
Normal file
1
installer/previous-release/last-built-version.txt
Normal file
|
|
@ -0,0 +1 @@
|
|||
2026.11.22.48
|
||||
124
installer/previous-release/last-release-manifest.json
Normal file
124
installer/previous-release/last-release-manifest.json
Normal file
|
|
@ -0,0 +1,124 @@
|
|||
{
|
||||
"schema": 1,
|
||||
"product": "RynthCore + RynthSuite",
|
||||
"version": "2026.10.18.13",
|
||||
"release": 2026101813,
|
||||
"builtUtc": "2026-10-18T03:51:03Z",
|
||||
"previous": "2026.10.18.11",
|
||||
"installer": {
|
||||
"file": "RynthCore-Setup-2026.10.18.13.exe",
|
||||
"size": 138670467,
|
||||
"sha256": "db6ab30f1e5bedcc6832525883f6a3b88e0675cfe10e9b9e3dfb8d2a8a0f2eb2"
|
||||
},
|
||||
"source": {
|
||||
"rynthCore": {
|
||||
"branch": "test/hotbuild-2026-10-16-on-aelrynth",
|
||||
"commit": "6b6442faa23bea6b2ede9a377406c8e5abddf058",
|
||||
"dirty": false
|
||||
},
|
||||
"rynthSuite": {
|
||||
"branch": "test/hotbuild-2026-10-16-on-aelrynth",
|
||||
"commit": "85c2e4f17bf7882b9420f787cdec94bf8e4508e1",
|
||||
"dirty": false
|
||||
}
|
||||
},
|
||||
"components": [
|
||||
{
|
||||
"name": "Launcher (RynthCore.exe)",
|
||||
"file": "core\\RynthCore.exe",
|
||||
"version": "2026.10.18.13+6b6442faa23bea6b2ede9a377406c8e5abddf058"
|
||||
},
|
||||
{
|
||||
"name": "Engine",
|
||||
"file": "core\\Runtime\\RynthCore.Engine.dll",
|
||||
"version": "2026.10.18.13+6b6442faa23bea6b2ede9a377406c8e5abddf058"
|
||||
},
|
||||
{
|
||||
"name": "Loader",
|
||||
"file": "core\\Runtime\\RynthCore.Loader.dll",
|
||||
"version": ""
|
||||
},
|
||||
{
|
||||
"name": "Loot Editor",
|
||||
"file": "core\\Tools\\LootEditor\\RynthCore.LootEditor.exe",
|
||||
"version": "2026.10.18.13+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthAi plugin",
|
||||
"file": "suite\\RynthAi\\RynthCore.Plugin.RynthAi.dll",
|
||||
"version": "2026.10.18.13+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "Monster Editor",
|
||||
"file": "suite\\RynthAi\\MonsterEditor\\RynthCore.MonsterEditor.exe",
|
||||
"version": "2026.10.18.13+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthOracle plugin",
|
||||
"file": "suite\\RynthOracle\\RynthCore.Plugin.RynthOracle.dll",
|
||||
"version": "2026.10.18.13+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthILT plugin",
|
||||
"file": "suite\\RynthILT\\RynthCore.Plugin.RynthILT.dll",
|
||||
"version": "2026.10.18.13+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthInventory plugin",
|
||||
"file": "suite\\RynthInventory\\RynthCore.Plugin.RynthInventory.dll",
|
||||
"version": "2026.10.18.13+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthSort plugin",
|
||||
"file": "suite\\RynthSort\\RynthCore.Plugin.RynthSort.dll",
|
||||
"version": "2026.10.18.13+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthChat (experimental)",
|
||||
"file": "suite\\RynthChat\\RynthCore.Plugin.RynthChat.dll",
|
||||
"version": "1.0.0+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthJuice (experimental)",
|
||||
"file": "suite\\RynthJuice\\RynthCore.Plugin.RynthJuice.dll",
|
||||
"version": "0.1.3-experimental+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthNav (experimental)",
|
||||
"file": "suite\\RynthNav\\RynthCore.Plugin.RynthNav.dll",
|
||||
"version": "1.0.0+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthTracker (experimental)",
|
||||
"file": "suite\\RynthTracker\\RynthCore.Plugin.RynthTracker.dll",
|
||||
"version": "1.0.0+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "RynthVision (experimental)",
|
||||
"file": "suite\\RynthVision\\RynthCore.Plugin.RynthVision.dll",
|
||||
"version": "1.0.0+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
},
|
||||
{
|
||||
"name": "UbRythai (experimental)",
|
||||
"file": "suite\\UbRythai\\RynthCore.Plugin.UbRythai.dll",
|
||||
"version": "3.1.15+85c2e4f17bf7882b9420f787cdec94bf8e4508e1"
|
||||
}
|
||||
],
|
||||
"changelog": [
|
||||
"RynthCore/Changelog/2026-10-17-test-build-full-install-2026.10.18.4.md",
|
||||
"RynthCore/Changelog/2026-10-18-graphics-low-memory-safeguard-2026.10.18.11.md",
|
||||
"RynthCore/Changelog/2026-10-18-loot-add-attribute-checklist-2026.10.18.10.md",
|
||||
"RynthSuite/Changelog/2026-10-17-chaser-ring-evade-0.5.84.md",
|
||||
"RynthSuite/Changelog/2026-10-17-handler-ring-run-away-0.5.83.md",
|
||||
"RynthSuite/Changelog/2026-10-17-oracle-dynamic-stamps-tab-0.5.0.md",
|
||||
"RynthSuite/Changelog/2026-10-17-vt-mt-commands-port-0.5.85.md",
|
||||
"RynthSuite/Changelog/2026-10-18-loot-add-attribute-checklist-0.5.87.md",
|
||||
"RynthSuite/Changelog/2026-10-18-meta-samples-compat-0.5.88.md",
|
||||
"RynthSuite/Changelog/2026-10-18-ub-it-meta-compat-0.5.86.md"
|
||||
],
|
||||
"changelogSince": {
|
||||
"rynthCore": "28fede68151c65934949d19edfa4c7efc4e15a1e",
|
||||
"rynthSuite": "7877c869e77d3c251bdd3e7fb72030e979cf0e18",
|
||||
"date": ""
|
||||
}
|
||||
}
|
||||
1
installer/previous-release/previous-version.txt
Normal file
1
installer/previous-release/previous-version.txt
Normal file
|
|
@ -0,0 +1 @@
|
|||
2026.11.22.47
|
||||
Loading…
Reference in a new issue