• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Steve5000

Recruit
58 Badges
Dec 5, 2013
8
5
  • Stellaris: Ancient Relics
  • Stellaris: Synthetic Dawn
  • Age of Wonders III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • Stellaris: Distant Stars
  • Europa Universalis IV: Dharma
  • Stellaris: Megacorp
  • Europa Universalis IV: Golden Century
  • Imperator: Rome
  • Hearts of Iron IV: Expansion Pass
  • Prison Architect
  • Hearts of Iron IV: Death or Dishonor
  • Stellaris: Lithoids
  • Hearts of Iron IV: La Resistance
  • Stellaris: Federations
  • Imperator: Rome - Magna Graecia
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Battle for Bosporus
  • Europa Universalis 4: Emperor
  • Stellaris: Necroids
  • Stellaris: Nemesis
  • Hearts of Iron IV: By Blood Alone
  • Hearts of Iron IV: No Step Back
  • Hearts of Iron 4: Arms Against Tyranny
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Res Publica
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Common Sense
  • Cities: Skylines - After Dark
  • A Game of Dwarves
  • Europa Universalis IV: Mare Nostrum
  • Stellaris
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet

Integrity​

I have verified my game files (on Steam)​

Yes

I have disabled all mods​

Yes

Required​

Summary​

USA formation not working due to wrong flag

Description​

USA can not be formed from former colonial nations if in the american tech group per lines 30-33 of decisions/USANation.txt.

The check performed is: "is_former_colonial_nation = yes", which is never cleared , because this flag is never set in the formation of other colonial nations. The flag set in other colonial nations is "set_country_flag = changed_from_colonial_nation"

the flag "is former colonial nation appears to be an out of date / unused flag as it is never set anywhere in the code.

Steps to reproduce​

Release yourself as a native colonial nation.
Form Texas
Try to form USA (can't)

Game Version​

Current Version

OS​

Windows

Additional​

Bug Type​

  • Controls (wrong logic in buttons, menu)

Attachments​



Screenshot​



 
Upvote 0
The check performed is: "is_former_colonial_nation = yes", which is never cleared , because this flag is never set in the formation of other colonial nations. The flag set in other colonial nations is "set_country_flag = changed_from_colonial_nation"

the flag "is former colonial nation appears to be an out of date / unused flag as it is never set anywhere in the code.
It is set in code and not in the script. You know that it was working, because it allowed you to form Texas in the first place. But as soon as you form another country, you are not a former colonial nation anymore, so you can't use it to bypass the tech group requirements a second time.
 
It is set in code and not in the script. You know that it was working, because it allowed you to form Texas in the first place. But as soon as you form another country, you are not a former colonial nation anymore, so you can't use it to bypass the tech group requirements a second time.

is_colonial_nation is a nation like Spanish Florida
a former colonial nation is if Spanish florida forms actual florida

It's clearly erroneous code as the "is_former_colonial_nation" tag is never set anywhere in the rest of the game files.

Instead it has "set_country_flag = changed_from_colonial_nation" ... but "changed_from_colonial_nation" is never checked anywhere.

1714070540715.png


1714070580764.png
 
is_colonial_nation is a nation like Spanish Florida
That's only true while Spanish Florida is a subject which has the line "has_colonial_parent = yes" in common/subject_types/00_subject_types.txt. If it gains independence it ceases to be a colonial nation. Instead "is_former_colonial_nation" becomes true.
It's clearly erroneous code as the "is_former_colonial_nation" tag is never set anywhere in the rest of the game files.
is_former_colonial_nation is not some kind of variable which can be set. And neither is it a scripted trigger which you could find in the game files. Like is_colonial_nation, it is a trigger which is coded in eu4's source code. The source code is not publicly available, but you can open the eu4 executable (e.g. eu4.exe on windows) in an (hex-) editor and search for is_former_colonial_nation which will show you something like the following:
1714074047291.png


You can use the following steps to confirm that "is_former_colonial_nation = yes" actually works.
  1. create a run file with the following contents:
    Code:
    if = {
        limit = {
            is_former_colonial_nation = yes
        }
        add_treasury = 1
    }
    else = {
        add_prestige = 2
    }
  2. Start a new campaign as Castile in 1444
  3. use the console command integrate AZT and unpause the game to gain a colonial nation in Mexico
  4. release and play as the colonial nation
  5. use the run command to execute the run file(with the filename as a parameter). If is_former_colonial_nation is true, you gain 1 ducat. If it is false, you gain 2 prestige. If neither of those things happen, the run file has not been executed(e.g. because it was in the wrong folder or it had invalid code, ...)
  6. form a new country(e.g. Mexico)
  7. run the run file again. Now you gain 2 prestige, because is_former_colonial_nation is not true anymore
  8. you can do a similar test with is_colonial_nation = yes in the run file instead of is_former_colonial_nation = yes to confirm that it is true for colonial nations while they are a subject and that it is not true anymore if you grant them independence
Instead it has "set_country_flag = changed_from_colonial_nation" ... but "changed_from_colonial_nation" is never checked anywhere.
That flag is checked in all the decisions of the post-colonial formables. e.g. TexasNation.txt has
1714074722679.png