Event can be used to diplay description, trigger, trigger condition and options of an event in a compact infobox.
Parameter
Parameter | Description | Default | Status |
---|---|---|---|
version | To specify the major patch for which the event was written or updated. | empty | required |
event_id | Event identification code as it appears in the file to serve as an anchor | empty | optional |
event_name | Title of the event. | empty | required |
event_text | Ingame description text of the event. | empty | One of these two is optional, but desired |
cond_event_text | Ingame descriptions of the event, with their attached conditions. The text itself should be set in italics. | empty | |
mtth | Mean time to happen, including both the base weight and its modifiers. For MTTH-events this is the number of months after which there is a 50% chance that it triggers. For triggered-only events triggered by event pulses it determines how likely that event is to happen on that pulse. | empty | One of theses two is required. |
triggered only | To specify the trigger of 'triggered only' events. | empty | |
trigger | Trigger conditions of the event. |
|
optional |
immediate | The immediate effects of the event. | empty | optional |
option conditions | If set to ‘yes’ the section heading 'Option conditions' for events with conditional options is displayed. | empty | optional |
options | The possible effects of the event. Please use {{option}} .
|
empty | required |
collapse | Whether to collapse the event. If set to ‘yes’ the content will be collapsed. (Please use collapsed content on country pages.) |
empty | optional |
after | Any effects after selecting an option. | empty | optional |
Usage
{{Event |version = |event_id = |event_name = |event_text = <!-- optional, but desired --> |trigger = |mtth = <!-- for Mtth events --> |triggered only = <!-- for triggered only events --> |immediate = <!-- optional for immediate effects --> |options = <!-- options use {{option}} template --> }}
Note: Please use either “mtth”-parameter or “triggered only”-parameter.
Examples
MTTH event
The following code
{{event |version = 1.8 |event_id = flavor_tur.3374 |event_name = Mimar Sinan's Great Constructions |event_text = Mimar Sinan planned and oversaw the construction of countless mosques, aqueducts, bathhouses, bridges, palaces, caravanserais and schools during his half-a-century long career. His masterpieces were the Selimiye and Suleymaniye Mosques in Adrianople and Constantinople respectively. |trigger = *Event has not yet occurred. *The year is between 1519 and 1560. *owns Constantinople (151). *The advisor ‘Mimar Sinan’ does ''not'' exist. |mtth = 1000 months |options = {{option |option_text = Appoint him royal architect |effect = *the modifier “Mimar Sinan” until the death of the current ruler, giving the following effect: **{{icon|build cost}} {{green|−15.0%}} Build cost }} {{option |option_text = Enlist his services for a short time |effect = *{{icon|Adm}} {{green|+40}} Administrative power }} }}
will display:
Mimar Sinan's Great Constructions
这条信息可能已不适合当前版本,最后更新于1.8。 |
Mimar Sinan planned and oversaw the construction of countless mosques, aqueducts, bathhouses, bridges, palaces, caravanserais and schools during his half-a-century long career. His masterpieces were the Selimiye and Suleymaniye Mosques in Adrianople and Constantinople respectively.
触发条件
|
平均发生时间
1000 months |
Appoint him royal architect
Enlist his services for a short time |
Triggered only event
The following code
{{event |version = 1.8 |event_id = ideagroups.100 |event_name = Loss of Stability |event_text = This strengthening of the privileges of the nobles is severely upsetting the burghers and merchants. This is creating turmoil in our realm, and may prove disastrous in the long run. |trigger = *has the [[idea group]]: Aristocratic ideas. *has a [[stability]] of at least 0. |triggered only = *the five year pulse '''Base weight: 1''' |options = {{option |option_text = Well, they are just peasants. |effect = *{{icon|stability}} {{red|–1}} Stability }} }}
will display:
Loss of Stability
这条信息可能已不适合当前版本,最后更新于1.8。 |
This strengthening of the privileges of the nobles is severely upsetting the burghers and merchants. This is creating turmoil in our realm, and may prove disastrous in the long run.
触发条件
|
只触发于
Base weight: 1 |
Well, they are just peasants. |
Event with conditional options
The following code
{{Event |version = 1.13 |event_id = flavor_azt.2 |event_name = Reactions to Pyramid Project |event_text = Much as we suspected not all of the cities under our control have welcomed the chance to put all of their resources at our disposal, and it seems clear that we will have to carry a larger part of the costs than we had hoped. |trigger = This event has not fired before. |triggered only = the event [[#The Great Pyramid of Tenochtitlan|The Great Pyramid of Tenochtitlan]] − option “All our subjects must contribute to the Pyramid!”. |option conditions=yes |options ={{option |trigger = Aztec has at least 2 provinces with the modifier ''“Contributing to the Great Temple”'' |option_text = Ok. |effect = ''The great contributions we have received have resulted in an impressive addition to the Pyramid.''<br> {{flag|Aztec}}: *loses {{icon|adm|24px}}{{red|25}} Administrative power *loses {{icon|dip|24px}}{{red|25}} Diplomatic power *gains {{icon|prestige|24px}}{{green|10}} Prestige *gains {{icon|small legitimacy|24px}}{{green|25}} Legitimacy Mexico (852) gets the modifier ''“Great Temple of Tenochtitlan”'' for the rest of the campaign with the following effect: *{{icon|prestige|24px}}{{green|+1}} Yearly prestige Every Aztec province with the modifier ''“Contributing to the Great Temple”'' loses it. }} {{option |trigger = Aztec has exactly 1 province with the modifier ''“Contributing to the Great Temple”'' |option_text = Ok. |effect = ''The contributions from our provinces have paid for part of the new Pyramid.''<br> {{flag|Aztec}}: *loses {{icon|adm|24px}}{{red|35}} Administrative power *loses {{icon|dip|24px}}{{red|35}} Diplomatic power *gains {{icon|prestige|24px}}{{green|5}} Prestige *gains {{icon|small legitimacy|24px}}{{green|5}} Legitimacy Mexico (852) gets the modifier ''“Great Temple of Tenochtitlan”'' for the rest of the campaign with the following effect: *{{icon|prestige|24px}}{{green|+1}} Yearly prestige Every Aztec province with the modifier ''“Contributing to the Great Temple”'' loses it. }} {{option |trigger = Aztec does ''not'' have a province with the modifier ''“Contributing to the Great Temple”'' |option_text = Ok. |effect = ''The Pyramid is effectively paid for by only the central government and other city states in its immediate surroundings.''<br> {{flag|Aztec}} country: *loses {{icon|adm|24px}}{{red|75}} Administrative power *loses {{icon|dip|24px}}{{red|75}} Diplomatic power Mexico (852) gets the modifier ''“Great Temple of Tenochtitlan”'' for the rest of the campaign with the following effect: *{{icon|prestige|24px}}{{green|+1}} Yearly prestige |end }} }}
will display:
Reactions to Pyramid Project
这条信息可能已不适合当前版本,最后更新于1.13。 |
Much as we suspected not all of the cities under our control have welcomed the chance to put all of their resources at our disposal, and it seems clear that we will have to carry a larger part of the costs than we had hoped.
触发条件
This event has not fired before. |
只触发于
the event The Great Pyramid of Tenochtitlan − option “All our subjects must contribute to the Pyramid!”. |
选择条件
满足则可用: Aztec has at least 2 provinces with the modifier “Contributing to the Great Temple”Ok. The great contributions we have received have resulted in an impressive addition to the Pyramid. Mexico (852) gets the modifier “Great Temple of Tenochtitlan” for the rest of the campaign with the following effect: Every Aztec province with the modifier “Contributing to the Great Temple” loses it. 满足则可用: Aztec has exactly 1 province with the modifier “Contributing to the Great Temple”Ok. The contributions from our provinces have paid for part of the new Pyramid. Mexico (852) gets the modifier “Great Temple of Tenochtitlan” for the rest of the campaign with the following effect: Every Aztec province with the modifier “Contributing to the Great Temple” loses it. 满足则可用: Aztec does not have a province with the modifier “Contributing to the Great Temple”Ok. The Pyramid is effectively paid for by only the central government and other city states in its immediate surroundings. Mexico (852) gets the modifier “Great Temple of Tenochtitlan” for the rest of the campaign with the following effect: |