• 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.

DesertSnow

Colonel
50 Badges
Oct 10, 2007
1.108
16
  • Hearts of Iron II: Armageddon
  • Stellaris - Path to Destruction bundle
  • Pillars of Eternity
  • Warlock: Master of the Arcane
  • Rome: Vae Victis
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Europa Universalis: Rome
  • Europa Universalis IV: Res Publica
  • Europa Universalis III Complete
  • March of the Eagles
  • Magicka
  • For The Glory
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV
  • Arsenal of Democracy
  • Crusader Kings II
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Europa Universalis III
  • Europa Universalis III Complete
  • Divine Wind
  • Europa Universalis IV: Art of War
  • Shadowrun: Hong Kong
  • Shadowrun: Dragonfall
  • Shadowrun Returns
  • Stellaris: Distant Stars
  • Stellaris: Apocalypse
  • Stellaris: Humanoids Species Pack
  • Tyranny - Bastards Wound
  • Stellaris: Synthetic Dawn
  • Imperator: Rome
  • Stellaris: Leviathans Story Pack
  • Tyranny: Archon Edition
  • Crusader Kings II: Reapers Due
  • Hearts of Iron IV: Cadet
  • Stellaris Sign-up
  • Hearts of Iron IV Sign-up
  • Stellaris
  • Crusader Kings II: Way of Life
  • Mount & Blade: Warband
  • 500k Club
  • Warlock 2: The Exiled
  • Victoria 2
  • Europa Universalis III Complete
  • Tyranny - Tales from the Tiers
  • Crusader Kings II: Charlemagne
I tried to create some events to make sure the AI always has a garrison is key areas, but the following command

command = { type = lock_division which = x value = y }

doesn't seem to work.

Am i doing sth wrong (e.g. wrong spelling) or is the command "broken"?

Thanks in advance,

DesertSnow
 

Zuckergußgebäck

Den ökända hästen från Troja
11 Badges
Jan 7, 2004
8.851
2
  • Hearts of Iron II: Armageddon
  • Deus Vult
  • Europa Universalis III
  • Heir to the Throne
  • Europa Universalis III Complete
  • Europa Universalis III Complete
  • Victoria: Revolutions
  • Victoria 2
  • Victoria 2: A House Divided
  • 500k Club
  • Hearts of Iron IV Sign-up
The command only applies to certain divisions, meaning that when you add the id type (x) and id (y), it will freeze the division wherever it is.

Practical example.
A german event with the command
Code:
command = { type = lock_division which = 14500 value = 35 }
Will, in the '36 scenario, lock the 1. Infanterie-Division, wherever it is currently located.
 

xtfoster

Field Marshal
57 Badges
Feb 8, 2006
5.874
2.209
  • Shadowrun Returns
  • Surviving Mars
  • Hearts of Iron IV: Death or Dishonor
  • Stellaris: Synthetic Dawn
  • Tyranny - Tales from the Tiers
  • Tyranny - Bastards Wound
  • Age of Wonders III
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • BATTLETECH - Digital Deluxe Edition
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Distant Stars
  • BATTLETECH
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • BATTLETECH: Flashpoint
  • Stellaris: Megacorp
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Ancient Relics
  • BATTLETECH: Season pass
  • Age of Wonders: Planetfall Sign Up
  • Stellaris: Lithoids
  • BATTLETECH: Heavy Metal
  • Hearts of Iron IV: La Resistance
  • Hearts of Iron IV: No Step Back
  • Stellaris: Galaxy Edition
  • Deus Vult
  • Europa Universalis III
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Majesty 2
  • Europa Universalis III Complete
  • Semper Fi
  • Supreme Ruler 2020
  • 500k Club
  • Hearts of Iron II: Beta
  • Stellaris
  • Hearts of Iron II: Armageddon
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Hearts of Iron IV: Cadet
  • Tyranny: Archon Edition
  • Tyranny: Archon Edition
  • Tyranny: Gold Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Hearts of Iron IV: Expansion Pass
Zuckergußgebäck said:
The command only applies to certain divisions, meaning that when you add the id type (x) and id (y), it will freeze the division wherever it is.

Practical example.
A german event with the command
Code:
command = { type = lock_division which = 14500 value = 35 }
Will, in the '36 scenario, lock the 1. Infanterie-Division, wherever it is currently located.
Basically what this means is that you can only "lock" divisions that you know the Type/ID for, or to be more specific, those divisions defined in the *.inc files. The best way to do this is to start the scenario with those divisions locked (check the UK.inc and/or USA.inc files for examples.)
 

Micah Goodman 2

Colonel
98 Badges
Dec 28, 2003
930
263
  • Stellaris: Galaxy Edition
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Conclave
  • Cities: Skylines - Snowfall
  • Europa Universalis IV: Mare Nostrum
  • Stellaris
  • Stellaris: Galaxy Edition
  • Cities: Skylines
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Field Marshal
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • Cities: Skylines - Mass Transit
  • Hearts of Iron IV: No Step Back
  • Europa Universalis IV: Wealth of Nations
  • 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 IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Crusader Kings II
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III Collection
  • Europa Universalis IV: Res Publica
  • Victoria: Revolutions
  • Semper Fi
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
The command works. Just make sure that you enter the right country code and division id. Look in the inc file for the scenario you are working on and that will give you the country code number used for that country. Then make sure that the id number for that division is correct. If it isn't working still double check the rest of the event to make sure something isn't missing.