Wiki

effect · create_production_license

Definition

  • Supported scope:COUNTRY
  • Supported target:none

Description

Creates an equipment production license. If the selection criteria fails to match a variant no license will be created.
Example:
create_production_license = {
	target = TAG # Receiver of the license.
	cost_factor = 1.0 # Optional. Cost factor for production of the equipment.
	new_prioritised = no # Optional. Default yes. Ignore 'version' (but not 'version_name') below and instead select the latest variant.
	equipment = {
		type = small_plane_naval_bomber_airframe # The type of the variant to select. Must be specified.
		version = 1 # Optional. Default 0. Select the variant with the given version.
		version_name = "Do 22" # Optional. Select the variant with the given name.
	}
}

实战 · 配合 · 坑

实战内容由 AI 生成,并已对照 vanilla 命令词表校验 —— 请当作起点而非权威依据。上方的定义节才是游戏自带文档原文。

实战用法

create_production_license 常用于外交或科技事件中,让一国向另一国授权生产某款装备变体,例如小国从大国购买飞机或坦克的生产许可。典型场景是当玩家完成某个外交焦点后,自动向盟友提供武器生产授权。

# 德国向匈牙利授予 Do 22 型飞机的生产许可
GER = {
    create_production_license = {
        target = HUN
        cost_factor = 0.75
        new_prioritised = no
        equipment = {
            type = small_plane_naval_bomber_airframe
            version_name = "Do 22"
        }
    }
}

配合关系

  • [has_any_license](/wiki/trigger/has_any_license):在授权前检查目标国是否已持有该许可,避免重复授权造成逻辑混乱。
  • [create_equipment_variant](/wiki/effect/create_equipment_variant):通常先用此命令在授权方国家创建装备变体,再用 create_production_license 将该变体授出,确保 version_name 能正确匹配。
  • [add_opinion_modifier](/wiki/effect/add_opinion_modifier):授权后叠加外交好感度修正,模拟因技术转让带来的关系改善。
  • [diplomatic_relation](/wiki/effect/diplomatic_relation):与生产许可一同使用,搭建更完整的军事合作框架(如设置军事通行权或附庸关系)。

常见坑

  1. 变体不存在导致许可静默失败:若 version_nameversion 在授权方国家找不到匹配的装备变体,游戏不会报错,许可直接不创建。务必先通过 create_equipment_variant 或确认内置变体确实存在,再调用本命令。
  2. new_prioritisedversion/version_name 的优先级混淆new_prioritised = yes(默认值)会忽略 version 字段而选取最新变体,但仍会匹配 version_name;若同时填写了 version 却忘记关闭 new_prioritisedversion 将被静默忽略,导致授权的不是预期版本。

Hands-On Notes

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.

Hands-On Usage

create_production_license is commonly used in diplomatic or technology events to grant one nation the production rights to an equipment variant from another nation. Typical scenarios include smaller nations purchasing production licenses for aircraft or tanks from larger powers. A classic case is when the player completes a diplomatic focus and automatically grants production licenses to allies.

# Germany grants Hungary a production license for the Do 22 aircraft
GER = {
    create_production_license = {
        target = HUN
        cost_factor = 0.75
        new_prioritised = no
        equipment = {
            type = small_plane_naval_bomber_airframe
            version_name = "Do 22"
        }
    }
}

Synergy

  • [has_any_license](/wiki/trigger/has_any_license): Check whether the target nation already holds the license before granting it to avoid logical conflicts from duplicate licenses.
  • [create_equipment_variant](/wiki/effect/create_equipment_variant): Typically use this command first to create the equipment variant in the granting nation's technology tree, then use create_production_license to grant that variant. This ensures the version_name matches correctly.
  • [add_opinion_modifier](/wiki/effect/add_opinion_modifier): Stack diplomatic opinion modifiers after granting the license to simulate improved relations from technology transfer.
  • [diplomatic_relation](/wiki/effect/diplomatic_relation): Use alongside production licenses to establish a more comprehensive military cooperation framework (such as setting military access rights or vassal relationships).

Common Pitfalls

  1. License creation fails silently due to missing variant: If the version_name or version cannot find a matching equipment variant in the granting nation, the game will not produce an error—the license simply will not be created. Always ensure the variant exists through create_equipment_variant or verify that a built-in variant actually exists before calling this command.
  2. Priority confusion between new_prioritised and version/version_name: Setting new_prioritised = yes (the default value) will ignore the version field and select the newest variant instead, but will still match version_name. If you fill in version but forget to disable new_prioritised, the version will be silently ignored, resulting in granting a production license for an unintended variant.