feat(suite): Vaulted Dungeons tab, Oracle breeding/charms, Mini Remote Options

Port tonight's Suite work onto standing sk for upstream release prep: ILT Vaulted Dungeons (Options-gated), chat 0x1C channels, Oracle Charms/Pet Breeding, Mini Remote Options opens Settings. HandWrittenVersion stays 0.5.0-legacy-ui.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
BlankenshipG 2026-10-16 00:55:13 -04:00
commit 0532d8d981
43 changed files with 2129 additions and 197 deletions

View file

@ -15,16 +15,21 @@
// "checking" until the reply arrives, then on or off.
// * No server bit at all (the Temple guardians, Paragon gear): content, on with the ILT world.
// Off an ILT world nothing is claimed: every state is unknown.
// The list feeds the ILT settings window ("/ilt settings", IltSettingsView/) and "/ra hub features".
// The list feeds RynthOracle's About tab ("Server features", via the profile JSON), "/ra hub features",
// and the "RynthILT.Server" profile JSON other plugins read (Plugins/Shared/RynthIltServerApi.cs:
// RynthOracle's Fellowship tab takes the fellowship rules from it, and its Quests tab the /qb list).
// Server facts copied from ACECustom: Fellowship.MaxFellows = 29 (Source/ACE.Server/Entity/
// Fellowship.cs), Zone Share (ZoneShareManager) and the fellowship luminance share.
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Text;
using RynthCore.Plugin.Shared;
namespace RynthCore.Plugin.RynthILT.Hub;
/// <summary>One Leaftide feature: id, display text, where it lives, and the server bit that says whether it's on.</summary>
/// <param name="Key">Stable id.</param>
/// <param name="Key">Stable id (the profile JSON's "key").</param>
/// <param name="Label">Display name.</param>
/// <param name="Group">Character, Items, Fellowship or Activities (the list's sections).</param>
/// <param name="Where">Where the Rynth tools handle it.</param>
@ -45,6 +50,16 @@ internal enum IltKnown
ProfileOff,
}
/// <summary>The quest bonus list as the profile JSON carries it ("questBonus"), for RynthOracle's Quests tab.</summary>
/// <param name="Disabled">The server has /qb turned off.</param>
/// <param name="Generation">Bumped per parsed "/qb list"; 0 = not loaded this session.</param>
/// <param name="Count">The server's quest bonus count; -1 = unknown.</param>
/// <param name="Status">One line on the last request ("loading...", "12 completed, 3 incomplete", ...).</param>
/// <param name="Completed">Completed bonus flags, sorted.</param>
/// <param name="Incomplete">Incomplete bonus flags, sorted.</param>
internal sealed record IltQuestBonusInfo(bool Disabled, int Generation, long Count, string Status,
IReadOnlyList<string> Completed, IReadOnlyList<string> Incomplete);
internal static class IltFeatureCatalog
{
public const string GroupCharacter = "Character";
@ -60,16 +75,13 @@ internal static class IltFeatureCatalog
/// <summary>ACECustom's fellowship member limit (Fellowship.MaxFellows); retail is 9.</summary>
public const int IltFellowshipMax = 29;
/// <summary>A retail fellowship's member limit.</summary>
public const int RetailFellowshipMax = 9;
/// <summary>Every Leaftide feature RynthILT supports, in display order.</summary>
public static readonly IltFeatureInfo[] All =
{
// Character progression and money.
new("bank", "Banking", GroupCharacter, "Mini Remote > Banking tab; Remote tab bank line",
new("bank", "Banking", GroupCharacter, "Global Inventory > Banking (/ginv bank); Remote tab bank line",
"Bank pyreals, luminance, keys and coins; deposit, withdraw and transfer (/bank).", IltFeature.Bank, IltKnown.Checked),
new("bank_notes", "Trade note banking", GroupCharacter, "Mini Remote > Banking tab (trade notes)",
new("bank_notes", "Trade note banking", GroupCharacter, "Global Inventory > Banking (/ginv bank, notes)",
"Deposit trade notes as pyreals, withdraw any note from I to MMD, transfer note value (/bank d n).", "bank_notes"),
new("guardian", "Guardian (infinite base attributes)", GroupCharacter, "Guardian panel (/rc guardian)",
"Temple of Enlightenment guardians raise base attributes past the retail cap.", null),
@ -102,7 +114,7 @@ internal static class IltFeatureCatalog
"t11_craft_gate"),
new("split_arrows", "Split arrows", GroupItems, "Mini Remote > Gear > Split arrows",
"Missile weapons carry split arrows, added with White Quartz salvage.", "split_arrows"),
new("charms", "Charms", GroupItems, "Mini Remote > Charms tab",
new("charms", "Charms", GroupItems, "RynthOracle > Character (/ro character)",
"Registry charms and the Guardian Hand, with their toggles; each charm is listed in the Charms section.", "charms"),
new("clap", "Chunk clap (auto craft)", GroupItems, "Mini Remote > Gear tab",
"Turns aetheria, chunks and trinkets into banked enlightened coins (/clap all).", IltFeature.Clap, IltKnown.Checked),
@ -111,10 +123,10 @@ internal static class IltFeatureCatalog
new("pets", "Pet log", GroupPets, "Mini Remote > Pets tab", "Captured pets, registered with Professor Ruggan (/pets).", IltFeature.Pets, IltKnown.Checked),
new("shinies", "Shiny log", GroupPets, "Mini Remote > Pets tab", "Rare shiny creature variants you captured (/shinies).", IltFeature.Shinies, IltKnown.Checked),
new("monster_capture", "Monster capture", GroupPets, "Mini Remote > Pets tab",
"Siphon lenses capture a creature\'s look into a pet essence (<=20% health or under 20 HP; Asheron\'s Lens skips the gate). Auto-capture is the checkbox on the Pets roster.", "monster_capture"),
new("pet_breeding", "Pet breeding", GroupPets, "Mini Remote > Pets > Breeding",
"Siphon lenses capture a creature's look into a pet essence (≤20% health or under 20 HP; Asheron's Lens skips the gate). Auto-capture is the checkbox on the Pets roster.", "monster_capture"),
new("pet_breeding", "Pet breeding", GroupPets, "Mini Remote > Pets > Breeding; RynthOracle > Pet Breeding",
"Breed two combat pet devices at the Seedy Motel for inherited and mutated offspring (/dance).", "pet_breeding"),
new("pet_maturity", "Pet maturity", GroupPets, "Mini Remote > Pets > Breeding",
new("pet_maturity", "Pet maturity", GroupPets, "Mini Remote > Pets > Breeding; RynthOracle > Pet Breeding",
"Bred pets start small and weak and grow up with kills.", "pet_maturity"),
new("pet_bond", "Pet bond", GroupPets, "Mini Remote > Pets tab",
"Pets gain bond XP from kills, which scales their stats (/top bonds). On in ILT (breeding needs bond 100).", IltFeature.PetBond),
@ -130,9 +142,9 @@ internal static class IltFeatureCatalog
"Ask for a name for your pet; staff approve it (/pet-name).", "pet_naming"),
// Fellowship.
new("fellowship_large", "Large fellowships (up to 29)", GroupFellowship, "The game's fellowship panel",
new("fellowship_large", "Large fellowships (up to 29)", GroupFellowship, "RynthOracle > Fellowship",
"Fellowships hold up to 29 members instead of retail's 9.", "fellowship_size"),
new("fship", "Fellowship commands", GroupFellowship, "ILT fellowship window (/ilt fellow)",
new("fship", "Fellowship commands", GroupFellowship, "RynthOracle > Fellowship (ILT /fship)",
"Create, invite, invite your landblock, list nearby, leave and disband from chat (/fship).", "fship"),
new("zone_share", "Zone Share", GroupFellowship, "Mini Remote > Session Stats (luminance, pass-up)",
"XP and luminance shared with everyone in a Zone Share area, capped at a fellowship's size.", "zone_share"),
@ -158,11 +170,15 @@ internal static class IltFeatureCatalog
"Curbs extreme evasion at very high defense skill. Off by default in ACECustom.", "defense_scaling", IltKnown.ProfileOff),
// Activities.
new("quests", "Quest tracker", GroupActivities, "Mini Remote > Quests tab",
new("quests", "Quest tracker", GroupActivities, "RynthOracle > Quests tab",
"Your quest timers from the server (/myquests).", IltFeature.Quests, IltKnown.Checked),
new("quest_bonus", "Quest bonus", GroupActivities, "Mini Remote > Quests tab (quest bonus)",
new("quest_bonus", "Quest bonus", GroupActivities, "RynthOracle > Quests tab",
"Each quest completed adds to your XP bonus; the list (/qb).", IltFeature.Qb, IltKnown.Checked),
new("bounties", "Bounties", GroupActivities, "Bounties window (/rc bounties)", "ACECustom bounties and your progress.", "bounties"),
new("vaulted_dungeons", "Vaulted Dungeons", GroupActivities,
"Mini Remote > Vaulted Dungeons (/ilt vaulted; Options > Navigation)",
"Keeps you in one Vaulted Dungeon via a tied portal recall gem; optional kill-client on no luminance kill.",
null), // content: on with the ILT world; the Options checkbox only shows the Mini Remote tab
new("rifts", "Greater Rifts", GroupActivities, "Chat: /rift", "Private, timed dungeon runs that scale by tier (/rift).", "rifts"),
new("room_assign", "Room Assign dungeons", GroupActivities, "Portals and recalls",
"One-player rooms with their own spawns.", "room_assign"),
@ -226,7 +242,7 @@ internal static class IltFeatureCatalog
foreach (IltCharmDef def in IltInventory.Charms)
if (IltFeature.Charm(def.Name).Equals(key, StringComparison.OrdinalIgnoreCase))
return (def.Name, GroupCharms, (def.Effect.Length > 0 ? def.Effect + "\n" : string.Empty)
+ "Where: Mini Remote > Charms tab\n" + charmNote);
+ "Where: RynthOracle > Character (/ro character)\n" + charmNote);
return (key.Substring(CharmKeyPrefix.Length), GroupCharms, charmNote);
}
return (key, GroupOther, "A server switch RynthILT reads from chat.");
@ -255,7 +271,69 @@ internal static class IltFeatureCatalog
};
/// <summary>The fellowship member limit: ACECustom's 29 on an ILT world, retail's 9 elsewhere.</summary>
public static int FellowshipMax(bool iltWorld) => iltWorld ? IltFellowshipMax : RetailFellowshipMax;
public static int FellowshipMax(bool iltWorld) => iltWorld ? IltFellowshipMax : RynthIltServer.RetailFellowshipMax;
/// <summary>
/// The "RynthILT.Server" profile JSON (schema in Plugins/Shared/RynthIltServerApi.cs). Pure:
/// everything comes in as arguments, so the tests build it without a client. Plain ASCII.
/// </summary>
public static string BuildProfileJson(bool iltWorld, string world, bool forced, string source, DateTime checkedUtc,
Func<string, IltTri> bit, IltQuestBonusInfo? questBonus = null)
{
var sb = new StringBuilder(4096);
sb.Append("{\"ilt\":").Append(iltWorld ? "true" : "false");
sb.Append(",\"world\":\"").Append(Escape(world)).Append('"');
sb.Append(",\"forced\":").Append(forced ? "true" : "false");
sb.Append(",\"source\":\"").Append(Escape(source)).Append('"');
sb.Append(",\"checked\":\"")
.Append(checkedUtc == DateTime.MinValue ? "" : checkedUtc.ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ", CultureInfo.InvariantCulture))
.Append('"');
sb.Append(",\"features\":[");
for (int i = 0; i < All.Length; i++)
{
IltFeatureInfo f = All[i];
if (i > 0) sb.Append(',');
sb.Append("{\"key\":\"").Append(Escape(f.Key))
.Append("\",\"label\":\"").Append(Escape(f.Label))
.Append("\",\"group\":\"").Append(Escape(f.Group))
.Append("\",\"state\":").Append(((int)StateOf(f, iltWorld, bit)).ToString(CultureInfo.InvariantCulture))
.Append(",\"where\":\"").Append(Escape(f.Where)).Append("\"}");
}
sb.Append(']');
int State(string key) => (int)StateOf(Find(key)!, iltWorld, bit);
sb.Append(",\"fellowship\":{\"maxMembers\":").Append(FellowshipMax(iltWorld).ToString(CultureInfo.InvariantCulture))
.Append(",\"zoneShare\":").Append(State("zone_share").ToString(CultureInfo.InvariantCulture))
.Append(",\"blackjack\":").Append(State("fellowship_blackjack").ToString(CultureInfo.InvariantCulture))
.Append(",\"luminanceShare\":").Append(State("fellowship_luminance").ToString(CultureInfo.InvariantCulture))
.Append('}');
// The /qb list (ILT worlds only): RynthOracle's Quests tab draws it.
if (questBonus != null && iltWorld)
{
sb.Append(",\"questBonus\":{\"disabled\":").Append(questBonus.Disabled ? "true" : "false")
.Append(",\"generation\":").Append(questBonus.Generation.ToString(CultureInfo.InvariantCulture))
.Append(",\"count\":").Append(questBonus.Count.ToString(CultureInfo.InvariantCulture))
.Append(",\"status\":\"").Append(Escape(questBonus.Status)).Append('"');
AppendList(sb, "completed", questBonus.Completed);
AppendList(sb, "incomplete", questBonus.Incomplete);
sb.Append('}');
}
sb.Append('}');
return sb.ToString();
static void AppendList(StringBuilder b, string name, IReadOnlyList<string> items)
{
b.Append(",\"").Append(name).Append("\":[");
for (int i = 0; i < items.Count; i++)
{
if (i > 0) b.Append(',');
b.Append('"').Append(Escape(items[i])).Append('"');
}
b.Append(']');
}
}
/// <summary>The chat listing for "/ra hub features": one line per feature, ASCII only.</summary>
public static List<string> BuildChatLines(bool iltWorld, Func<string, IltTri> bit)
@ -270,4 +348,19 @@ internal static class IltFeatureCatalog
}
return lines;
}
/// <summary>JSON string body: quotes, backslashes and control characters escaped, anything non-ASCII as \uXXXX.</summary>
private static string Escape(string? s)
{
if (string.IsNullOrEmpty(s)) return string.Empty;
var sb = new StringBuilder(s.Length + 8);
foreach (char c in s)
{
if (c == '"') sb.Append("\\\"");
else if (c == '\\') sb.Append("\\\\");
else if (c < 0x20 || c > 0x7E) sb.Append("\\u").Append(((int)c).ToString("x4", CultureInfo.InvariantCulture));
else sb.Append(c);
}
return sb.ToString();
}
}

View file

@ -64,6 +64,8 @@ internal sealed class IltHubController
public IltCharms CharmsTab { get; }
/// <summary>Temple guardians: riddle translator, hand-in, attribute turn-in tracker.</summary>
public IltGuardian Guardian { get; }
/// <summary>Vaulted Dungeons keeper (Mini Remote tab; Options > Navigation gate in RynthAi).</summary>
public IltVaultedDungeons VaultedDungeons { get; }
/// <param name="writesBlocked">True while this character's copy from RynthAi is unfinished (IltHubStore.WritesBlocked).</param>
/// <param name="legacyFolder">The character's RynthAi folder while that copy is unfinished (read-only fallback).</param>
@ -92,7 +94,8 @@ internal sealed class IltHubController
Charms = new IltCharmTracker(_ctx);
CharmsTab = new IltCharms(_ctx, Charms);
Guardian = new IltGuardian(_ctx, QuestBonus);
_features.AddRange(new IIltFeature[] { Banking, PetLogs, Breeding, Rates, QuestBonus, Progression, Gear, CharmsTab, Games, Guardian });
VaultedDungeons = new IltVaultedDungeons(_ctx);
_features.AddRange(new IIltFeature[] { Banking, PetLogs, Breeding, Rates, QuestBonus, Progression, Gear, CharmsTab, Games, VaultedDungeons, Guardian });
Banking.BalanceChanged += Rates.OnBankBalanceChanged;
Rates.MovingMoney = () => Banking.MovingMoney;
@ -346,6 +349,7 @@ internal sealed class IltHubController
IltProgression => LogCat.IltProgression,
IltGear or IltCharms => LogCat.IltGear,
IltGames => LogCat.IltGames,
IltVaultedDungeons => LogCat.IltHub,
_ => LogCat.IltHub,
};
@ -456,7 +460,7 @@ internal sealed class IltHubController
{
// Quests and Pets are RynthAi's tabs: not ours to open.
if (args.Length >= 2 && IltSections.IsUniversalTabName(args[1])) return false;
_ctx.Chat("[Mini Remote] Usage: /ra hub open pets|banking|gear|charms|games|guardian|bounties [show|hide|toggle] (character: /ro character, quests: /ro)");
_ctx.Chat("[Mini Remote] Usage: /ra hub open pets|banking|gear|charms|games|vaulted|guardian|bounties [show|hide|toggle] (character: /ro character, quests: /ro)");
break;
}
OpenSection(section, args.Length > 2 ? args[2] : "toggle");
@ -494,7 +498,8 @@ internal sealed class IltHubController
break;
default:
_ctx.Chat("[Mini Remote] /ra hub [show|hide|toggle] (Mini Remote)|refresh|bank|status|features|force on|off|servers [list]|clap|confirm|cancel");
_ctx.Chat("[Mini Remote] /ra hub open pets|banking|gear|charms|games [show|hide|toggle] (Mini Remote tabs; character: /ro character, quests: /ro)");
_ctx.Chat("[Mini Remote] /ra hub open pets|banking|gear|charms|games|vaulted [show|hide|toggle] (Mini Remote tabs; character: /ro character, quests: /ro)");
_ctx.Chat("[Mini Remote] /ilt vaulted [on|off|toggle|status] (Vaulted Dungeons; Options > Navigation > Vaulted Dungeons)");
_ctx.Chat("[Mini Remote] /ra hub profile list|save <name> [shared]|load <name> /ra hub suit list|test|load [name]");
_ctx.Chat("[Mini Remote] /ra hub attr run|stop|costs|status|auto on|off|every <min>|raise <stat> <n> (Skills panel > Progression)");
_ctx.Chat("[Mini Remote] /ra quests refresh (quiet /myquests) /ra pets [show|hide] /ilt qb (the quest bonus list)");

View file

@ -4,20 +4,21 @@
// Infinite Leaftide items) that read the Hub's state.
//
// The ILT sections are tabs of RynthAi's Mini Remote (its MiniRemoteHud draws the tab bar and
// calls RenderTab through RynthILT.Hub): Banking, Gear, Charms and Games. A tab is offered only
// while the server reports its feature on. The Character tab left the Mini Remote on 2026-10-13:
// calls RenderTab through RynthILT.Hub): Gear and Games. A tab is offered only while the server
// reports its feature on. Character, Charms and Banking left the Mini Remote on 2026-10-13:
// - the session rates are RynthCore's Mini Remote "Session Stats" section (RenderRatesSection,
// surface "section:ilt-rates"), below RynthAi's one session;
// - the character overview and session are RynthOracle's Character tab ("/ro character");
// - the Leaftide feature list is RynthOracle's About tab ("Server features", from the profile);
// - the charms are RynthOracle's Character tab, the bank balances RynthInventory's Global
// Inventory "Banking" tab (both read "RynthILT.Data");
// - the "Treat this world as ILT" override and the ILT world names are RynthCore's
// Options > Diagnostics server selection only ("/ra hub force" and "/ra hub servers" remain).
// The /qb list (RynthAi's Quests tab before it moved to RynthOracle) is RynthILT's own "Quests"
// section on the rail (RenderQuestBonusSection, surface "section:ilt-questbonus").
// RenderSection draws the ILT pieces inside RynthAi's own surfaces (the Remote tab, the Pets tab,
// the Mini Remote menu). The Guardian is a RynthCore ILT panel (the bar's ILT button, next to
// Bounties), drawn through RenderGuardianPanel. Render() keeps the floating extras: the Games HUD and the confirmation
// modal. Augmentations / Enlightenment / XP planning live on the engine Skills panel. All AC
// actions go through IltHubContext.Post / Confirm so nothing here touches the game directly.
// RenderSection draws the ILT pieces inside RynthAi's own surfaces (the Remote tab, the Quests and
// Pets tabs, the Mini Remote menu). The Guardian is a RynthCore ILT panel (the bar's ILT button,
// next to Bounties), drawn through RenderGuardianPanel. Render() keeps the floating extras: the
// Games HUD and the confirmation modal. Augmentations / Enlightenment / XP planning live on the
// engine Skills panel. All AC actions go through IltHubContext.Post / Confirm so nothing here
// touches the game directly.
using System;
using System.Numerics;
using ImGuiNET;
@ -66,10 +67,9 @@ internal sealed class IltHubUi
}
switch (section)
{
case IltSection.Banking: _hub.Banking.Render(); break;
case IltSection.Gear: _hub.Gear.Render(); break;
case IltSection.Charms: _hub.CharmsTab.Render(); break;
case IltSection.Games: _hub.Games.Render(); break;
case IltSection.VaultedDungeons: _hub.VaultedDungeons.Render(); break;
default:
// A saved tab id from before the move: say where the section lives now.
if (IltSections.MovedCommand(section) is string moved)
@ -95,20 +95,8 @@ internal sealed class IltHubUi
ImGui.TextDisabled("XP planner, Augmentations and Enlightenment: Skills panel > Progression.");
}
/// <summary>
/// The quest bonus list (/qb) in RynthILT's own Mini Remote "Quests" section (surface
/// "section:ilt-questbonus"); it was a section of RynthAi's Quests tab, which moved to RynthOracle.
/// </summary>
public void RenderQuestBonusSection()
{
if (!_ctx.Options.IsIltLikeWorld)
{
RenderHeader();
RenderUnavailable();
return;
}
_hub.QuestBonus.RenderQb();
}
/// <summary>The /qb list in RynthILT's Quests section (surface "section:ilt-questbonus").</summary>
public void RenderQuestBonusSection() => _hub.QuestBonus.RenderSection();
/// <summary>
/// One of the ILT pieces RynthAi draws in its own surfaces (RynthIltHub.Section*). False when
@ -167,8 +155,8 @@ internal sealed class IltHubUi
/// <summary>A button that opens a moved section's new home (posted: the command runs on the pump).</summary>
private void MovedLink(IltSection section, string command)
{
const string home = "RynthOracle > Character";
SafeImGui.TextDisabled($"{IltSections.Label(section)} moved to {home}; the ILT session rates are in Session Stats.");
string home = command == IltSections.GlobalBankCommand ? "Global Inventory > Banking" : "RynthOracle > Character";
ImGui.TextDisabled($"{IltSections.Label(section)} moved to {home}.");
if (ImGui.SmallButton($"Open {home}##moved{(int)section}"))
_ctx.Post(() => _hub.OpenMoved(section, command));
if (ImGui.IsItemHovered()) SafeImGui.SetTooltip(command);
@ -216,7 +204,7 @@ internal sealed class IltHubUi
ImGui.TextDisabled("Bank: not loaded yet");
ImGui.SameLine();
if (ImGui.SmallButton("Load##mrbank")) _ctx.Post(() => _hub.Banking.RequestRefresh(quiet: true));
if (ImGui.IsItemHovered()) ImGui.SetTooltip("Reads your bank balances (/bank, reply hidden). The Banking tab has the details.");
if (ImGui.IsItemHovered()) ImGui.SetTooltip("Reads your bank balances (/bank, reply hidden). Global Inventory > Banking (/ginv bank) has the details.");
BankLink();
return;
}
@ -233,15 +221,14 @@ internal sealed class IltHubUi
ImGui.EndTable();
}
/// <summary>The Bank line's link to RynthILT's own Banking tab (Infinite Leaftide's bank stays RynthILT's).</summary>
/// <summary>The Bank line's link to RynthInventory's Global Inventory "Banking" tab (every character here).</summary>
private void BankLink()
{
if (!_hub.SectionAvailable(IltSection.Banking)) return;
ImGui.SameLine();
if (ImGui.SmallButton("Bank##mrbanklink"))
_ctx.Ai.MiniRemoteTab(IltSections.TabId(IltSection.Banking), "show");
if (ImGui.SmallButton("Banks##mrbanklink"))
_ctx.Post(() => _hub.OpenMoved(IltSection.Banking, IltSections.GlobalBankCommand));
if (ImGui.IsItemHovered())
ImGui.SetTooltip("The Banking tab: deposits, withdrawals and transfers (/ra hub open banking).");
SafeImGui.SetTooltip("Global Inventory > Banking (/ginv bank): deposits, withdrawals, transfers and\nevery character's bank on this server.");
}
private static void Stat(string label, string value)
@ -284,8 +271,8 @@ internal sealed class IltHubUi
/// <summary>
/// RynthILT's own Infinite Leaftide entries, for when RynthCore sends no server list (older
/// RynthCore, or its ImGui layer off): the tabs, where Character went, and the Guardian /
/// Bounties panels.
/// RynthCore, or its ImGui layer off): the tabs, where Character / Charms / Banking went, and
/// the Guardian / Bounties panels.
/// </summary>
private bool RenderLocalMenu()
{
@ -297,8 +284,10 @@ internal sealed class IltHubUi
if (ImGui.MenuItem(IltSections.Label(section) + "##mrlocal", string.Empty, false, _hub.SectionAvailable(section)))
_ctx.Ai.MiniRemoteTab(IltSections.TabId(section), "show");
}
if (ImGui.MenuItem("Character##mrlocal", IltSections.OracleCharacterCommand))
if (ImGui.MenuItem("Character and charms##mrlocal", IltSections.OracleCharacterCommand))
_ctx.Post(() => _hub.OpenMoved(IltSection.Character, IltSections.OracleCharacterCommand));
if (ImGui.MenuItem("Banking##mrlocal", IltSections.GlobalBankCommand, false, _hub.SectionAvailable(IltSection.Banking)))
_ctx.Post(() => _hub.OpenMoved(IltSection.Banking, IltSections.GlobalBankCommand));
if (ImGui.MenuItem("Guardian##mrlocal", "/rc guardian", false, _hub.SectionAvailable(IltSection.Guardian)))
_ctx.Post(() => _hub.OpenEnginePanel("guardian", "Guardian", "show"));
if (ImGui.MenuItem("Bounties##mrlocal", "/rc bounties"))

View file

@ -1,35 +1,41 @@
// IltSections.cs - The Infinite Leaftide tabs of RynthAi's Mini Remote and the Guardian panel.
// Originally SilentKelpie's ILT Hub sections (RynthAi IltHub/); moved to RynthILT 2026-10-13.
//
// Banking, Gear, Charms and Games are Mini Remote tabs: RynthAi's MiniRemoteHud draws the tab bar
// (after its Remote, Pets and Crafting tabs) and asks RynthILT for each tab's body (RynthILT.Hub
// GetTabs / RenderTab); "/ra hub open <section>" picks one, and with RynthCore's sections rail
// RynthAi lists them as "section:<tab>" views (Inventory). Guardian is a RynthCore ILT panel
// instead (the bar's ILT button, next to Bounties; "/rc guardian"), drawn by this plugin through
// RynthPluginRenderEmbed("guardian"). The Pets tab is RynthAi's (every server: summoning essences
// aren't ILT's); quests are RynthOracle's.
// Gear and Games are Mini Remote tabs: RynthAi's MiniRemoteHud draws the tab bar (after its Remote,
// Quests and Pets tabs) and asks RynthILT for each tab's body (RynthILT.Hub GetTabs / RenderTab);
// "/ra hub open <section>" picks one. Guardian is a RynthCore ILT panel instead (the bar's ILT
// button, next to Bounties; "/rc guardian"), drawn by this plugin through
// RynthPluginRenderEmbed("guardian"). The Quests and Pets tabs are RynthAi's (every server:
// /myquests and summoning essences aren't ILT's).
//
// Character was a Mini Remote tab until 2026-10-13. It moved out:
// the character overview and session -> RynthOracle's Character tab ("/ro character");
// the ILT session rates -> RynthCore's Mini Remote "Session Stats" section
// (RynthILT's own surface "section:ilt-rates");
// the force-server override -> RynthCore Options > Diagnostics only.
// Its names still parse, so old links and commands land on the new home (MovedCommand). Charms and
// Banking are Infinite Leaftide's own screens and stay RynthILT's tabs.
// Character, Charms and Banking were Mini Remote tabs until 2026-10-13. They moved out:
// Character -> RynthCore's Mini Remote "Session Stats" section (session rates; the force-server
// override lives only in RynthCore Options > Diagnostics) and RynthOracle's
// Character tab ("/ro character");
// Charms -> RynthOracle's Character tab, a list fed by "RynthILT.Data" ("/ro character");
// Banking -> RynthInventory's Global Inventory "Banking" tab, every character on this server
// ("/ginv bank").
// Their names still parse, so old links and commands land on the new home (MovedCommand).
using System;
using System.Numerics;
namespace RynthCore.Plugin.RynthILT.Hub;
/// <summary>ILT sections: the Mini Remote's ILT tabs, the one that moved out, then the Guardian panel.</summary>
/// <summary>ILT sections: the Mini Remote's ILT tabs, the sections that moved out, then the Guardian panel.</summary>
internal enum IltSection
{
/// <summary>Moved out (2026-10-13): RynthOracle's Character tab and the Session Stats section.</summary>
/// <summary>Moved out (2026-10-13): RynthOracle's Character tab.</summary>
Character,
/// <summary>Moved out (2026-10-13): RynthInventory's Global Inventory "Banking" tab.</summary>
Banking,
Gear,
Games,
/// <summary>Registry charms (acquired / status / tier / server) and the Guardian Hand.</summary>
/// <summary>
/// Vaulted Dungeons keeper (portal-recall gem + kill-client). Mini Remote tab on ILT worlds when
/// Options > Navigation > Vaulted Dungeons is enabled (RynthAi filters the tab).
/// </summary>
VaultedDungeons,
/// <summary>Moved out (2026-10-13): RynthOracle's Character tab (the charms list).</summary>
Charms,
// Keep Guardian last.
Guardian,
@ -40,21 +46,25 @@ internal static class IltSections
/// <summary>The ILT tabs, in tab-bar order (RynthAi puts them after its own tabs).</summary>
public static readonly IltSection[] Tabs =
{
IltSection.Banking, IltSection.Gear, IltSection.Charms, IltSection.Games,
IltSection.Gear, IltSection.Games, IltSection.VaultedDungeons,
};
/// <summary>The Mini Remote's own tab (the remote itself): its tab id.</summary>
public const string RemoteTab = "";
/// <summary>RynthOracle's Character tab: the character overview and this session.</summary>
/// <summary>RynthOracle's Character tab: the character, its session and the charms list.</summary>
public const string OracleCharacterCommand = "/ro character";
/// <summary>RynthInventory's Global Inventory "Banking" tab: every character's bank on this server.</summary>
public const string GlobalBankCommand = "/ginv bank";
public static string Label(IltSection s) => s switch
{
IltSection.Character => "Character",
IltSection.Banking => "Banking",
IltSection.Gear => "Gear",
IltSection.Games => "Games",
IltSection.VaultedDungeons => "Vaulted Dungeons",
IltSection.Charms => "Charms",
IltSection.Guardian => "Guardian",
_ => s.ToString(),
@ -70,13 +80,14 @@ internal static class IltSections
IltSection.Banking => "banking",
IltSection.Gear => "gear",
IltSection.Games => "games",
IltSection.VaultedDungeons => "vaulted",
IltSection.Charms => "charms",
IltSection.Guardian => "guardian",
_ => s.ToString().ToLowerInvariant(),
};
/// <summary>True for the sections drawn as Mini Remote tabs (Banking, Gear, Charms, Games).</summary>
public static bool IsTab(IltSection s) => s is IltSection.Banking or IltSection.Gear or IltSection.Charms or IltSection.Games;
/// <summary>True for the sections drawn as Mini Remote tabs (Gear, Games, Vaulted Dungeons).</summary>
public static bool IsTab(IltSection s) => s is IltSection.Gear or IltSection.Games or IltSection.VaultedDungeons;
/// <summary>
/// Where a section that moved out of the Mini Remote lives now, as the chat command that opens
@ -84,7 +95,8 @@ internal static class IltSections
/// </summary>
public static string? MovedCommand(IltSection s) => s switch
{
IltSection.Character => OracleCharacterCommand,
IltSection.Character or IltSection.Charms => OracleCharacterCommand,
IltSection.Banking => GlobalBankCommand,
_ => null,
};
@ -104,6 +116,8 @@ internal static class IltSections
case "banking": case "bank": section = IltSection.Banking; return true;
case "gear": section = IltSection.Gear; return true;
case "games": case "game": section = IltSection.Games; return true;
case "vaulted": case "vaulteddungeons": case "vaulted-dungeons":
section = IltSection.VaultedDungeons; return true;
case "charms": case "charm": section = IltSection.Charms; return true;
case "guardian": case "temple": case "riddle": section = IltSection.Guardian; return true;
default: section = IltSection.Gear; return false;
@ -116,10 +130,9 @@ internal static class IltSections
/// </summary>
public static Vector2 TabSize(IltSection section) => section switch
{
IltSection.Banking => new Vector2(560, 520),
IltSection.Gear => new Vector2(560, 520),
IltSection.Charms => new Vector2(560, 520),
IltSection.Games => new Vector2(520, 440),
IltSection.VaultedDungeons => new Vector2(360, 420),
_ => new Vector2(520, 440),
};

View file

@ -0,0 +1,708 @@
// IltVaultedDungeons.cs — Mini Remote "Vaulted Dungeons" tab (ILT / ACECustom only).
// Port of the UtilityBelt VaultedDungeons.lua script (owner 2026-09-27 / 2026-10-03):
// keeps the character in one Vaulted Dungeon via a tied Portal Recall Gem, and optionally
// /rc quit after N minutes without a real kill ("You've banked N Luminance." system line).
//
// Shown only on ILT-like worlds, and only when Options > Navigation > Vaulted Dungeons is on
// (RynthAi filters the tab; this module still runs whenever the character is on ILT so a
// saved Active state keeps working after a relog even if the tab is hidden).
using System;
using System.Collections.Generic;
using System.IO;
using System.Numerics;
using System.Text.Json;
using System.Text.Json.Serialization;
using System.Text.RegularExpressions;
using ImGuiNET;
using RynthCore.Plugin.Shared;
using RynthCore.PluginSdk;
namespace RynthCore.Plugin.RynthILT.Hub;
/// <summary>One known Vaulted Dungeon (landblock high word; the client does not see the layer).</summary>
internal readonly record struct VaultedDungeon(string Name, uint Landblock);
internal sealed class IltVaultedDungeons : IIltFeature
{
// Keep order stable: saved picks are by 1-based index into this list.
private static readonly VaultedDungeon[] Dungeons =
{
new("Tyrant's Quarry", 0x01F7),
new("Tusgian Barracks", 0x8C03),
new("Wailing Cells", 0x01C2),
new("Chamber of Idols", 0x5649),
new("Fiun Redoubt", 0x0178), // added 2026-09-27
new("Tumerok Tunnels", 0x5754), // added 2026-10-03
};
private static readonly string[] GemNames =
{
"Primary Portal Recall Gem",
"Secondary Portal Recall Gem",
};
private static readonly (string Name, float Value)[] Powers =
{
("Fast", 0f), ("Medium", 0.5f), ("Full Power", 1f),
};
private static readonly int[] QuitPresets = { 1, 2, 5, 10, 15, 30 };
private const long FirstRecallAfterMs = 1000;
private const long RecallAfterMs = 5000;
private const int QuitMin = 1, QuitMax = 30;
private const long WarnEveryMs = 30_000;
private const string SettingsFileName = "settings.json";
private const string SettingsBadFileName = "settings.unreadable.json";
private const string CmdMetaOff = "/vt opt set EnableMeta False";
private const string CmdNavOff = "/vt opt set EnableNav False";
private const string CmdRepeatOn = "/ub playeroption AutoRepeatAttack on";
private const string CmdAttackBar = "/vt setattackbar ";
private const string CmdQuit = "/rc quit";
// System line only (no player sender): "You've banked 1,234 Luminance."
private static readonly Regex KillLine = new(
@"^You've banked [\d,]+ Luminance\.\s*$",
RegexOptions.Compiled | RegexOptions.CultureInvariant);
private readonly IltHubContext _ctx;
private readonly object _gate = new();
private Cfg _cfg = new();
private bool _loaded;
private bool _dirty;
private string? _lastGoodJson;
// Runtime (pump thread).
private long _outSinceMs;
private long _lastRecallMs;
private long _clockStartMs;
private long _realKillMs;
private bool _wasInside;
private bool _quitSent;
private long _lastWarnMs;
private string _state = "paused"; // paused / setup / in / out / portal / nogem
private long? _quitLeftMs;
private bool? _presentBefore;
private long _idleSecs;
private long _inSinceMs;
private long _portalSinceMs;
private int _kills;
private long _dungeonSecs;
private long _lastTickMs;
// Snapshot for the render thread (copied under _gate).
private Snapshot _snap = Snapshot.Empty;
public IltVaultedDungeons(IltHubContext ctx) => _ctx = ctx;
// ── Persistence ─────────────────────────────────────────────────────────
private string SettingsDir => Path.Combine(_ctx.Store.CharFolder, "VaultedDungeons");
private string SettingsPath => Path.Combine(SettingsDir, SettingsFileName);
private void EnsureLoaded()
{
if (_loaded) return;
_loaded = true;
try
{
string path = SettingsPath;
if (!File.Exists(path)) return;
string text = File.ReadAllText(path);
var cfg = JsonSerializer.Deserialize<Cfg>(text, JsonOpts);
if (cfg == null) return;
_cfg = Sanitize(cfg);
_lastGoodJson = text;
}
catch (Exception ex)
{
RynthLog.Write(LogCat.IltHub, $"Vaulted Dungeons: settings load failed: {ex.Message}");
}
}
private void SaveIfDirty()
{
if (!_dirty) return;
_dirty = false;
try
{
Directory.CreateDirectory(SettingsDir);
string path = SettingsPath;
// Corrupt / mid-write: keep a copy, then rewrite from last good + current cfg.
if (File.Exists(path))
{
try
{
string existing = File.ReadAllText(path);
if (_lastGoodJson == null)
JsonSerializer.Deserialize<Cfg>(existing, JsonOpts); // throws if bad
}
catch
{
try
{
File.Copy(path, Path.Combine(SettingsDir, SettingsBadFileName), overwrite: true);
_ctx.Chat("[Vaulted Dungeons] settings.json would not read — kept a copy as "
+ SettingsBadFileName + ".");
}
catch { /* best effort */ }
}
}
string json = JsonSerializer.Serialize(_cfg, JsonOpts);
File.WriteAllText(path, json);
_lastGoodJson = json;
}
catch (Exception ex)
{
RynthLog.Write(LogCat.IltHub, $"Vaulted Dungeons: settings save failed: {ex.Message}");
}
}
private static readonly JsonSerializerOptions JsonOpts = new()
{
WriteIndented = true,
PropertyNamingPolicy = JsonNamingPolicy.CamelCase,
DefaultIgnoreCondition = JsonIgnoreCondition.WhenWritingNull,
};
private static Cfg Sanitize(Cfg c)
{
c.Dungeon = ClampInt(c.Dungeon, 0, Dungeons.Length, 0);
c.Gem = ClampInt(c.Gem, 0, GemNames.Length, 0);
c.QuitMinutes = ClampInt(c.QuitMinutes, QuitMin, QuitMax, 2);
c.AttackPower = Powers[PowerIndex(c.AttackPower)].Value;
return c;
}
private static int ClampInt(int v, int lo, int hi, int def)
=> v < lo || v > hi ? def : v;
private static int PowerIndex(float v)
{
int best = 0;
float bestGap = float.MaxValue;
for (int i = 0; i < Powers.Length; i++)
{
float gap = Math.Abs(Powers[i].Value - v);
if (gap < bestGap) { best = i; bestGap = gap; }
}
return best;
}
private static string PowerText(float p)
{
string t = p.ToString("0.##", System.Globalization.CultureInfo.InvariantCulture);
return t;
}
// ── IIltFeature ─────────────────────────────────────────────────────────
public void Tick(long nowMs)
{
EnsureLoaded();
SaveIfDirty();
// Time in dungeon (kills/hour): only while last state was "in".
if (_lastTickMs > 0 && _state == "in")
_dungeonSecs += Math.Max(0, (nowMs - _lastTickMs) / 1000);
_lastTickMs = nowMs;
if (!_ctx.Host.HasGetPlayerPose || !_ctx.Host.TryGetPlayerPose(out uint cell, out _, out _, out _, out _, out _, out _, out _) || cell == 0)
{
Publish();
return;
}
uint landblock = cell >> 16;
bool portaling = _ctx.Host.HasIsPortaling && _ctx.Host.IsPortaling();
VaultedDungeon? dungeon = _cfg.Dungeon > 0 && _cfg.Dungeon <= Dungeons.Length
? Dungeons[_cfg.Dungeon - 1]
: null;
// Present check (for Auto Start / arrive actions) even while Off.
if (dungeon == null)
_presentBefore = null;
else if (!portaling)
{
bool here = landblock == dungeon.Value.Landblock;
if (here && _presentBefore != true) OnArrive(dungeon.Value, nowMs);
_presentBefore = here;
}
_quitLeftMs = null;
if (!_cfg.Active)
{
_state = "paused";
_outSinceMs = 0;
Publish();
return;
}
string? gemName = _cfg.Gem > 0 && _cfg.Gem <= GemNames.Length ? GemNames[_cfg.Gem - 1] : null;
if (dungeon == null || gemName == null)
{
_state = "setup";
_wasInside = false;
Warn(nowMs, dungeon == null
? "Pick a dungeon in the Vaulted Dungeons tab."
: "Pick a recall gem in the Vaulted Dungeons tab.");
Publish();
return;
}
bool inside = landblock == dungeon.Value.Landblock;
if (inside && !portaling)
{
if (!_wasInside)
{
_clockStartMs = nowMs;
_quitSent = false;
_inSinceMs = nowMs;
}
_wasInside = true;
_outSinceMs = 0;
_portalSinceMs = 0;
_state = "in";
_idleSecs = Math.Max(0, (nowMs - _clockStartMs) / 1000);
if (_cfg.Quit)
{
long quitAfterMs = _cfg.QuitMinutes * 60_000L;
_quitLeftMs = Math.Max(0, quitAfterMs - (nowMs - _clockStartMs));
if (nowMs - _clockStartMs >= quitAfterMs && !_quitSent)
{
_quitSent = true;
_ctx.Chat($"[Vaulted Dungeons] No kill in {_cfg.QuitMinutes} minute"
+ (_cfg.QuitMinutes == 1 ? "" : "s") + " — quitting.");
Invoke(CmdQuit);
}
}
Publish();
return;
}
_wasInside = false;
if (portaling)
{
_state = "portal";
_outSinceMs = 0;
if (_portalSinceMs == 0) _portalSinceMs = nowMs;
Publish();
return;
}
_portalSinceMs = 0;
if (_outSinceMs == 0) _outSinceMs = nowMs;
_state = "out";
bool tried = _lastRecallMs >= _outSinceMs;
bool due = (!tried && nowMs - _outSinceMs >= FirstRecallAfterMs)
|| (tried && nowMs - _lastRecallMs >= RecallAfterMs);
if (due)
{
var gem = _ctx.Inventory.FindByName(n => n.Equals(gemName, StringComparison.OrdinalIgnoreCase));
if (gem != null)
{
_lastRecallMs = nowMs;
_ctx.Chat($"[Vaulted Dungeons] Not in {dungeon.Value.Name} — using the {gemName}.");
_ctx.Inventory.Use(gem);
}
else
{
_state = "nogem";
Warn(nowMs, $"No {gemName} in your pack.");
}
}
Publish();
}
public bool OnChat(string text)
{
if (string.IsNullOrEmpty(text) || !KillLine.IsMatch(text.TrimEnd('\r', '\n'))) return false;
long now = IltHubContext.NowMs;
_clockStartMs = now;
_quitSent = false;
_realKillMs = now;
if (_state == "in") _kills++;
Publish();
return false; // never eat the luminance line
}
public void OnLogout()
{
SaveIfDirty();
_wasInside = false;
_outSinceMs = 0;
_state = "paused";
Publish();
}
// ── Arrive / commands ───────────────────────────────────────────────────
private void OnArrive(VaultedDungeon dungeon, long nowMs)
{
if (_cfg.AutoStart && !_cfg.Active)
{
_cfg.Active = true;
_outSinceMs = 0;
_dirty = true;
_ctx.Chat($"[Vaulted Dungeons] Arrived in {dungeon.Name} — switched On (Auto Start On Arrival).");
}
if (_cfg.DisableMeta) Invoke(CmdMetaOff);
if (_cfg.DisableNav) Invoke(CmdNavOff);
if (_cfg.RepeatAttack) Invoke(CmdRepeatOn);
if (_cfg.SetPower) Invoke(CmdAttackBar + PowerText(_cfg.AttackPower));
}
private void Invoke(string cmd)
{
if (_ctx.Host.HasInvokeChatParser) _ctx.Host.InvokeChatParser(cmd);
}
private void Warn(long nowMs, string text)
{
if (nowMs - _lastWarnMs < WarnEveryMs) return;
_lastWarnMs = nowMs;
_ctx.Chat("[Vaulted Dungeons] " + text);
}
/// <summary>Pump-thread: /ilt vaulted [on|off|toggle|status].</summary>
public bool HandleCommand(string[] args)
{
EnsureLoaded();
string sub = args.Length > 0 ? args[0].ToLowerInvariant() : "status";
switch (sub)
{
case "on":
case "start":
SetActive(true);
_ctx.Chat("[Vaulted Dungeons] On.");
return true;
case "off":
case "stop":
SetActive(false);
_ctx.Chat("[Vaulted Dungeons] Off.");
return true;
case "toggle":
SetActive(!_cfg.Active);
_ctx.Chat("[Vaulted Dungeons] " + (_cfg.Active ? "On." : "Off."));
return true;
default:
string d = _cfg.Dungeon > 0 && _cfg.Dungeon <= Dungeons.Length
? Dungeons[_cfg.Dungeon - 1].Name : "(none)";
string g = _cfg.Gem > 0 && _cfg.Gem <= GemNames.Length
? GemNames[_cfg.Gem - 1] : "(none)";
_ctx.Chat($"[Vaulted Dungeons] {(_cfg.Active ? "On" : "Off")} — dungeon={d}, gem={g}, "
+ $"kill-client={(_cfg.Quit ? $"{_cfg.QuitMinutes}m" : "off")}, state={_state}.");
_ctx.Chat("[Vaulted Dungeons] /ilt vaulted [on|off|toggle|status] (Mini Remote tab; Options > Navigation > Vaulted Dungeons)");
return true;
}
}
private void SetActive(bool value)
{
_cfg.Active = value;
_outSinceMs = 0;
_dirty = true;
if (!value)
{
_clockStartMs = IltHubContext.NowMs;
_quitSent = false;
_wasInside = false;
_quitLeftMs = null;
_state = "paused";
}
Publish();
}
// ── Render snapshot ─────────────────────────────────────────────────────
private void Publish()
{
lock (_gate)
{
_snap = new Snapshot(
_cfg.Active, _cfg.Dungeon, _cfg.Gem, _cfg.Quit, _cfg.QuitMinutes,
_cfg.ShowInDungeon, _cfg.AutoStart, _cfg.DisableMeta, _cfg.DisableNav,
_cfg.RepeatAttack, _cfg.SetPower, _cfg.AttackPower,
_state, _quitLeftMs, _idleSecs, _inSinceMs, _outSinceMs, _portalSinceMs,
_realKillMs, _kills, _dungeonSecs, IltHubContext.NowMs);
}
}
private Snapshot Take()
{
lock (_gate) return _snap;
}
// ── UI (render thread) ──────────────────────────────────────────────────
private bool _showAdvanced;
// Pending edits from the UI, applied on the next pump tick via Post.
private void PostEdit(Action<Cfg> edit)
{
_ctx.Post(() =>
{
EnsureLoaded();
edit(_cfg);
_dirty = true;
Publish();
});
}
public void Render()
{
// Settings load on the pump (Tick); the window only reads the snapshot.
Snapshot s = Take();
Vector4 colLabel = new(0.53f, 0.53f, 0.53f, 1f);
Vector4 colValue = new(1f, 1f, 1f, 1f);
Vector4 colGreen = new(0.27f, 0.80f, 0.40f, 1f);
Vector4 colAmber = new(0.95f, 0.65f, 0.20f, 1f);
Vector4 colRed = new(0.90f, 0.30f, 0.30f, 1f);
Vector4 colPurple = new(0.72f, 0.52f, 0.95f, 1f);
Vector4 colTitleRed = new(0.85f, 0.25f, 0.25f, 1f);
// Title row: Vaulted (red) Dungeons (white) + On/Off + Advanced.
ImGui.TextColored(colTitleRed, "Vaulted");
ImGui.SameLine(0, ImGui.CalcTextSize(" ").X);
ImGui.TextColored(colValue, "Dungeons");
ImGui.SameLine(0, 16);
Vector4 pill = s.Active ? colGreen : new(0.85f, 0.10f, 0.10f, 1f);
ImGui.PushStyleColor(ImGuiCol.Button, pill);
ImGui.PushStyleColor(ImGuiCol.ButtonHovered, pill);
ImGui.PushStyleColor(ImGuiCol.ButtonActive, pill);
ImGui.PushStyleColor(ImGuiCol.Text, new Vector4(0.05f, 0.05f, 0.05f, 1f));
if (ImGui.SmallButton((s.Active ? " On " : " Off ") + "##vdactive"))
_ctx.Post(() => SetActive(!s.Active));
ImGui.PopStyleColor(4);
if (ImGui.IsItemHovered())
ImGui.SetTooltip(s.Active
? "On: keeping this character in the chosen dungeon.\nClick: turn off."
: "Off: doing nothing.\nClick: turn on.");
ImGui.SameLine();
if (ImGui.SmallButton("Advanced##vdoptions")) _showAdvanced = !_showAdvanced;
ImGui.Separator();
float labelW = ImGui.CalcTextSize("Recall Gem").X + 12;
void Label(string text)
{
ImGui.AlignTextToFramePadding();
ImGui.TextColored(colLabel, text);
ImGui.SameLine(labelW);
}
// Status
var (statusWord, statusCol) = s.State switch
{
"in" => ("In Dungeon", colGreen),
"out" => ("Recalling", colAmber),
"portal" => ("Portal Space", colPurple),
"setup" => ("Setup Needed", colAmber),
"nogem" => ("No Gem", colRed),
_ => ("Not Running", colRed),
};
long since = s.State == "in" ? s.InSinceMs
: s.State == "out" ? s.OutSinceMs
: s.State == "portal" ? s.PortalSinceMs : 0;
string statusText = statusWord;
if (since > 0)
{
long secs = Math.Max(0, (s.NowMs - since) / 1000);
long h = secs / 3600, m = (secs / 60) % 60, sec = secs % 60;
statusText += h > 0 ? $" ({h}:{m:D2}:{sec:D2})" : $" ({m}:{sec:D2})";
}
Label("Status");
ImGui.TextColored(statusCol, statusText);
// Dungeon combo (0 = pick, 1..N = Dungeons[i-1])
Label("Dungeon");
string[] dungeonChoices = BuildDungeonChoices();
int dungeonIdx = s.Dungeon;
ImGui.SetNextItemWidth(260);
if (ImGui.Combo("##vddungeon", ref dungeonIdx, dungeonChoices, dungeonChoices.Length))
PostEdit(c => { c.Dungeon = dungeonIdx; });
Label("Recall Gem");
string[] gemChoices = { "Pick a gem", GemNames[0], GemNames[1] };
int gemIdx = s.Gem;
ImGui.SetNextItemWidth(260);
if (ImGui.Combo("##vdgem", ref gemIdx, gemChoices, gemChoices.Length))
PostEdit(c => { c.Gem = gemIdx; });
if (ImGui.IsItemHovered())
ImGui.SetTooltip("Tie this gem to the dungeon's portal first.");
Label("Last Kill");
if (s.State == "in" && s.RealKillMs > 0)
ImGui.TextUnformatted($"{(s.NowMs - s.RealKillMs) / 1000} s ago");
else
ImGui.TextUnformatted("-");
Label("Session");
string perHour = s.DungeonSecs < 60 ? "-"
: Commas((long)(s.Kills * 3600.0 / Math.Max(1, s.DungeonSecs)));
ImGui.TextUnformatted($"{Commas(s.Kills)} kills ({perHour} Per Hour)");
if (s.QuitLeftMs is long left && s.QuitMinutes > 0)
{
float frac = (float)(left / (double)(s.QuitMinutes * 60_000L));
string barLabel = $"Kill Client ({left / 60_000}:{(left / 1000) % 60:D2})";
ImGui.ProgressBar(Math.Clamp(frac, 0f, 1f), new Vector2(-1, ImGui.GetTextLineHeight()), barLabel);
}
if (_showAdvanced)
{
ImGui.Separator();
ImGui.TextColored(colValue, "Advanced");
bool quit = s.Quit;
if (ImGui.Checkbox("Kill Client##vdquit", ref quit))
{
bool on = quit;
_ctx.Post(() =>
{
EnsureLoaded();
_cfg.Quit = on;
_cfg.QuitMinutes = ClampInt(_cfg.QuitMinutes, QuitMin, QuitMax, 2);
_clockStartMs = IltHubContext.NowMs;
_quitSent = false;
_dirty = true;
Publish();
});
}
if (ImGui.IsItemHovered())
ImGui.SetTooltip("No kill for the set minutes in the dungeon → /rc quit closes the client.\n"
+ "A kill is the server's \"You've banked N Luminance.\" line.");
ImGui.SameLine();
ImGui.TextColored(colLabel, "after");
ImGui.SameLine();
if (ImGui.SmallButton($"{s.QuitMinutes} minute{(s.QuitMinutes == 1 ? "" : "s")}##vdmincycle"))
_ctx.Post(() =>
{
EnsureLoaded();
_cfg.QuitMinutes = StepPreset(_cfg.QuitMinutes, +1);
_clockStartMs = IltHubContext.NowMs;
_quitSent = false;
_dirty = true;
Publish();
});
if (ImGui.IsItemClicked(ImGuiMouseButton.Right))
_ctx.Post(() =>
{
EnsureLoaded();
_cfg.QuitMinutes = StepPreset(_cfg.QuitMinutes, -1);
_clockStartMs = IltHubContext.NowMs;
_quitSent = false;
_dirty = true;
Publish();
});
if (ImGui.IsItemHovered())
ImGui.SetTooltip("Minutes with no kill before Kill Client quits.\nClick: longer. Right-click: shorter. (1, 2, 5, 10, 15, 30)");
BoolRow("Auto Start On Arrival##vdautostart", s.AutoStart,
v => PostEdit(c => c.AutoStart = v),
"Switch On by itself when you arrive in the chosen dungeon (logging in there counts).");
BoolRow("Disable Meta##vdnometa", s.DisableMeta,
v => PostEdit(c => c.DisableMeta = v),
"On arriving: " + CmdMetaOff);
BoolRow("Disable Nav##vdnonav", s.DisableNav,
v => PostEdit(c => c.DisableNav = v),
"On arriving: " + CmdNavOff);
BoolRow("Repeat Attacks On##vdrepeat", s.RepeatAttack,
v => PostEdit(c => c.RepeatAttack = v),
"On arriving: " + CmdRepeatOn);
BoolRow("Set Attack Power##vdpower", s.SetPower,
v => PostEdit(c => c.SetPower = v),
"On arriving: " + CmdAttackBar + PowerText(s.AttackPower));
ImGui.SameLine();
int pi = PowerIndex(s.AttackPower);
if (ImGui.SmallButton(Powers[pi].Name + "##vdpowercycle"))
PostEdit(c => c.AttackPower = Powers[(pi + 1) % Powers.Length].Value);
if (ImGui.IsItemClicked(ImGuiMouseButton.Right))
PostEdit(c => c.AttackPower = Powers[(pi - 1 + Powers.Length) % Powers.Length].Value);
if (ImGui.IsItemHovered())
ImGui.SetTooltip("Fast (0), Medium (0.5) or Full Power (1).\nClick: next. Right-click: back.");
}
ImGui.Spacing();
ImGui.TextDisabled("Note: the client sees the landblock, not the layer — standing in the retail copy also counts as \"in it\".");
ImGui.TextDisabled("/ilt vaulted [on|off|toggle|status]");
}
private static void BoolRow(string id, bool value, Action<bool> set, string tip)
{
bool v = value;
if (ImGui.Checkbox(id, ref v)) set(v);
if (ImGui.IsItemHovered()) ImGui.SetTooltip(tip);
}
private static string[] BuildDungeonChoices()
{
var list = new string[Dungeons.Length + 1];
list[0] = "Pick a dungeon";
for (int i = 0; i < Dungeons.Length; i++) list[i + 1] = Dungeons[i].Name;
return list;
}
private static int StepPreset(int current, int dir)
{
if (dir > 0)
{
foreach (int m in QuitPresets) if (m > current) return m;
return QuitPresets[0];
}
for (int i = QuitPresets.Length - 1; i >= 0; i--)
if (QuitPresets[i] < current) return QuitPresets[i];
return QuitPresets[^1];
}
private static string Commas(long n)
{
string s = Math.Abs(n).ToString();
var chars = new List<char>();
for (int i = 0; i < s.Length; i++)
{
if (i > 0 && (s.Length - i) % 3 == 0) chars.Add(',');
chars.Add(s[i]);
}
return (n < 0 ? "-" : "") + new string(chars.ToArray());
}
// ── Config / snapshot types ─────────────────────────────────────────────
private sealed class Cfg
{
public bool Active { get; set; }
/// <summary>0 = none, 1..N = Dungeons index.</summary>
public int Dungeon { get; set; }
/// <summary>0 = none, 1 = primary, 2 = secondary.</summary>
public int Gem { get; set; }
public bool Quit { get; set; }
public int QuitMinutes { get; set; } = 2;
public bool ShowInDungeon { get; set; }
public bool AutoStart { get; set; }
public bool DisableMeta { get; set; }
public bool DisableNav { get; set; }
public bool RepeatAttack { get; set; }
public bool SetPower { get; set; }
public float AttackPower { get; set; }
}
private readonly record struct Snapshot(
bool Active, int Dungeon, int Gem, bool Quit, int QuitMinutes,
bool ShowInDungeon, bool AutoStart, bool DisableMeta, bool DisableNav,
bool RepeatAttack, bool SetPower, float AttackPower,
string State, long? QuitLeftMs, long IdleSecs, long InSinceMs, long OutSinceMs, long PortalSinceMs,
long RealKillMs, int Kills, long DungeonSecs, long NowMs)
{
public static Snapshot Empty => new(false, 0, 0, false, 2,
false, false, false, false, false, false, 0f,
"paused", null, 0, 0, 0, 0, 0, 0, 0, 0);
}
}

View file

@ -55,6 +55,15 @@ internal sealed class IltSettingsModel
if (view != null) Volatile.Write(ref _engine, view);
}
/// <summary>
/// Older "servermenu" text push (RynthPluginApplyRemoteCommand). No-op here: the verdict now
/// comes from <see cref="ApplyServerState"/> / IltEngineVerdict. Kept so ApplyRemoteCommand compiles.
/// </summary>
public void ApplyEngine(string? payload) { _ = payload; }
/// <summary>Older "iltfeatures" text push. No-op; features come from the Hub's PublishFeatures.</summary>
public void ApplyFeatures(string? payload) { _ = payload; }
/// <summary>The Hub's own feature read (plugin tick); null clears it. Any thread.</summary>
public void PublishFeatures(IltFeatureView? view) => Volatile.Write(ref _features, view);

View file

@ -8,13 +8,14 @@
Bounty/ the Bounties window's tracker (ported from SilentKelpie's rynth/RynthSuite PR #11).
Hub/ the ILT Hub (SilentKelpie's): the Mini Remote's ILT tabs (Character, Banking, Gear,
Charms, Games), the Guardian, the progression planners and the attribute raiser,
server feature detection, the Rings inscription chain (Gear tab). Moved out of
RynthAi 2026-10-13: RynthAi's Mini Remote hosts the tabs through RynthILT.Hub, and
RynthILT borrows from RynthAi through RynthAi.Hub (Plugins/Shared/RynthIltHubApi.cs,
RynthAiHubApi.cs).
server feature detection. Moved out of RynthAi 2026-10-13: RynthAi's Mini Remote
hosts the tabs through RynthILT.Hub, and RynthILT borrows from RynthAi through
RynthAi.Hub (Plugins/Shared/RynthIltHubApi.cs, RynthAiHubApi.cs).
IltSettingsView/ a copy of the ILT settings (RynthCore's verdict, this character's override, the
ILT world names, the Hub's feature read) in its own window ("/ilt settings").
IltFellowship/ ILT's /fship commands as buttons ("/ilt fellow").
ILT world names, the Hub's feature read), in RynthCore's Mini Remote and its
own window ("/ilt settings").
IltFellowship/ ILT's /fship commands as buttons (RynthCore's Fellowship section, "/ilt fellow",
and RynthAi's Fellowship view).
-->
<PropertyGroup>
<TargetFramework>net10.0-windows</TargetFramework>
@ -33,17 +34,16 @@
<Platforms>x86</Platforms>
<!-- Plugin manifest (embedded in the DLL; Plugins\Directory.Build.targets). minEngineApi is the
highest API use NOT behind a Has*/version check. Nothing above the v66 baseline: every
newer call (plugin interfaces v68, live object ids v69, vendor trade v67, confirmation
answers v85, the server list v86, ...) is behind its Has* check, as it was in RynthAi. -->
newer call (plugin interfaces v68, live object ids v69, vendor trade v67, the chat parser,
world names and the plugin-command broker) is behind its Has* check, as it was in RynthAi. -->
<RynthPluginMinEngineApi>66</RynthPluginMinEngineApi>
<!-- RynthILT is ILT's server plugin: RynthCore loads it only for clients connecting to ILT, or late
when the world announces an ILT name (SilentKelpie's server plugins). Same lists as RynthCore's
IltDetect defaults. -->
<RynthPluginDescription>Infinite Leaftide (ACECustom) features: the ILT Hub (the Mini Remote's ILT tabs: banking, gear, charms, games), the Guardian, bounties, progression, the attribute raiser, the ILT settings and the /fship fellowship commands.</RynthPluginDescription>
<!-- RynthILT is ILT's server plugin: RynthCore loads it only for clients connecting to ILT (or when no
installed server plugin claims the host). Same lists as RynthCore's IltDetect defaults. -->
<RynthPluginServerId>ilt</RynthPluginServerId>
<RynthPluginServerName>Infinite Leaftide</RynthPluginServerName>
<RynthPluginServerHosts>infiniteleaftide.online</RynthPluginServerHosts>
<RynthPluginServerWorldNames>InfiniteLeaftide|*Leaftide*</RynthPluginServerWorldNames>
<RynthPluginDescription>Infinite Leaftide (ACECustom) features: the ILT Hub (the Mini Remote's ILT tabs: banking, gear, charms, games), the Guardian, bounties, progression, the attribute raiser, the ring inscription chain, the ILT settings and the /fship fellowship commands.</RynthPluginDescription>
</PropertyGroup>
<ItemGroup>
@ -55,9 +55,9 @@
<ItemGroup>
<!-- The two interfaces between RynthILT and RynthAi (linked into both plugins). -->
<Compile Include="..\Shared\RynthIltHubApi.cs" Link="Shared\RynthIltHubApi.cs" />
<Compile Include="..\Shared\RynthAiHubApi.cs" Link="Shared\RynthAiHubApi.cs" />
<!-- "RynthILT.Data": the charms list and bank balances for other plugins (DataInterface.cs). -->
<Compile Include="..\Shared\RynthIltServerApi.cs" Link="Shared\RynthIltServerApi.cs" />
<Compile Include="..\Shared\RynthIltDataApi.cs" Link="Shared\RynthIltDataApi.cs" />
<Compile Include="..\Shared\RynthAiHubApi.cs" Link="Shared\RynthAiHubApi.cs" />
<!-- RynthCore's server list (API v86): the ILT verdict the Hub follows (IltSettingsView/). -->
<Compile Include="..\Shared\EngineServerState.cs" Link="Shared\EngineServerState.cs" />
<!-- "RynthServer.Profile": ILT's settings and tinkering salvage (Hub/IltSalvage.cs) for other
@ -67,7 +67,7 @@
<Compile Include="..\Shared\ServerPack\ServerPackProfile.cs" Link="ServerPack\ServerPackProfile.cs" />
<!-- ImGui.NET bound to the engine's cimgui (the tabs draw inside RynthAi's Mini Remote). -->
<Compile Include="..\Shared\ImGuiNativeBinding.cs" Link="Shared\ImGuiNativeBinding.cs" />
<!-- ImGui text calls for non-literal text ('%' escaped; RynthAi links the same file). -->
<!-- ImGui text calls are printf formats: dynamic text (names, chat, server lines) goes through SafeImGui. -->
<Compile Include="..\Shared\SafeImGui.cs" Link="Shared\SafeImGui.cs" />
<!-- Install-folder resolver (the ILT Hub files left in the RynthAi folder). -->
<Compile Include="..\Shared\RynthInstallPaths.cs" Link="Shared\RynthInstallPaths.cs" />
@ -78,7 +78,7 @@
<Compile Include="..\Shared\DataWriteGuard.cs" Link="Shared\DataWriteGuard.cs" />
<!-- AcObjectClass (the item classes the gear tools check). -->
<Compile Include="..\..\Shared\RynthCore.LootSdk\AcGameEnums.cs" Link="Shared\AcGameEnums.cs" />
<!-- ILT's /fship commands (IltFellowship/): the shared command list format and its button panel. -->
<!-- ILT's /fship commands: sent to RynthAi's Fellowship view, and drawn in RynthCore's Fellowship section. -->
<Compile Include="..\Shared\ServerCommandShare.cs" Link="Shared\ServerCommandShare.cs" />
<Compile Include="..\Shared\ServerCommandPanel.cs" Link="Shared\ServerCommandPanel.cs" />
</ItemGroup>

View file

@ -59,6 +59,9 @@ public sealed class RynthILTPlugin : RynthPluginBase
/// <summary>The ILT session extras' surface in RynthCore's Mini Remote "Session Stats" section.</summary>
internal const string RatesSurface = "section:ilt-rates";
/// <summary>The /qb list surface (RynthOracle Quests / ILT quest-bonus embed).</summary>
internal const string QuestBonusSurface = "section:ilt-questbonus";
/// <summary>The fellowship commands' surface in RynthCore's Fellowship section.</summary>
internal const string FellowshipSurface = "section:ilt-fellowship";
@ -381,6 +384,7 @@ public sealed class RynthILTPlugin : RynthPluginBase
SettingsSurface => _settingsUi.RenderBody,
FellowshipSurface => _fellowshipUi.RenderBody,
RatesSurface => RenderRatesSurface,
QuestBonusSurface => RenderQuestBonusSurface,
_ => null,
};
if (body == null) return false;
@ -411,6 +415,14 @@ public sealed class RynthILTPlugin : RynthPluginBase
hub.RenderRatesSection();
}
/// <summary>The /qb list (render thread), or a line saying the Hub is not ready yet.</summary>
private void RenderQuestBonusSurface()
{
IltHubController? hub = _hub;
if (hub == null) { ImGui.TextDisabled("ILT quest bonus starts once RynthILT's Hub is ready."); return; }
hub.RenderQuestBonusSection();
}
/// <summary>
/// RynthPluginGetSectionsJson: the ILT session extras in RynthCore's Session Stats section
/// (the "char" id) and the fellowship commands in its Fellowship section, Infinite Leaftide
@ -625,6 +637,14 @@ public sealed class RynthILTPlugin : RynthPluginBase
case "hub":
case "rates":
break;
case "vaulted":
case "vaulteddungeons":
{
// "/ilt vaulted [on|off|toggle|status]": the Vaulted Dungeons keeper.
if (_hub == null) { ChatLine("[RynthILT] ILT features not ready (log in first)."); return; }
_hub.VaultedDungeons.HandleCommand(args);
return;
}
case "settings":
case "options":
{
@ -645,6 +665,7 @@ public sealed class RynthILTPlugin : RynthPluginBase
case "help":
ChatLine("[RynthILT] /ilt hub ... (the Mini Remote's ILT tabs; same as /ra hub ...), /ilt guardian ..., /ilt servers [list|<names>|default],");
ChatLine("[RynthILT] /ilt bounty [list|refresh] - the tracked ACECustom bounties (the Bounties window: the ILT button on the RynthCore bar, or /rc bounties),");
ChatLine("[RynthILT] /ilt vaulted [on|off|toggle|status] - Vaulted Dungeons (Mini Remote tab; enable in Options > Navigation),");
ChatLine("[RynthILT] /ilt settings [show|hide|toggle] - the ILT settings: the world verdict, the ILT world names and a feature summary (force a server: RynthCore Options > Diagnostics; all features: RynthOracle > About),");
ChatLine("[RynthILT] /ilt fellow [show|hide|toggle] - ILT's /fship commands as buttons (also in the Mini Remote's Fellowship section and RynthOracle's Fellowship tab),");
ChatLine("[RynthILT] /ilt trace <category|all|list> [on|off], /ilt debug [on|off].");