I have restarted the game over 80 times in the last hour hoping to get an oppose Hitler start.

  • 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.
Showing developer posts only. Show all posts in this thread.

Archangel85

Content Design, HoI4 [Retired]
Paradox Staff
62 Badges
Jan 27, 2005
2.247
5.213
  • Europa Universalis IV: El Dorado
  • March of the Eagles
  • Naval War: Arctic Circle
  • Europa Universalis IV: Res Publica
  • Semper Fi
  • Sengoku
  • Sword of the Stars II
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Warlock: Master of the Arcane
  • 500k Club
  • Cities: Skylines
  • Magicka
  • Magicka: Wizard Wars Founder Wizard
  • Pride of Nations
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: By Blood Alone
  • Europa Universalis III: Chronicles
  • Cities in Motion 2
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Europa Universalis III
  • Cities in Motion
  • Divine Wind
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
Time for some actual math. There are 6 focus that are available at the begining of the game with weights of : 12, 1,1,10,1,1. So Rhineland has a probability of 10/26, and Oppose Hitler at 1/26. Meaning almost a 4% chance at the game start.

That is not how that system works. The focuses set to 1 are never chosen and the choice is between the 12 and the 10. We could fix this (and I have pushed for it before) but it shouldn't be as big of an issue come 1.6 anyway.
 

Bratyn

Content Design Lead
Paradox Staff
39 Badges
Dec 25, 2012
1.189
1.824
  • Crusader Kings II: Charlemagne
  • Europa Universalis IV: Pre-order
  • Semper Fi
  • Europa Universalis IV: Res Publica
  • Naval War: Arctic Circle
  • Magicka
  • Leviathan: Warships
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Wealth of Nations
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II
  • Stellaris Sign-up
  • Prison Architect
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Field Marshal
  • Hearts of Iron IV: Death or Dishonor
  • Age of Wonders III
  • Hearts of Iron IV: Expansion Pass
  • Hearts of Iron IV: Expansion Pass
  • Hearts of Iron IV Sign-up
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Stellaris
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Way of Life
  • Europa Universalis IV: El Dorado
  • 500k Club
  • Europa Universalis IV
Then why have an a-historical mode then? If the AI will never pick unlikely options because they are weighted so low?

Another reason is that there was incredible backlash at the bare notion of it even being conceivable of AI Germany ever going ahistorical, so when it was discovered that there is an issue in the weightings (AFAIK any focuses with less than 1/3rd of the chance of other foci never get picked) I didn't increase the value for Oppose Hitler. As stated, with 1.6 it won't be an issue anymore, since if you want Oppose Hitler to get picked you can set the AI to do so.
 

Archangel85

Content Design, HoI4 [Retired]
Paradox Staff
62 Badges
Jan 27, 2005
2.247
5.213
  • Europa Universalis IV: El Dorado
  • March of the Eagles
  • Naval War: Arctic Circle
  • Europa Universalis IV: Res Publica
  • Semper Fi
  • Sengoku
  • Sword of the Stars II
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Warlock: Master of the Arcane
  • 500k Club
  • Cities: Skylines
  • Magicka
  • Magicka: Wizard Wars Founder Wizard
  • Pride of Nations
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: By Blood Alone
  • Europa Universalis III: Chronicles
  • Cities in Motion 2
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Europa Universalis III
  • Cities in Motion
  • Divine Wind
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
I checked the code and I see nothing that prevents picking focuses with weight 1. The weighting is skewed however and does not work like in other places that use weights like this. Each focus rolls a die from 0 up to its ai_will_do value and the largest value wins. For example if one focus with ai_will_do 2 is available and another with ai_will_do 4 the pick ratio the latter wins in 50% of the cases where it rolls above 1 and half of the remaining cases where both roll between 0 and 1. So the pick rate is not 33% vs 66% but actually 25% vs 75%. Simulating this method with all the German starting focus weights 100000 times I get ~136 times Oppose Hitler, i.e. it takes on average 735 games to get this start.

Code:
import random
successes = 0
for i in range(100000):
    fourYearPlan = random.random()*10
    airInno = random.random()*1
    armyInno = random.random()*1
    rheinland = random.random()*12
    oppose = random.random()*1
    naval = random.random()*1
    successes += oppose > max(fourYearPlan,airInno,armyInno,rheinland,naval)

Edit: also the dice roll is not done for ai_will_do's below 1; this means 0.999 is twice as likely to be picked as 1.0

We were specifically told by the person who made the system that this is not how it works. There is no dice roll on the base value, it just takes the ai_weight of all the available focuses, adds a random value of up to 50% to it, and then picks the focus with the highest value. That means if a focus is not within 50% of the base value of the highest available focus, it will never be picked.
 

Archangel85

Content Design, HoI4 [Retired]
Paradox Staff
62 Badges
Jan 27, 2005
2.247
5.213
  • Europa Universalis IV: El Dorado
  • March of the Eagles
  • Naval War: Arctic Circle
  • Europa Universalis IV: Res Publica
  • Semper Fi
  • Sengoku
  • Sword of the Stars II
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Warlock: Master of the Arcane
  • 500k Club
  • Cities: Skylines
  • Magicka
  • Magicka: Wizard Wars Founder Wizard
  • Pride of Nations
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: By Blood Alone
  • Europa Universalis III: Chronicles
  • Cities in Motion 2
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Europa Universalis III
  • Cities in Motion
  • Divine Wind
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
That seems like a very tough balance to get right, and we do want the achievements to be somewhat comparable between players - otherwise you end up in a situation where people restart endlessly to get an easier achievement run.
 

Archangel85

Content Design, HoI4 [Retired]
Paradox Staff
62 Badges
Jan 27, 2005
2.247
5.213
  • Europa Universalis IV: El Dorado
  • March of the Eagles
  • Naval War: Arctic Circle
  • Europa Universalis IV: Res Publica
  • Semper Fi
  • Sengoku
  • Sword of the Stars II
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Warlock: Master of the Arcane
  • 500k Club
  • Cities: Skylines
  • Magicka
  • Magicka: Wizard Wars Founder Wizard
  • Pride of Nations
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: By Blood Alone
  • Europa Universalis III: Chronicles
  • Cities in Motion 2
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Europa Universalis III
  • Cities in Motion
  • Divine Wind
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
The random rule uses a different system but I will add this to my growing list of "lostech is a real concept in the real world and HoI 4 is a good example of lostech in action"
 

Archangel85

Content Design, HoI4 [Retired]
Paradox Staff
62 Badges
Jan 27, 2005
2.247
5.213
  • Europa Universalis IV: El Dorado
  • March of the Eagles
  • Naval War: Arctic Circle
  • Europa Universalis IV: Res Publica
  • Semper Fi
  • Sengoku
  • Sword of the Stars II
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • Warlock: Master of the Arcane
  • 500k Club
  • Cities: Skylines
  • Magicka
  • Magicka: Wizard Wars Founder Wizard
  • Pride of Nations
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: By Blood Alone
  • Europa Universalis III: Chronicles
  • Cities in Motion 2
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Europa Universalis III
  • Cities in Motion
  • Divine Wind
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Heir to the Throne
  • Knights of Pen and Paper +1 Edition
Assuming there will be a "random" setting which will let all countries chose their focuses at random, will it actually allow for true randomness? Right now there are paths that countries will not take in their tree even with historical focuses turned off. Many of the communist paths are an example of this. In 1.6 if I select for focuses to be random, will there be a chance of perhaps a communist Hungary or a fascist Czechoslovakia or will the current weighting system be maintained even on random?

On random, the AI will chose a random strategy plan, which usually include a communist plan.