Welcome to the TWC Wiki! You are not logged in. Please log in to the Wiki to vote in polls, change skin preferences, or edit pages. See HERE for details of how to LOG IN.

Difference between revisions of "Papal faction modding (M2TW)"

From TWC Wiki
Jump to navigationJump to search
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
For discussion and answers to problems with modding a papal faction please also see the thread [https://www.twcenter.net/forums/showthread.php?808480-Why-Avoid-Using-papal_states Why Avoid Using papal_states?] on TWC.  The article below will attempt to summarise the findings.
 
For discussion and answers to problems with modding a papal faction please also see the thread [https://www.twcenter.net/forums/showthread.php?808480-Why-Avoid-Using-papal_states Why Avoid Using papal_states?] on TWC.  The article below will attempt to summarise the findings.
  
Any one faction in M2TW can become the 'Papal Faction' by using the line
+
Any one faction in M2TW can become the 'Papal Faction' by using this line in [[descr_sm_factions.txt]]. It does not have to be the [[Papal States (M2TW Faction)|papal_states]] faction:
 
  special_faction_type papal_faction
 
  special_faction_type papal_faction
in [[descr_sm_factions.txt]]. It does not have to be the [[Papal States (M2TW Faction)|papal_states]] faction.
 
  
Any faction using this line must also use  
+
 
 +
Any faction using this line must also use this line to disable the family tree, otherwise, the faction will be destroyed and the game will crash if the pope dies.
 
  has_family_tree no
 
  has_family_tree no
otherwise, the faction will be destroyed and the game will crash if the pope dies.
+
 
 +
 
 +
The papal faction may not be able to call crusades without a request if its standing with itself is not high enough!  To fix this issue add this or similar to your campaign script, using the papal factions internal name in place of faction_name. 
 +
 
 +
monitor_event FactionTurnStart FactionType faction_name
 +
set_faction_standing faction_name faction_name 1.0
 +
end_monitor
 +
 
  
 
==What happens when the Pope dies?==
 
==What happens when the Pope dies?==
Line 25: Line 32:
  
 
A named_character spawned via spawn_army whilst the college and Pope position are empty will become pope.  That character will retain his portrait, label and first name.
 
A named_character spawned via spawn_army whilst the college and Pope position are empty will become pope.  That character will retain his portrait, label and first name.
 +
 +
==See Also==
 +
For information about the Papal States faction in the unmodded game please see [[Papal States (M2TW Faction)]]
  
 
[[Category:M2TW Modding]]
 
[[Category:M2TW Modding]]

Latest revision as of 07:55, 27 February 2021

For discussion and answers to problems with modding a papal faction please also see the thread Why Avoid Using papal_states? on TWC. The article below will attempt to summarise the findings.

Any one faction in M2TW can become the 'Papal Faction' by using this line in descr_sm_factions.txt. It does not have to be the papal_states faction:

special_faction_type				papal_faction


Any faction using this line must also use this line to disable the family tree, otherwise, the faction will be destroyed and the game will crash if the pope dies.

has_family_tree					no


The papal faction may not be able to call crusades without a request if its standing with itself is not high enough! To fix this issue add this or similar to your campaign script, using the papal factions internal name in place of faction_name.

monitor_event FactionTurnStart FactionType faction_name
set_faction_standing faction_name faction_name 1.0
end_monitor


What happens when the Pope dies?

If the papal_faction is used in M2TW there are two alternative ways of arranging a replacement for a dead pope.

Choice by College of Cardinals

The College can only be populated by priest agents with piety above the threshold set in the campaign_db.xml to reach 'cardinal' level.

The Pope will be chosen, by voting of the catholic factions, from amongst the priest agents in the college. The selected priest will disappear from the owning factions' roster and appear as a general with his original priest portrait, but a new name, in the papal_faction's capital.

Even if all the priests in the college are controlled by the same AI faction it doesn't seem as though there is a trait-based way of controlling who gets promoted to Pope.

Attempting to control the attributes of spawned priest agents who would qualify for the college (who don't start in descr_strat) is limited by spawn_character not allowing labels or custom portraits. Spawning a priest via spawn_army, which does allow those variables, is limited by the priest being killed when the game is reloaded, this causes a crash if the priest is adopted into the college and the player quits and reloads on the turn that the vote should be resolved.

Spawned Army with Empty College

If no priests are qualified as cardinals and the college is empty, and the Pope dies, the papal_faction can continue without a faction leader and without a pope in place, apparently indefinitely.

A named_character spawned via spawn_army whilst the college and Pope position are empty will become pope. That character will retain his portrait, label and first name.

See Also

For information about the Papal States faction in the unmodded game please see Papal States (M2TW Faction)