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

Scripted effect · All Under Heaven files

tgp_restore_japanese_monarchy_yamato_restoration_effect

tgp_restore_japanese_monarchy_yamato_restoration_effect = yes

game/common/scripted_effects/10_dlc_tgp_japan_scripted_effects.txt, line 2702 (50 lines). No parameters.

tgp_restore_japanese_monarchy_yamato_restoration_effect is a scripted effect in Crusader Kings III, in the All Under Heaven files, written at line 2702 of its file. It takes no parameters: tgp_restore_japanese_monarchy_yamato_restoration_effect = yes. The game's script calls it in 2 places, among them Yamato Ten'nō Restored (event tgp_japan_decision.9901) and Yamato Ten'nō Restored (event tgp_japan_decision.9902). Patch 1.20.1.2, from game/common/scripted_effects/10_dlc_tgp_japan_scripted_effects.txt.

What it does

  • If

    a check the game hides

    Then

    • Chrysanthemum Throne: Gains the … Title (scion)
    • If

      • scope:scion.liege != scope:kampaku
      • scope:scion != scope:kampaku

      Then

      • scope:scion:
        • change_liege = { liege = scope:kampaku change = scope:change }

• 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 (50 lines of game script)
tgp_restore_japanese_monarchy_yamato_restoration_effect = {
	add_character_flag = tgp_japan_restore_japanese_monarchy_flag
	if = {
		limit = { exists = scope:scion }
		if = {
			limit = { exists = title:k_chrysanthemum_throne.holder }
			create_title_and_vassal_change = {
				type = usurped
				save_scope_as = change
				add_claim_on_loss = yes
			}
		}
		else = {
			create_title_and_vassal_change = {
				type = created
				save_scope_as = change
			}
		}
		title:k_chrysanthemum_throne ?= {
			change_title_holder = {
				holder = scope:scion
				change = scope:change
			}
		}
		if = {
			limit = {
				scope:scion.liege != scope:kampaku
				scope:scion != scope:kampaku
			}
			scope:scion ?= {
				change_liege = {
					liege = scope:kampaku
					change = scope:change
				}
			}
		}
		resolve_title_and_vassal_change = scope:change
	}
	remove_character_flag = tgp_japan_restore_japanese_monarchy_flag
	hidden_effect = {
		scope:scion = {
			if = {
				limit = {
					NOT = { government_has_flag = government_is_japan_administrative }
				}
				change_government = japan_administrative_government
			}
		}
	}
}

As written in game/common/scripted_effects/10_dlc_tgp_japan_scripted_effects.txt.

Where it is used

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

Events (2)

Source: game/common/scripted_effects/10_dlc_tgp_japan_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?