﻿# 子入口定义
# 每年发展度检测
qing_htool_ai_building_yearly_global_pulse = {
    effect = {
		if = {
			limit = {
				has_game_rule = qing_htool_ai_main_switch_building_slot_add_development_on
			}
			every_province = {
				county = {
					save_scope_as = target_county
				}
				if = {
					limit = {
						exists = province_owner
						province_owner = {
							is_ai = yes
						}
					}
					if = {
						limit = {
							NOT = { has_variable = qing_htool_building_slot_development_information_count }
						}
						set_variable = {
							name = qing_htool_building_slot_development_information_count
							value = 0
						}
					}
					if = {
						limit = {
							var:qing_htool_building_slot_development_information_count < qing_htool_ai_building_slot_add_development_count_value
						}
						add_province_modifier = {
							modifier = qing_htool_building_slot_add_modifier
						}
						change_variable = {
							name = qing_htool_building_slot_development_information_count
							add = 1
						}
					}
				}
			}
		}
    }
}