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

Scripted effect · Silk and Silver files

merchant_charter_abuse_counter_effect

merchant_charter_abuse_counter_effect = { MERCHANT = … PATRON = … }

game/common/scripted_effects/gdp_merchant_scripted_effects.txt, line 3963 (200 lines). Parameters: $MERCHANT$, $PATRON$.

merchant_charter_abuse_counter_effect is a scripted effect in Crusader Kings III, in the Silk and Silver files, written at line 3963 of its file. A call passes 2 parameters: MERCHANT and PATRON. The game's script calls it in 6 places, among them Abuse Charter Authority (decision), Leverage Patron's Authority (interaction) and disrupt_charter (contract). Its body carries 13 texts of the game's own for the player. Patch 1.21.0, from game/common/scripted_effects/gdp_merchant_scripted_effects.txt.

The comment above it in the file

Merchant Charter Effects

What it does

  • If

    • scope:patron: Is played by a person

    Then

    Otherwise

    • If

      • One of these

        • Charter abuse patron is not scope:patron
        • or

          NOT = { exists = var:charter_abuse_stance }

      Then

      • Your Patron is indifferent and will not take any action

      Else if

      a check the game hides

      Then

      • Depending on charter abuse stance:
        • When charter abuse stance is angry › 1 of 3 things will happen:
          • 23% (base chance; changed in play) › 15% chance of:
            • Your forgery is revealed
            • scope:patron: Opinion: Forged Charter
          • 46% (base chance; changed in play):
          • 31%: Your Patron will be furious but will not take any action
        • When charter abuse stance is annoyed › 1 of 3 things will happen:
          • 17% (base chance; changed in play):
            • Your forgery is revealed
            • scope:patron: Opinion: Forged Charter
          • 33% (base chance; changed in play):
          • 50%: Your Patron will be furious but will not take any action
        • When charter abuse stance is indifferent › 1 of 3 things will happen:
          • 9% (base chance; changed in play):
            • Your forgery is revealed
            • scope:patron: Opinion: Forged Charter
          • 18% (base chance; changed in play):
          • 73%: Your Patron will be annoyed but will not take any action
        • When charter abuse stance is pleased: Your Patron will be indifferent and will not take any action
        • When charter abuse stance is grateful: Your Patron will be pleased and will not take any action

• 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)
merchant_charter_abuse_counter_effect = {
	$PATRON$ = { save_scope_as = patron }
	$MERCHANT$ = { save_scope_as = merchant }
	if = {
		limit = {
			scope:patron = { is_ai = no }
		}
		custom_tooltip = merchant_charter_abuse_counter_random
		scope:patron = {
			trigger_event = {
				id = gdp_decision.1010
				days = { 1 4 }
			}
		}
	}
	else = {
		set_variable = {
			name = charter_abused_patron
			value = scope:patron
		}
		if = {
			limit = {
				OR = {
					NOT = { var:charter_abuse_patron ?= scope:patron }
					NOT = { exists = var:charter_abuse_stance }
				}
			}
			custom_tooltip = merchant_charter_abuse_counter_indifferent
			set_variable = {
				name = charter_abuse_patron
				value = scope:patron
			}
			set_variable = {
				name = charter_abuse_stance
				value = flag:indifferent
			}
		}
		else_if = {
			limit = { exists = var:charter_abuse_stance }
			switch = {
				trigger = var:charter_abuse_stance
				flag:angry = {
					random_list = {
						30 = {
							modifier = {
								factor = 0.5
								scope:merchant = { has_perk = accomplished_forger_perk }
							}
							modifier = {
								factor = 0.6
								scope:merchant = { has_perk = digging_for_dirt_perk }
							}
							trigger = {
								scope:charter_artifact.var:forger ?= scope:merchant
								NOT = {
									scope:patron = {
										has_opinion_modifier = {
											target = scope:merchant
											modifier = forged_charter_opinion
										}
									}
								}
							}
							random = {
								chance = 15
								custom_tooltip = merchant_charter_abuse_forgery_detected
								scope:patron = {
									add_opinion = {
										target = scope:merchant
										modifier = forged_charter_opinion
									}
								}
							}
						}
						60 = {
							modifier = { add = merchant_charter_abuse_patron_reaction_value }
							custom_tooltip = merchant_charter_abuse_counter_reaction_action
							trigger_event = {
								id = gdp_decision.1000
								days = { 21 37 }
							}
						}
						40 = {
							custom_tooltip = merchant_charter_abuse_counter_reaction_angry
						}
					}
				}
				flag:annoyed = {
					set_variable = {
						name = charter_abuse_stance
						value = flag:angry
					}
					random_list = {
						20 = {
							modifier = {
								factor = 0.5
								scope:merchant = { has_perk = accomplished_forger_perk }
							}
							modifier = {
								factor = 0.6
								scope:merchant = { has_perk = digging_for_dirt_perk }
							}
							trigger = {
								scope:charter_artifact.var:forger ?= scope:merchant
								NOT = {
									scope:patron = {
										has_opinion_modifier = {
											target = scope:merchant
											modifier = forged_charter_opinion
										}
									}
								}
							}
							custom_tooltip = merchant_charter_abuse_forgery_detected
							scope:patron = {
								add_opinion = {
									target = scope:merchant
									modifier = forged_charter_opinion
								}
							}

As written in game/common/scripted_effects/gdp_merchant_scripted_effects.txt.

The first 120 of its 200 lines; the rest is in game/common/scripted_effects/gdp_merchant_scripted_effects.txt from line 3963.

Where it is used

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

Character interactions (1)

Task contracts (1)

  • disrupt_charter

Events (3)

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

Spotted a mistake on this page, or have an idea for the site?