Following is my guide to modding events in Beyond the Sword. The guide is part of the Modders Guide to Beyond the Sword. Any updates will be posted to this thread first, and it can be used for feedback and questions related to this guide and event modding. The guide follows...
-------------------------------
Intro
Random events are one of the new features in Civ4: Beyond the Sword. The game ships with over 150 events, which vary from happiness and diplomatic bonuses to free promotions and technological breakthroughs. The event system provides a great foundation for modders to build open, as all events can be modded and new ones can be added.
You can create a wide array of possible events through XML modding only, but events can also be enhanced by Python for more versatility. The last section of this guide has some examples of events that can be modded in. The events described therein, along with some others, can be found in an event mod created by me. Think of the mod as an addendum to this guide, if you will. It can be found here.
The basics
It’s important to understand the two basic building blocks of the event system – triggers and events. “Triggers” are a collection of parameters indicating conditions when they can activate. So, triggers check whether you have the required technologies, population, etc. If the trigger’s conditions are met, it has a chance of activating. When a trigger is activated, it gives the player choice between one or more “events” (well, when there is only one event, there’s no choice). Events themselves are what provides the specific results that then affect the player.
Players may be inclined to think of the event system as consisting of “events”and “choices” – that’s not really accurate. Every choice is a separate event, and a trigger is what gives those choices.
As most other things in Civ4, events are primarily handled in the SDK. Events are described by the CvEventInfo class, which mimics the XML description of events. Below is the description of event tags in the XML file. If you can read C++, you may want to take a look at the definition of CvEventInfo. The correspondence between member functions of that class and the XML values should be fairly obvious.
Event triggers are kept in Civ4EventTriggerInfos.xml and that file, along with triggers in general, will be described after the event description explanations.
Civ4EventInfos.xml
Assets\XML\Events\Civ4EventInfos.xml is the main file describing all the in-game events. This section will describe the tags in that file, explaining their meaning.
Type- this is the event type identifier. Takes the form of EVENT_NAME
Description- identifier of the text string which contains the event description. Typically takes the form of TXT_KEY_EVENT_NAME, and description text strings can be found in Assets\XML\Text\Civ4GameText_Events_BTS.xml
LocalInfoText- identifier of the text string, if any, to be shown to the affected player.
WorldNewsTexts- specifies text, if any, to be shown to every player in the world (who has met the affected civilization) when the event occurs.
OtherPlayerPopup- specifies text, if any, to show in a popup to the other player affected. In BtS, is used for the Partisans event.
QuestFailText- specifies text, if any, to be displayed if the quest has been failed. Obviously, used for quests.
bQuest- can be either 0 or 1. If set to 1, then the event is actually a quest.
bGlobal- can be either 0 or 1. If set to 1, then the event will apply to all players. That is used for events that complete a quest in order to reset it for every player.
bTeam- can be either 0 or 1. If set to 1, then it will apply to all players on the same team. It’s not used in any of the events shipping with BtS.
bPickCity- can be either 0 or 1. If set to 1, then the event affects a city of the player for whom the event was triggered.
bPickOtherPlayerCity- can be either 0 or 1. If set to 1, the event affects a foreign city. For example, you can be given the choice of spending some espionage points to worsen the effects this event deals to the foreign city. Used in conjunction with, creates an event that affects the player’s city and a foreign city. Famine is one example of such an event in BtS.
bDeclareWar- can be either 0 or 1. If set to 1, will cause the affected player and the other player to go to war.
iGold- is a number. Specifies the base amount of gold that the affected player gains. If set to a negative number, the player will lose the gold. Can also optionally affect the other player – see below.
bGoldToPlayer- can be either 0 or 1. Works in conjunction with. If set to 1, then the gold value of will be given to the other player. Since it requires another player, it’s only useful for events that involve another player.
iRandomGold- is a number. Specifies the cap for an extra random amount of gold that is added to iGold to produce the total amount of gold.
iCulture- is a number. Specifies the amount of culture to be added to a city – only useful for events targeting a city.
iEspionagePoints- is a number. Specifies the amount of espionage points that the affected player will gain towards the other player.
bGoldenAge- can be either 0 or 1. If set to 1, triggers a golden age for the affected player.
iFreeUnitSupport- is a number. Specifies how many extra free units the player is allowed to support.
iInflationMod- is a number. Specifies by how much the affected player’s inflation modifier is changed.
iSpaceProductionMod- is a number. Specifies by how much the player’s spaceship part production modifier is changed. A value of 10, for example, would speed SS production up by 10%.
Tech- is a technology identifier. NONE for no technology. If set, explicitly specifies a technology towards which you can gain beakers.
TechFlavors- if not empty, contains one or more flavor types. For events that result in progress towards a technology, flavors affect which technology will be picked. For example, FLAVOR_RELIGION with a value of 1 will make you more likely to have progress towards a religious technology.
iTechPercent- is a number. Specifies by how many percent closer the player will become to the technology. The technology can be set explicitly (see) or chosen randomly. Negative numbers can be used to set research back.
iTechCostPercent- is a number. Specifies how many percent of the technology’s beaker cost to convert to a gold value.
iTechMinTurnsLeft- is a number. Specifies that the event may only affect techs for which the player needs at least this many turns to research. For example, setting to 2 for an event that advances research progress would mean that progress won’t be advanced for a tech that you’re about to complete in 2 turns.
PrereqTech- is a technology identifier. NONE for no technology. If set, then the technology is required for this event. Used to create event choices that the player can not pick unless he has the tech.
UnitClass- is a unit class identifier. NONE for no unit class. Specifies a unit class for receiving free units – see below.
iNumFreeUnits- is a number. Specifies how many free units of the class given in the player should receive. For example, with set to UNITCLASS_CROSSBOWMAN and to 2, the player would get 2 free Crossbowmen, or 2 free Chu-Ko-Nu if Chinese.
bDisbandUnit- can be either 0 or 1. If set to 1, disbands (kills) the affected unit.
iUnitExperience- is a number. Specifies the amount of free XP received by the affected unit.
iUnitImmobileTurns- is a number. Specifies the number of turns that the affected unit will remain immobile. Immobile units can still defend.
UnitPromotion- is a promotion identifier. For events that affect a specific unit (as determined by the trigger), can be used to apply a promotion to that specific unit. It’s not used in BtS, however – instead, Python callbacks are used (example: the Champion event).
UnitName- is a text string identifier. If specified, will set the affected unit’s name to the specified string.
UnitCombatPromotions- if non-empty, contains free promotions that all units of a selected combat type receive. Format to fill is as follows:
[xml]
UNITCOMBAT_ARCHER
PROMOTION_COMBAT1
[/xml]
The above would give all archery units a free Combat I promotion.
UnitClassPromotions- similar to above. If non-empty, contains free promotions for all units of a selected unit class to receive. Format as follows:
[xml]
UNITCLASS_AXEMAN
PROMOTION_SHOCK
[/xml]
That would give all Axeman-class units Shock.
BuildingClass- is a building class identifier. NONE for no building. Explicitly gives a building class to be affected by the event. Used with, see below.
iBuildingChange- is a number. Specifies how many buildings of the class specified in to add. Since a city can only contain 1 of a building, the only useful values are 1 to add a building and -1 to remove it. So, if is a BUILDINGCLASS_FORGE and is -1, the event would remove the affected city’s Forge.
BuildingExtraYields- if non-empty, contains information that modifies yield given by a building. For example, a building can be made to produce extra food or hammers. Format to fill as follows:
[xml]
BUILDINGCLASS_HARBOR
YIELD_COMMERCE
2
[/xml]
The above would give your Harbours 2 extra commerce. If is 0, the change will apply to all buildings of the class in your civ. If is 1, only the building in the affected city will be modified.
BuildingExtraCommerces- similar to above, if non-empty, contains information tat modifies commerce outputs given by a building. Note that this is not for pure commerce (to change that, use BuildingExtraYields and YIELD_COMMERCE as per the above example), but rather for commerce types – research, culture, gold or espionage. Format to fill as follows:
[xml]
BUILDINGCLASS_MARKET
COMMERCE_GOLD
1
[/xml]
The above would add 1 gold to the output of your Markets. Just as with the, if is 0, the change will apply to all buildings of the class in your civ. If is 1, only the building in the affected city will be modified.
BuildingExtraHappies- another similar tag, if non-empty, assigns extra happiness to buildings. Format as follows:
[xml]
BUILDINGCLASS_THEATRE
1
[/xml]
That’s to add 1 happiness to a Theatre. Once again, if is 0, the change will apply to all buildings of the class in your civ. If is 1, only the building in the affected city will be modified.
BuildingExtraHealths- works just like above, but adds extra health.
[xml]
BUILDINGCLASS_HOSPITAL
1
[/xml]
That would give +1 health to your Hospitals. If is 0, the change will apply to all buildings of the class in your civ. If is 1, only the building in the affected city will be modified.
iHappy- is a number. Specifies extra happiness to give. If is 0, the change will apply to the entire civ. If bPickCity> is 1, only the affected city’s happiness will be modified.
iHealth- is a number. Specifies extra health to give. If is 0, the change will apply to the entire civ. If is 1, only the affected city’s health will be modified.
iHurryAnger- is a number. Specifies extra whipping unhappiness to give. Unhappy citizens created by events using this variable will have the “We can not forget your cruel oppression!” unhappiness. You can be extra evil by setting to 0, which would give the penalty in all cities. Ack!
iHappyTurns- is a number. Specifies the amount of turns to give temporary happiness. The amount of happy faces given is specified in Assets\XML\GlobalAssets.xml as the TEMP_HAPPY variable. It defaults to 1 in BtS. Therefore, setting to 10 would ensure +1 happiness for 10 turns. Once again, if is 0, the change will apply to the entire civ. If is 1, only the affected city’s happiness will be modified.
iRevoltTurns- is a number. Specifies the amount of turns that the city will spend in revolt (no production, etc., like newly captured cities). Must be city-targeted, that is, used in conjunction with or set to 1.
iMinPillage- is a number. Specifies the minimum amount of terrain improvements that will be pillaged (removed). If used with a city-targeting event, then the pillaged improvement will be in the city’s radius. If the event doesn’t target a city, the improvement may be anywhere.
iMaxPillage- is a number. Specifies the maximum amount of terrain improvement that will be pillaged(removed). Works in conjunction with and must be equal or greater than , see above. Setting both variables to an equal value will result in exactly that many improvements getting pillaged.
iFood- is a number. Specifies the amount of stored food to be added in a city. If is 0, the change will apply to the entire civ. If is 1, only the affected city’s food stores will be modified.
iFoodPercent- is a number. Specifies by how many percent to modify the stored food in a city. You can remove all the stored food by setting this value to -100. If is 0, the change will apply to the entire civ. If is 1, only the affected city’s food stores will be modified.
FreeSpecialistCounts- if non-empty, describes the free specialists added to a city. Can only be used with events that target a city. Format is as follows:
[xml]
SPECIALIST_SCIENTIST
1
[/xml]
That would add a free Scientist to the city.
FeatureType- is a feature type identifier, NONE for no feature types. Sets the feature type that the event will add or remove in a plot, used in conjunction with, see below.
iFeatureChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the feature described in to the affected plot, setting to -1 would remove the feature.
ImprovementType- is an improvement type identifier, NONE for no improvement. Sets the improvement type that the event will add or remove in a plot, used in conjunction with, see below.
iImprovementChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the improvement described in to the affected plot, setting to -1 would remove the improvement.
BonusType- is a bonus (resource) type identifier, NONE for no bonus. Sets the bonus type that the event will add or remove in a plot, used in conjunction with, see below.
iBonusChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the bonus described in to the affected plot, setting to -1 would remove the bonus.
RouteType- is a route type identifier, NONE for no route. Sets the route type that the event will add or remove in a plot, used in conjunction with, see below.
iRouteChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the route described in to the affected plot, setting to -1 would remove the route.
BonusRevealed- is a bonus type identifier, NONE for no bonus. If used, will reveal the specified bonus to the affected player, even if he has no technology to normally see the bonus.
BonusGift- is a bonus type identifier, NONE for no bonus. If used, will make the affected player gift the specified bonus to the other player. As such, it can only be used with events that affect two players.
PlotExtraYields- if non-empty, contains information that modifies the yields of the affected plot. Format is as follows:
[xml]
YIELD_COMMERCE
1
[/xml]
The above would add 1 commerce to the affected plot.
iConvertOwnCities- is a number. Specifies the number of the player’s cities that will be converted to the trigger religion, the religion being added to the city if not already present. The religion is determined in event triggers.
iConvertOtherCities- is a number. Specifies the number of foreign cities that will be converted to the trigger religion. The religion is determined in event triggers.
iMaxNumReligions- is a number. Specifies the maximum amount of religions that may be present in a city in order for it to be converted by either or . If you wish to ignore the amount of religions already in the city, set this variable to -1.
iOurAttitudeModifier- is a number. Specifies the attitude modifier of the affected player towards the other player.
iAttitudeModifier- is a number. Specifies the attitude modifier of the other player towards the affected player.
iTheirEnemyAttitudeModifier- is a number. Specifies the attitude modifier of the affected player towards the other player’s worst enemy and vice versa. For example, if set to -1, Civ A is the affected player and Civ B is the other player, then Civ A will have -1 towards Civ B’s worst enemy and Civ B’s worst enemy will also have a -1 modifier towards Civ A.
iPopulationChange- is a number. Specifies the population change in the city – negative numbers indicate population loss. If is 0, the change will apply to the entire civ. If is 1, only the affected city’s population will be modified.
AdditionalEvents- if non-empty, specifies extra events that will have a chance of occuring if that event happens. For example,
[xml]
EVENT_AIRLINER_CRASH_4
50
[/xml]
means that EVENT_AIRLINER_CRASH_4 will be triggered with a likelihood of 50%.
EventTimes- if non-empty, it can be used to set up delayed events. Has to be used along with above. Fill as follows:
[xml]
EVENT_MOTOR_OIL_1
5
[/xml]
In case the event filled in does not trigger due to the random roll, the event timer will kick in, making it occur later.
ClearEvents- if non-empty, specifies the events which get reset and the probability of that happening. For example:
[xml]
EVENT_DUSTBOWL_2
100
[/xml]
This resets the EVENT_DUSTBOWL_2 unconditionally, which means that the event is considered to not have occurred.
PythonCallback- If non-empty, specifies the Python function that is called when the event occurs. See the section on Python for more information.
PythonExpireCheck- if non-empty, specifies the Python function that is called to check whether the event expires. See the section on Python for more information.
PythonCanDo- If non-empty, specifies the Python function that is called to verify whether the event can be triggered. See the section on Python for more information.
PythonHelp- If non-empty, specifies the Python function that generates the help text for this event. See the section on Python for more information.
Button- Specifies the art file which is displayed as the event’s button.
iAIValue- is a number. Reflects the AI trigger value for this event.
-------------------------------
Intro
Random events are one of the new features in Civ4: Beyond the Sword. The game ships with over 150 events, which vary from happiness and diplomatic bonuses to free promotions and technological breakthroughs. The event system provides a great foundation for modders to build open, as all events can be modded and new ones can be added.
You can create a wide array of possible events through XML modding only, but events can also be enhanced by Python for more versatility. The last section of this guide has some examples of events that can be modded in. The events described therein, along with some others, can be found in an event mod created by me. Think of the mod as an addendum to this guide, if you will. It can be found here.
The basics
It’s important to understand the two basic building blocks of the event system – triggers and events. “Triggers” are a collection of parameters indicating conditions when they can activate. So, triggers check whether you have the required technologies, population, etc. If the trigger’s conditions are met, it has a chance of activating. When a trigger is activated, it gives the player choice between one or more “events” (well, when there is only one event, there’s no choice). Events themselves are what provides the specific results that then affect the player.
Players may be inclined to think of the event system as consisting of “events”and “choices” – that’s not really accurate. Every choice is a separate event, and a trigger is what gives those choices.
As most other things in Civ4, events are primarily handled in the SDK. Events are described by the CvEventInfo class, which mimics the XML description of events. Below is the description of event tags in the XML file. If you can read C++, you may want to take a look at the definition of CvEventInfo. The correspondence between member functions of that class and the XML values should be fairly obvious.
Event triggers are kept in Civ4EventTriggerInfos.xml and that file, along with triggers in general, will be described after the event description explanations.
Civ4EventInfos.xml
Assets\XML\Events\Civ4EventInfos.xml is the main file describing all the in-game events. This section will describe the tags in that file, explaining their meaning.
Type- this is the event type identifier. Takes the form of EVENT_NAME
Description- identifier of the text string which contains the event description. Typically takes the form of TXT_KEY_EVENT_NAME, and description text strings can be found in Assets\XML\Text\Civ4GameText_Events_BTS.xml
LocalInfoText- identifier of the text string, if any, to be shown to the affected player.
WorldNewsTexts- specifies text, if any, to be shown to every player in the world (who has met the affected civilization) when the event occurs.
OtherPlayerPopup- specifies text, if any, to show in a popup to the other player affected. In BtS, is used for the Partisans event.
QuestFailText- specifies text, if any, to be displayed if the quest has been failed. Obviously, used for quests.
bQuest- can be either 0 or 1. If set to 1, then the event is actually a quest.
bGlobal- can be either 0 or 1. If set to 1, then the event will apply to all players. That is used for events that complete a quest in order to reset it for every player.
bTeam- can be either 0 or 1. If set to 1, then it will apply to all players on the same team. It’s not used in any of the events shipping with BtS.
bPickCity- can be either 0 or 1. If set to 1, then the event affects a city of the player for whom the event was triggered.
bPickOtherPlayerCity- can be either 0 or 1. If set to 1, the event affects a foreign city. For example, you can be given the choice of spending some espionage points to worsen the effects this event deals to the foreign city. Used in conjunction with
bDeclareWar- can be either 0 or 1. If set to 1, will cause the affected player and the other player to go to war.
iGold- is a number. Specifies the base amount of gold that the affected player gains. If set to a negative number, the player will lose the gold. Can also optionally affect the other player – see below.
bGoldToPlayer- can be either 0 or 1. Works in conjunction with
iRandomGold- is a number. Specifies the cap for an extra random amount of gold that is added to iGold to produce the total amount of gold.
iCulture- is a number. Specifies the amount of culture to be added to a city – only useful for events targeting a city.
iEspionagePoints- is a number. Specifies the amount of espionage points that the affected player will gain towards the other player.
bGoldenAge- can be either 0 or 1. If set to 1, triggers a golden age for the affected player.
iFreeUnitSupport- is a number. Specifies how many extra free units the player is allowed to support.
iInflationMod- is a number. Specifies by how much the affected player’s inflation modifier is changed.
iSpaceProductionMod- is a number. Specifies by how much the player’s spaceship part production modifier is changed. A value of 10, for example, would speed SS production up by 10%.
Tech- is a technology identifier. NONE for no technology. If set, explicitly specifies a technology towards which you can gain beakers.
TechFlavors- if not empty, contains one or more flavor types. For events that result in progress towards a technology, flavors affect which technology will be picked. For example, FLAVOR_RELIGION with a value of 1 will make you more likely to have progress towards a religious technology.
iTechPercent- is a number. Specifies by how many percent closer the player will become to the technology. The technology can be set explicitly (see
iTechCostPercent- is a number. Specifies how many percent of the technology’s beaker cost to convert to a gold value.
iTechMinTurnsLeft- is a number. Specifies that the event may only affect techs for which the player needs at least this many turns to research. For example, setting to 2 for an event that advances research progress would mean that progress won’t be advanced for a tech that you’re about to complete in 2 turns.
PrereqTech- is a technology identifier. NONE for no technology. If set, then the technology is required for this event. Used to create event choices that the player can not pick unless he has the tech.
UnitClass- is a unit class identifier. NONE for no unit class. Specifies a unit class for receiving free units – see below.
iNumFreeUnits- is a number. Specifies how many free units of the class given in
bDisbandUnit- can be either 0 or 1. If set to 1, disbands (kills) the affected unit.
iUnitExperience- is a number. Specifies the amount of free XP received by the affected unit.
iUnitImmobileTurns- is a number. Specifies the number of turns that the affected unit will remain immobile. Immobile units can still defend.
UnitPromotion- is a promotion identifier. For events that affect a specific unit (as determined by the trigger), can be used to apply a promotion to that specific unit. It’s not used in BtS, however – instead, Python callbacks are used (example: the Champion event).
UnitName- is a text string identifier. If specified, will set the affected unit’s name to the specified string.
UnitCombatPromotions- if non-empty, contains free promotions that all units of a selected combat type receive. Format to fill is as follows:
[xml]
[/xml]
The above would give all archery units a free Combat I promotion.
UnitClassPromotions- similar to above. If non-empty, contains free promotions for all units of a selected unit class to receive. Format as follows:
[xml]
[/xml]
That would give all Axeman-class units Shock.
BuildingClass- is a building class identifier. NONE for no building. Explicitly gives a building class to be affected by the event. Used with
iBuildingChange- is a number. Specifies how many buildings of the class specified in
BuildingExtraYields- if non-empty, contains information that modifies yield given by a building. For example, a building can be made to produce extra food or hammers. Format to fill as follows:
[xml]
[/xml]
The above would give your Harbours 2 extra commerce. If
BuildingExtraCommerces- similar to above, if non-empty, contains information tat modifies commerce outputs given by a building. Note that this is not for pure commerce (to change that, use BuildingExtraYields and YIELD_COMMERCE as per the above example), but rather for commerce types – research, culture, gold or espionage. Format to fill as follows:
[xml]
[/xml]
The above would add 1 gold to the output of your Markets. Just as with the
BuildingExtraHappies- another similar tag, if non-empty, assigns extra happiness to buildings. Format as follows:
[xml]
[/xml]
That’s to add 1 happiness to a Theatre. Once again, if
BuildingExtraHealths- works just like
[xml]
[/xml]
That would give +1 health to your Hospitals. If
iHappy- is a number. Specifies extra happiness to give. If
iHealth- is a number. Specifies extra health to give. If
iHurryAnger- is a number. Specifies extra whipping unhappiness to give. Unhappy citizens created by events using this variable will have the “We can not forget your cruel oppression!” unhappiness. You can be extra evil by setting
iHappyTurns- is a number. Specifies the amount of turns to give temporary happiness. The amount of happy faces given is specified in Assets\XML\GlobalAssets.xml as the TEMP_HAPPY variable. It defaults to 1 in BtS. Therefore, setting
iRevoltTurns- is a number. Specifies the amount of turns that the city will spend in revolt (no production, etc., like newly captured cities). Must be city-targeted, that is, used in conjunction with
iMinPillage- is a number. Specifies the minimum amount of terrain improvements that will be pillaged (removed). If used with a city-targeting event, then the pillaged improvement will be in the city’s radius. If the event doesn’t target a city, the improvement may be anywhere.
iMaxPillage- is a number. Specifies the maximum amount of terrain improvement that will be pillaged(removed). Works in conjunction with
iFood- is a number. Specifies the amount of stored food to be added in a city. If
iFoodPercent- is a number. Specifies by how many percent to modify the stored food in a city. You can remove all the stored food by setting this value to -100. If
FreeSpecialistCounts- if non-empty, describes the free specialists added to a city. Can only be used with events that target a city. Format is as follows:
[xml]
[/xml]
That would add a free Scientist to the city.
FeatureType- is a feature type identifier, NONE for no feature types. Sets the feature type that the event will add or remove in a plot, used in conjunction with
iFeatureChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the feature described in
ImprovementType- is an improvement type identifier, NONE for no improvement. Sets the improvement type that the event will add or remove in a plot, used in conjunction with
iImprovementChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the improvement described in
BonusType- is a bonus (resource) type identifier, NONE for no bonus. Sets the bonus type that the event will add or remove in a plot, used in conjunction with
iBonusChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the bonus described in
RouteType- is a route type identifier, NONE for no route. Sets the route type that the event will add or remove in a plot, used in conjunction with
iRouteChange- is a number. If used, should only take the values of 1 or -1. Setting to 1 would add the route described in
BonusRevealed- is a bonus type identifier, NONE for no bonus. If used, will reveal the specified bonus to the affected player, even if he has no technology to normally see the bonus.
BonusGift- is a bonus type identifier, NONE for no bonus. If used, will make the affected player gift the specified bonus to the other player. As such, it can only be used with events that affect two players.
PlotExtraYields- if non-empty, contains information that modifies the yields of the affected plot. Format is as follows:
[xml]
[/xml]
The above would add 1 commerce to the affected plot.
iConvertOwnCities- is a number. Specifies the number of the player’s cities that will be converted to the trigger religion, the religion being added to the city if not already present. The religion is determined in event triggers.
iConvertOtherCities- is a number. Specifies the number of foreign cities that will be converted to the trigger religion. The religion is determined in event triggers.
iMaxNumReligions- is a number. Specifies the maximum amount of religions that may be present in a city in order for it to be converted by either
iOurAttitudeModifier- is a number. Specifies the attitude modifier of the affected player towards the other player.
iAttitudeModifier- is a number. Specifies the attitude modifier of the other player towards the affected player.
iTheirEnemyAttitudeModifier- is a number. Specifies the attitude modifier of the affected player towards the other player’s worst enemy and vice versa. For example, if set to -1, Civ A is the affected player and Civ B is the other player, then Civ A will have -1 towards Civ B’s worst enemy and Civ B’s worst enemy will also have a -1 modifier towards Civ A.
iPopulationChange- is a number. Specifies the population change in the city – negative numbers indicate population loss. If
AdditionalEvents- if non-empty, specifies extra events that will have a chance of occuring if that event happens. For example,
[xml]
[/xml]
means that EVENT_AIRLINER_CRASH_4 will be triggered with a likelihood of 50%.
EventTimes- if non-empty, it can be used to set up delayed events. Has to be used along with
[xml]
[/xml]
In case the event filled in
ClearEvents- if non-empty, specifies the events which get reset and the probability of that happening. For example:
[xml]
[/xml]
This resets the EVENT_DUSTBOWL_2 unconditionally, which means that the event is considered to not have occurred.
PythonCallback- If non-empty, specifies the Python function that is called when the event occurs. See the section on Python for more information.
PythonExpireCheck- if non-empty, specifies the Python function that is called to check whether the event expires. See the section on Python for more information.
PythonCanDo- If non-empty, specifies the Python function that is called to verify whether the event can be triggered. See the section on Python for more information.
PythonHelp- If non-empty, specifies the Python function that generates the help text for this event. See the section on Python for more information.
Button- Specifies the art file which is displayed as the event’s button.
iAIValue- is a number. Reflects the AI trigger value for this event.
Comment