Menu

#3401 Custom nation naming (flag, citizen name) is not applied after declaring independence

Current
open
nobody
None
5
2026-07-23
2026-07-23
No

Description

During the independence declaration dialog, the player is prompted to
customize several things about their new nation — including a custom
flag design and a name for their citizens (e.g. "Haitian citizens").
None of these customizations appear to carry over into gameplay after
independence is won:

  1. The custom flag is not saved or shown in the Foreign Affairs report.
  2. Units continue to display their pre-independence unit type names
    (e.g. "FreeColonist") instead of the custom citizen name chosen
    during declaration.
  3. Enemy/rival units also retain their original colonial-power naming
    (e.g. "French continental cavalry") even after the player has won
    the war of independence against them.

Steps to Reproduce

  1. Play to the point where independence can be declared.
  2. In the declaration dialog, design a custom flag and enter a custom
    name for citizens (e.g. "Haitian citizens").
  3. Confirm the declaration and win the war of independence.
  4. Observe:
  5. Foreign Affairs report still shows the old colonial flag.
  6. Your own units are still labeled "FreeColonist" rather than the
    chosen citizen name.
  7. Defeated/rival units are still labeled with their original
    colonial designation (e.g. "French continental cavalry").

Expected Behavior

Once independence is declared (and/or won), the custom flag and
citizen naming chosen by the player should be reflected everywhere
the nation and its units are displayed — Foreign Affairs report, unit
labels/tooltips, combat logs, etc.

Actual Behavior

All of these revert to or remain on the original colonial-era values;
none of the independence-time customization persists.

Technical Notes

  • ReportForeignAffairPanel.java (~line 88) renders the flag via
    lib.getScaledNationImage(enemy.getNation()), which always resolves
    to the original colonial Nation.
  • ConfirmDeclarationDialog.java builds a Flag object for preview,
    but getResponse() only returns nation name and country name — the
    flag design itself is discarded when the dialog closes.
  • Unit labels likely pull their display name from the base unit type
    (UnitType) or Nation/NationType rather than checking
    Player.isIndependent() and any custom naming field — this would
    need similar investigation in the unit-rendering/label code
    (likely under client/gui/) and in Nation/NationType.
  • A proper fix likely needs a single underlying mechanism: persist
    the player's independence-time customizations (flag design, citizen
    name) on Player/ServerPlayer, and have all relevant display code
    (flags, unit labels, reports) check for and use them when
    isIndependent() is true.

Environment

  • FreeCol version/branch: 1.2.0
  • OS: Windows 10

Discussion


Log in to post a comment.