Template:事件

[阅读] [编辑]Template-info.png 模板文档


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
icon_type Event icon, without "Event" prefix or .png "default" optional
header Header level, for Table of Contents h3 optional
cond_event_text Set to "yes" if the event has multiple descriptions available for use. empty optional
event_text In-game description text of the event. If multiple descriptions exist then use only the first one. empty optional, but desired
flavor_text Additional in-game description text of the event. Always collapsed empty optional, but desired
triggered by To specify the trigger of the event. empty required
trigger Trigger conditions of the event.
  • None
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 start collapsed.

(Please use collapsed content on country pages.)

empty optional

Usage

{{事件
|版本 = 
|id = <!-- optional, but desired -->
|icon_type = <!-- optional, but desired -->
|标题 = 
|事件文本 = <!-- optional, but desired -->
|趣味文本 = <!-- optional, but desired -->
|触发 = 
|触发于 = 
|即时效果 = <!-- optional, for immediate effects -->
|选项 = <!-- use {{option}} template -->
}}

Examples

{{Event
|collapse = no
|version = 1.1
|event_id = texan_war_of_independence.3
|event_name = General Santa Anna Captured
|event_text = Antonio López de Santa Anna, the ruler of Mexico and one of its leading generals, has been captured in a swamp wearing a dragoon's uniform by our forces. He is offering to immediately sign a peace with us in exchange for his release.
|flavor_text = "Santa Anna, alive, can be of incalculable benefit to Texas; Santa Anna, dead, would just be another casualty."
|trigger =
*Is Texas
*Texas is the aggressor against Mexico in a diplomatic play
*Mexico is AI and has Santa Anna as a character
|triggered by = 
*Winning a battle
|options = 
{{option
|option_text=Use Santa Anna to press for a deal.
|effect=
*Texas and Mexico sign a white peace}}
{{option|option_text=Let him run back to Mexico, we fight on!}}
}}

will display:

id

Event default.png General Santa Anna Captured

Antonio López de Santa Anna, the ruler of Mexico and one of its leading generals, has been captured in a swamp wearing a dragoon's uniform by our forces. He is offering to immediately sign a peace with us in exchange for his release.
 趣味文本:
"Santa Anna, alive, can be of incalculable benefit to Texas; Santa Anna, dead, would just be another casualty."

 
触发于:
  • Winning a battle
触发条件:
  • Is Texas
  • Texas is the aggressor against Mexico in a diplomatic play
  • Mexico is AI and has Santa Anna as a character

Event button.png
{{{选项文本}}}
Event button.png
{{{选项文本}}}

Event with conditional options

The following code

{{Event
|collapse = no
|version = 1.1
|event_id = texan_war_of_independence.1
|event_name = The Lone Star State
|event_text = Texas stands, after a hard-fought and bloody war, independent. There are many within the Republic that advocate for statehood within the United States of America. The Americans, by all accounts, would welcome us into their union.
|flavor_text = The war with Mexico has ended, and our brave citizens have begun to lay down their arms and return to peacetime life. But what good is independence if we must spend every day watching our backs, waiting for the return of our oppressors? Texas can be stronger still as part of a greater union, one of like-minded states that will not infringe upon our God-given rights.
|triggered by =
*Journal Entry Completion: ''Texan Independence''
|option conditions = yes
|options = 
{{option
|trigger=Is AI
|option_text=We'll join the union!
|effect=
*Texas is annexed by the USA}}
{{option
|trigger=always
|option_text=Full statehood is unnecessary.
|effect=
*Texas becomes a dominion of the USA}}
{{option
|trigger=always
|option_text=We don't need help from the Yankees.
|effect=
*The USA gains a claim on the state of Texas.
*Texas gets {{green|+20%}} prestige for 5 years.
|end}}
}}
id

Event default.png The Lone Star State

Texas stands, after a hard-fought and bloody war, independent. There are many within the Republic that advocate for statehood within the United States of America. The Americans, by all accounts, would welcome us into their union.
 趣味文本:
The war with Mexico has ended, and our brave citizens have begun to lay down their arms and return to peacetime life. But what good is independence if we must spend every day watching our backs, waiting for the return of our oppressors? Texas can be stronger still as part of a greater union, one of like-minded states that will not infringe upon our God-given rights.

 
触发于:
  • Journal Entry Completion: Texan Independence
触发条件:

选择条件:
Event button.png
{{{选项文本}}}
Event button.png
{{{选项文本}}}
Event button.png
{{{选项文本}}}