CK3 DatabaseCrusader Kings III · 1.20.1.2 “Crozier” · unofficial
Silk & Silverout Tue, Nov 17What's free, what needs the DLC, price →

Scripted effect · Roads to Power files

ep3_pick_random_maa_regiment_effect

ep3_pick_random_maa_regiment_effect = { INCLUDE_BASIC_MAA = … INCLUDE_SIEGE_MAA = … OWNER = … }

game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt, line 7778 (960 lines). Parameters: $INCLUDE_BASIC_MAA$, $INCLUDE_SIEGE_MAA$, $OWNER$.

ep3_pick_random_maa_regiment_effect is a scripted effect in Crusader Kings III, in the Roads to Power files, written at line 7778 of its file. A call passes 3 parameters: INCLUDE_BASIC_MAA, INCLUDE_SIEGE_MAA and OWNER. The game's script calls it in 3 places, among them Make a Request (interaction), Make a Request (interaction) and Grand Ambitions: Call to Arms (event grand_ambitions.0110). Patch 1.20.1.2, from game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt.

The comment above it in the file

Picks a random valid maa type for OWNER to create

What it does

  • $OWNER$ = { … }
  • If

    a check the game hides

    Then

    • 1 of 4 things will happen:
      • 25%: Nothing else happens
      • 25%: Nothing else happens
      • 25%: Nothing else happens
      • 25%: Nothing else happens

• the game's own tooltip text · ◦ our reading of the script line · code the script where neither exists

“They” is whatever it runs on (the scope it is called in). The scripted triggers and effects it calls link to their own pages; $PARAMETERS$ stay as written: each call fills them in.

The script as written (120 lines of game script)
ep3_pick_random_maa_regiment_effect = {
	save_temporary_scope_value_as = {
		name = include_basic_maa
		value = $INCLUDE_BASIC_MAA$
	}
	save_temporary_scope_value_as = {
		name = include_siege_maa
		value = $INCLUDE_SIEGE_MAA$
	}
	$OWNER$ = {
		random_list = {
			1 = {
				trigger = {
					scope:include_basic_maa = yes
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:light_footmen
				}
			}
			1 = {
				trigger = {
					scope:include_basic_maa = yes
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:bowmen
				}
			}
			1 = {
				trigger = {
					scope:include_basic_maa = yes
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:light_horsemen
				}
			}
			1 = {
				trigger = {
					scope:include_basic_maa = yes
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:pikemen_unit
				}
			}
			# TRIBAL
			1 = {
				trigger = {
					culture = { has_innovation = innovation_elephantry }
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:war_elephant
				}
			}
			1 = {
				trigger = {
					culture = { has_innovation = innovation_war_camels }
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:camel_rider
				}
			}
			1 = {
				trigger = {
					culture = { has_innovation = innovation_arched_saddle }
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:armored_horsemen
				}
			}
			1 = {
				trigger = {
					culture = {
						has_innovation = innovation_catapult
						culture_uses_eastern_siege_weapons_trigger = no
					}
					scope:include_siege_maa = yes
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:onager
				}
			}
			1 = {
				trigger = {
					culture = {
						has_innovation = innovation_catapult
						culture_uses_eastern_siege_weapons_trigger = yes
					}
					scope:include_siege_maa = yes
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:ballista
				}
			}
			# EARLY
			1 = {
				trigger = {
					culture = { has_innovation = innovation_quilted_armor }
				}
				save_scope_value_as = {
					name = maa_to_create
					value = flag:armored_footmen
				}
			}
			1 = {
				trigger = {
					culture = {
						has_innovation = innovation_mangonel
						culture_uses_eastern_siege_weapons_trigger = no
					}
					scope:include_siege_maa = yes
				}
				save_scope_value_as = {

As written in game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt.

The first 120 of its 960 lines; the rest is in game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt from line 7778.

Where it is used

Every place in common/, events/ and history/ that calls ep3_pick_random_maa_regiment_effect.

Character interactions (2)

Events (1)

Source: game/common/scripted_effects/07_dlc_ep3_scripted_effects.txt and every file of common/, events/ and history/ that calls it, Crusader Kings III 1.20.1.2.

Spotted a mistake on this page?