trigger · has_intelligence_agency
Definition
- Supported scope:
COUNTRY - Supported target:
THIS,ROOT,PREV,FROM,OWNER,CONTROLLER,OCCUPIED,CAPITAL
Description
has country created an Intelligence Agency
has_intelligence_agencyCOUNTRYTHIS, ROOT, PREV, FROM, OWNER, CONTROLLER, OCCUPIED, CAPITALhas country created an Intelligence Agency
Hands-on notes are AI-generated and checked against the vanilla command vocabulary — treat them as a starting point, not authoritative reference. The definition above is the game's own documentation.
has_intelligence_agency is commonly used to check whether a player or AI nation has established an intelligence agency, thereby unlocking subsequent intelligence-related decisions, focus trees, or advisor options. For example, you can set a prerequisite condition in the available block of a decision to ensure the player must establish an intelligence agency before executing espionage-related content.
# Example: A decision requiring the nation to have established an intelligence agency
my_spy_decision = {
available = {
has_intelligence_agency = yes
}
...
}
[create_intelligence_agency](/wiki/effect/create_intelligence_agency): The most direct pairing—first use has_intelligence_agency = no as a conditional check, then create the intelligence agency via this effect to avoid duplicate creation that could cause script errors or logic confusion.[agency_upgrade_number](/wiki/trigger/agency_upgrade_number): After confirming the intelligence agency exists, further check the upgrade count; the two are often nested together to unlock content in tiers.[has_done_agency_upgrade](/wiki/trigger/has_done_agency_upgrade): When combined with this trigger, you can establish a dual threshold of "agency established + specific upgrade completed," used for advanced espionage events or decision available checks.[any_operative_leader](/wiki/trigger/any_operative_leader): After confirming the intelligence agency exists, check whether the nation has operative personnel; commonly seen in comprehensive conditional blocks that determine whether a nation's spy network is operationally capable.has_intelligence_agency = no in the prerequisites of a create_intelligence_agency effect, causing the script to attempt creating an agency for nations that already have one, triggering silent errors or agency data corruption; always use this trigger as a protective check first.any_allied_country / any_neighbor_country, the trigger automatically switches to the child nation scope and requires no manual target specification; beginners often add the ROOT:has_intelligence_agency syntax by mistake, resulting in checking the root nation instead of the loop target.