Snapshot for release 2026.10.20.1 (internal e05e9a8)

This commit is contained in:
Tom Bohar 2026-10-20 21:28:16 -04:00
commit 286abd1445
35 changed files with 3569 additions and 65 deletions

View file

@ -18,6 +18,7 @@
<ItemGroup>
<Compile Include="..\..\src\RynthCore.Engine\UI\Data\CharactersModel.cs" Link="Engine\CharactersModel.cs" />
<Compile Include="..\..\src\RynthCore.Engine\Compatibility\HeadingMath.cs" Link="Engine\HeadingMath.cs" />
</ItemGroup>
</Project>

View file

@ -1,3 +1,4 @@
using RynthCore.Engine.Compatibility;
using RynthCore.Engine.UI.Data;
namespace CharactersPanelTests;
@ -25,6 +26,7 @@ internal static class Program
Stale();
StableOrder();
Vitals();
HeadingIsCompass();
Console.WriteLine($"{_checks} checks, {_failed} failed");
return _failed == 0 ? 0 : 1;
@ -248,4 +250,23 @@ internal static class Program
Check(Near(CharactersModel.Fraction(300, 400), 0.75), "fraction");
Check(CharactersModel.Fraction(5, 0) == 0 && CharactersModel.Fraction(500, 400) == 1, "fraction clamps");
}
// The row arrows draw bearing - heading, so the heading must be a compass one. Freya,
// 2026-10-20: the quaternion said 13.9 (NNE), GetPlayerHeading 76.1 (= 90 - 13.9); the
// arrows used 76.1 and pointed 62 degrees off.
private static void HeadingIsCompass()
{
static (float qw, float qz) Facing(double compass) =>
((float)Math.Cos(-compass * Math.PI / 360.0), (float)Math.Sin(-compass * Math.PI / 360.0));
var (fw, fz) = Facing(13.944);
Check(Near(HeadingMath.CompassFromYaw(fw, fz), 13.944, 0.01), "Freya's quaternion reads 13.9 (NNE)");
foreach (double h in new[] { 0.0, 45.0, 90.0, 180.0, 270.0, 359.0 })
{
var (qw, qz) = Facing(h);
Check(Near(HeadingMath.CompassFromYaw(qw, qz), h, 0.01), $"compass {h} round-trips through TurnToHeading's quaternion");
}
var (nw, nz) = Facing(90); // facing east
Check(Near(180.0 - HeadingMath.CompassFromYaw(nw, nz), 90, 0.01), "facing east, a target due south is 90 degrees to the right");
Check(Near(HeadingMath.CompassFromYaw(-fw, -fz), 13.944, 0.01), "the same rotation with a negated quaternion");
}
}

View file

@ -52,6 +52,7 @@ internal static class Program
RetailStandardFilters();
RetailRules();
RetailSetting();
TabsAcrossSetting();
SharedFileReload();
LineColorTags();
LineColorKinds();
@ -603,6 +604,20 @@ internal static class Program
Check(JsonSerializer.Deserialize(off, opts)!.Filters!.Length == 3, "the other fields are untouched");
}
private static void TabsAcrossSetting()
{
Case("tabs across the top: off (the drawer) unless a file says true");
var opts = RynthChatJsonContext.Default.RynthChatSettingsDto;
RynthChatSettingsDto old = JsonSerializer.Deserialize(OldFile, opts)!;
Check(old.TabsAcross == null, "a file from before the setting has no value (ChatModel reads that as the drawer)");
Check(!JsonSerializer.Serialize(old, opts).Contains("tabsAcross", StringComparison.Ordinal), "saving it writes no tabsAcross key");
old.TabsAcross = true;
string on = JsonSerializer.Serialize(old, opts);
Check(on.Contains("\"tabsAcross\":true", StringComparison.Ordinal), "on is saved as tabsAcross:true");
Check(JsonSerializer.Deserialize(on, opts)!.TabsAcross == true, "on loads back");
Check(JsonSerializer.Deserialize(on, opts)!.Filters!.Length == 3, "the other fields are untouched");
}
// ── Shared settings reload (2026-10-19; idea from Silentkelpie, rynth PR 6) ──
// SharedFileWatch: another client rewrote rynthchat_settings.json -> read it; our own saves don't count.

View file

@ -23,6 +23,9 @@
<Compile Include="..\..\src\RynthCore.App.Avalonia\RynthUpdater.MapPacks.cs" Link="Linked\RynthUpdater.MapPacks.cs" />
<Compile Include="..\..\src\RynthCore.App.Avalonia\RynthUpdater.NavData.cs" Link="Linked\RynthUpdater.NavData.cs" />
<Compile Include="..\..\src\RynthCore.App.Avalonia\RynthUpdater.Available.cs" Link="Linked\RynthUpdater.Available.cs" />
<Compile Include="..\..\src\RynthCore.App.Avalonia\PluginNames.cs" Link="Linked\PluginNames.cs" />
<Compile Include="..\..\src\RynthCore.App\KnownServerCatalog.cs" Link="Linked\KnownServerCatalog.cs" />
<Compile Include="..\..\src\RynthCore.App\LaunchServerProfile.cs" Link="Linked\LaunchServerProfile.cs" />
<Compile Include="..\..\src\RynthCore.App.Avalonia\DownloadProgress.cs" Link="Linked\DownloadProgress.cs" />
<Compile Include="..\..\src\RynthCore.App.Avalonia\UpdateCardModel.cs" Link="Linked\UpdateCardModel.cs" />
<Compile Include="..\..\src\RynthCore.App.Avalonia\UpdateTrust.cs" Link="Linked\UpdateTrust.cs" />

View file

@ -36,6 +36,7 @@ internal static class Program
try
{
await Run(nameof(AvailableIsFeedMinusInstalled), AvailableIsFeedMinusInstalled);
await Run(nameof(PluginNamesAndServerSplit), () => { PluginNamesAndServerSplit(); return Task.CompletedTask; });
await Run(nameof(OnlyRynthLuaIsAutomatic), OnlyRynthLuaIsAutomatic);
await Run(nameof(OldManifestWithoutDescriptions), OldManifestWithoutDescriptions);
await Run(nameof(DescriptionsAreOneShortLine), DescriptionsAreOneShortLine);
@ -701,6 +702,24 @@ internal static class Program
Check(verified.Title == "RynthNav map: verified", "verified step shown");
}
/// <summary>
/// The plugin list shows "RynthAi" (not "RynthCore.Plugin.RynthAi"), and a plugin for one game server
/// goes on the Server plugins tab (RynthThreads too: DreamWeave only), the rest on Plugins.
/// </summary>
private static void PluginNamesAndServerSplit()
{
Check(RynthCore.App.Avalonia.PluginNames.Friendly(@"C:\Games\RynthSuite\RynthAi\RynthCore.Plugin.RynthAi.dll") == "RynthAi", "a DLL path: the short name");
Check(RynthCore.App.Avalonia.PluginNames.Friendly("RynthCore.Plugin.RynthNav") == "RynthNav", "a file name without .dll");
Check(RynthCore.App.Avalonia.PluginNames.Friendly("RynthOracle") == "RynthOracle", "a feed name stays");
Check(RynthCore.App.Avalonia.PluginNames.Friendly("SomeoneElse.dll") == "SomeoneElse", "another plugin keeps its name");
foreach (string s in new[] { "RynthDreamWeave", "RynthConquest", "RynthILT", "RynthThreads", "RynthCore.Plugin.RynthAelrynth.dll" })
Check(RynthCore.App.Avalonia.PluginNames.IsServerPlugin(s), $"{s}: a server plugin");
foreach (string s in new[] { "RynthAi", "RynthNav", "RynthChat", "RynthNet", "RynthLua", "SomeoneElse" })
Check(!RynthCore.App.Avalonia.PluginNames.IsServerPlugin(s), $"{s}: a regular plugin");
Check(RynthCore.App.Avalonia.PluginNames.ServerOf("RynthThreads")?.Name == "DreamWeave", "RynthThreads is DreamWeave's");
Check(RynthUpdater.DescribeByName("RynthNet").Length > 0 && RynthUpdater.DescribeByName("RynthSort").Length > 0, "every RynthSuite plugin has a line");
}
private static void UpdateCardWhatsNew()
{
var six = new[] { "One.", "Two.", "Three.", "Four.", "Five.", "Six." };