Repository navigation
Conversation
Add a ui.auto_confirm_alliance_contribution TOML setting (default false) that skips the level-60 warning popup shown before contributing to a max-level alliance. The warning's MessageBox callback (AllianceContributionViewController.<>c__DisplayClass72_0.<RequestAction>b__0) only proceeds on MessageBox.ButtonResult.Yes (= 3, verified against the client disassembly), so the existing shared MessageBox.Show detours now invoke it with Yes instead of showing the popup. The detours are consolidated behind the existing install gate, which now triggers on either the Forbidden Tech or the new setting. Cherry-picked from stfc-mod-personal (3f202ff). Adapted to this tree's design: the MessageBox hooks stay installed unconditionally via the [patches] installForbiddenTechConfirmationHooks toggle with the feature setting checked inside the hook, and the patch entry label is renamed to MessageBoxConfirmations since the detours now own two auto-confirm behaviors.
netniV
approved these changes
Oct 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new
ui.auto_confirm_alliance_contributionsetting (defaultfalse) thatskips the confirmation popup shown when contributing to an alliance that has already
reached level 60. When enabled, the warning is answered with "Yes" automatically and
the contribution goes through without interruption.
How it works
The level-60 warning is shown through the game's shared
MessageBoxAPI. Its callback(
AllianceContributionViewController.<>c__DisplayClass72_0.<RequestAction>b__0) onlyproceeds on
MessageBox.ButtonResult.Yes(value3, verified against the clientdisassembly). Rather than installing new hooks, the existing shared
MessageBox.Show/MessageBox.ShowWithCallbackdetours now recognize this callback(via
IsAllianceContributionMaxLevelWarning()) and — when the setting is enabled —invoke it directly with
Yesinstead of showing the popup.Implementation notes
upgrades and the alliance contribution warning), so the patch entry label was
renamed from
ForbiddenTechConfirmtoMessageBoxConfirmations. This is cosmetic;the installer, hook set, and the existing
[patches]forbiddentechconfirmhookstoggle are unchanged, so existing user configs are unaffected.
[patches]install toggle, default on). The
ui.auto_confirm_alliance_contributionfeaturesetting is checked inside the hook; when it is disabled, the native popup behavior
is preserved exactly.
false) keeps stock behavior; the setting is opt-in, mirroringauto_confirm_ft_upgradeandauto_confirm_reveal_ability.example_community_patch_settings_en.tomlupdated with the new setting (otherlocales left untouched per repo convention).
Testing
xmake -y modsbuilds clean on macOS (arm64, debug,--target_minver=14.6)git diff --checkpasses; no whitespace/conflict artifactswarning suppressed and contribution applied (also sanity-check that other
MessageBox popups — event ads, store offers, generic OK/Cancel dialogs — are
unaffected)
the
ButtonResult.Yes(= 3) constant should be verified against the Windowsclient (
_WIN32/_M_X64), and the popup should be exercised in-game with thesetting both off (native warning appears) and on (warning is skipped, the
contribution registers normally)