Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
hathaway682 committed Sep 23, 2022
2 parents 1ca317c + c32af2d commit 9de6610
Show file tree
Hide file tree
Showing 7 changed files with 126 additions and 26 deletions.
6 changes: 6 additions & 0 deletions common/edicts/00_communists_edicts.txt
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,12 @@ speed_of_people = {
category = campaigns
upkeep = {
unity = 0.6
multiplier = trigger:num_pops
}
}
resources = {
category = campaigns
upkeep = {
minerals = 0.4
multiplier = trigger:num_pops
}
Expand Down
65 changes: 61 additions & 4 deletions common/scripted_modifiers/ethic_scripted_modifiers.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,26 +26,83 @@ trade_value_reduction = {
category = planet
}

economic_situation_improve_add = {
rec_situation_improve_add = { # 不推荐使用,请使用有更多后缀版本
icon = mod_cat_economy
good = yes
category = country
}
rec_civic_situation_improve_add = { # 来自体制的经济改善,无危机时
icon = mod_cat_economy
good = yes
category = country
}
rec_crisis_civic_situation_improve_add = { # 来自体制的经济改善,有危机时
icon = mod_cat_economy
good = no
category = country
}
rec_edict_situation_improve_add = { # 来自法令的经济改善,不区分危机与否
icon = mod_cat_economy
good = yes
category = country
}

economic_crisis_accumulate_add = {
rec_crisis_accumulate_add = { # 不推荐使用,请使用有更多后缀版本
icon = mod_cat_economy
good = no
category = country
}
economic_crisis_accumulate_decline = {
rec_civic_crisis_accumulate_add = { # 来自体制的危机积累,无危机时
icon = mod_cat_economy
good = no
category = country
}
rec_crisis_civic_crisis_accumulate_add = { # 来自体制的危机积累,有危机时
icon = mod_cat_economy
good = no
category = country
}
rec_edict_crisis_accumulate_add = { # 来自法令的危机积累,不区分危机与否
icon = mod_cat_economy
good = no
category = country
}

rec_crisis_accumulate_mult = { # 不推荐使用,请使用有更多后缀版本 (实际上也不能用)
icon = mod_cat_economy
percentage = yes
cap_zero_to_one = yes
good = yes
category = country
}
rec_civic_crisis_accumulate_mult = { # 来自体制的积累乘数,无危机时 (实际上也不能用)
icon = mod_cat_economy
percentage = yes
cap_zero_to_one = yes
good = yes
category = country
}
rec_crisis_civic_crisis_accumulate_mult = { # 来自体制的积累乘数,有危机时 (实际上也不能用)
icon = mod_cat_economy
percentage = yes
cap_zero_to_one = yes
good = yes
category = country
}
rec_edict_crisis_accumulate_mult = { # 来自法令的积累乘数,不区分危机与否 (实际上也不能用)
icon = mod_cat_economy
percentage = yes
cap_zero_to_one = yes
good = yes
category = country
}

economic_crisis_threshold_add = {
rec_crisis_threshold_add = { # 危机阈值增加,无危机时
icon = mod_cat_economy
neutral = yes
category = country
}
rec_incrisis_crisis_threshold_add = { # 危机阈值增加,有危机时
icon = mod_cat_economy
neutral = yes
category = country
Expand Down
11 changes: 5 additions & 6 deletions common/static_modifiers/00_pop_static_modifiers.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ planet_stability_no_happiness_low = {
pop_growth_speed_reduction = 0.15
pop_amenities_usage_mult = 0.15
planet_emigration_push_mult = 0.65
planet_crime_no_happiness_mult = 0.45

planet_crime_no_happiness_mult = 0.15
}

#稳定度高(格式塔)
Expand All @@ -58,7 +57,7 @@ planet_stability_no_happiness_high = {
planet_stability_low = {
planet_jobs_produces_mult = -0.65
pop_growth_speed_reduction = 0.4
pop_amenities_usage_mult = 0.4
pop_amenities_usage_mult = -0.5 #低稳定度下减少生活预期
planet_emigration_push_mult = 1
trade_value_mult = -0.8
planet_crime_mult = 0.35
Expand Down Expand Up @@ -125,7 +124,7 @@ planet_amenities_high = {
# 住房 ( 25% - 200% of required)
#拥挤(格式塔)
planet_housing_no_happiness_low = {
planet_stability_add = -5
#planet_stability_add = -5
pop_amenities_usage_mult = 1.85
}

Expand All @@ -137,8 +136,8 @@ planet_housing_no_happiness_high = {

#拥挤
planet_housing_low = {
planet_stability_add = -10
pop_amenities_usage_mult = 0.85
#planet_stability_add = -10
pop_amenities_usage_mult = 0.75
planet_immigration_pull_mult = -0.65
planet_emigration_push_mult = 0.45
pop_growth_speed_reduction = 0.65
Expand Down
22 changes: 19 additions & 3 deletions events/ethic_economic.txt
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,14 @@ situation_event = { # 计算情况改善-国策基础 6号
hide_window = yes
immediate = {
set_variable = { which = rec_situation_add_civic_temp value = 0 } # 初始化经济情况改善 - 国策基础
if = { # 加载scripted_modifier
limit={ has_situation_flag = economic_crisis }
change_variable = { which = rec_situation_add_civic_temp value = owner.modifier:rec_incrisis_civic_situation_improve_add }
}
else = {
change_variable = { which = rec_situation_add_civic_temp value = owner.modifier:rec_civic_situation_improve_add }
}

# 政策
if = { # 自由市场 +1.0增长
limit={
Expand Down Expand Up @@ -373,7 +381,8 @@ situation_event = { # 计算情况改善-法令基础 16号
is_triggered_only = yes
hide_window = yes
immediate = {
set_variable = { which = rec_situation_add_edict_temp value = 0 } # 初始化经济情况改善 - 法令基础
set_variable = { which = rec_situation_add_edict_temp value = 0 } # 初始化经济情况改善 - 法令基础国策基础
change_variable = { which = rec_situation_add_edict_temp value = owner.modifier:rec_edict_situation_improve_add } # 加载scripted_modifier
if = { # 发放消费券 +0.3增长
limit = {
owner = { has_edict = economic_consumer_coupon }
Expand Down Expand Up @@ -688,10 +697,14 @@ situation_event = { # 计算危机阈值 2号
}
}

if = { # 经济危机乘数 *50%阈值
if = { # 经济危机差分
limit = { has_situation_flag = economic_crisis }
change_variable = { which = rec_crisis_threshold value = owner.modifier:rec_incrisis_crisis_threshold_add } # 加载scripted_modifier
multiply_variable = { which = rec_crisis_threshold value = 0.5 }
}
else = {
change_variable = { which = rec_crisis_threshold value = owner.modifier:rec_crisis_threshold_add } # 加载scripted_modifier
}

set_variable = { which = rec_crisis_threshold_self value = rec_crisis_threshold }
if = { # 共同市场危机阈值
Expand Down Expand Up @@ -752,6 +765,7 @@ situation_event = { # 计算危机增长-有危机时 3号
}

set_variable = { which = rec_crisis_add_civic value = 0 }
change_variable = { which = rec_crisis_add_civic value = owner.modifier:rec_incrisis_civic_crisis_accumulate_add } # 加载scripted_modifier
if = { # 受控市场 -0.1增长
limit={ owner = { has_policy_flag = economic_stance_mixed } }
change_variable = { which = rec_crisis_add_civic value = -0.1 }
Expand Down Expand Up @@ -801,6 +815,7 @@ situation_event = { # 计算危机增长-无危机时-国策基础 8号
hide_window = yes
immediate = {
set_variable = { which = rec_crisis_add_civic value = 0 } # 初始化危机累积增加 - 国策基础
change_variable = { which = rec_crisis_add_civic value = owner.modifier:rec_civic_crisis_accumulate_add } # 加载scripted_modifier
# 政策
if = { # 受控市场 -0.1增长
limit={
Expand Down Expand Up @@ -948,6 +963,7 @@ situation_event = { # 计算危机增长-无危机时-法令基础 18号
hide_window = yes
immediate = {
set_variable = { which = rec_crisis_add_edict value = 0 } # 初始化危机累积增加 - 法令基础
change_variable = { which = rec_crisis_add_edict value = owner.modifier:mod_rec_edict_crisis_accumulate_add } # 加载scripted_modifier
if = { # 福报 +0.1增长
limit={
owner = { has_edict = blessings }
Expand Down Expand Up @@ -1093,7 +1109,7 @@ situation_event = { # 计算危机积累 4号

#if = { # 战时经济重整
# limit = { owner = { is_at_war = yes } }
# change_variable = { which = rec_crisis_add_war value = value:crisis_decline_war } # BUG,本该是set_variable,目前不修
# change_variable = { which = rec_crisis_add_war value = value:crisis_decline_war }
#}
# 测试新版战争经济-提供少量危机减少
if = { # 战时经济重整-释放危机压力
Expand Down
10 changes: 5 additions & 5 deletions events/ethic_economic_crisis.txt
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ country_event = { # 经济周期控制面板
}
}
}
situation_event = { # 经济周期帮助面板
country_event = { # 经济周期帮助面板
id = ethic_economic.99990
is_triggered_only = yes
hide_window = no
Expand Down Expand Up @@ -149,7 +149,7 @@ country_event = { # 经济周期帮助-改善
option = { # 返回帮助面板
name = ethic_economic_help_return_option
hidden_effect = {
situation_event = { id = ethic_economic.99990 }
country_event = { id = ethic_economic.99990 }
}
}
}
Expand All @@ -163,7 +163,7 @@ country_event = { # 经济周期帮助-积累
option = { # 返回帮助面板
name = ethic_economic_help_return_option
hidden_effect = {
situation_event = { id = ethic_economic.99990 }
country_event = { id = ethic_economic.99990 }
}
}
}
Expand All @@ -177,7 +177,7 @@ country_event = { # 经济周期帮助-市场
option = { # 返回帮助面板
name = ethic_economic_help_return_option
hidden_effect = {
situation_event = { id = ethic_economic.99990 }
country_event = { id = ethic_economic.99990 }
}
}
}
Expand All @@ -191,7 +191,7 @@ country_event = { # 经济周期帮助-扩张
option = { # 返回帮助面板
name = ethic_economic_help_return_option
hidden_effect = {
situation_event = { id = ethic_economic.99990 }
country_event = { id = ethic_economic.99990 }
}
}
}
Expand Down
19 changes: 15 additions & 4 deletions localisation/replace/english/ethic_modifiers_l_english.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,21 @@
mod_pop_category_slave_consumer_goods_upkeep_mult:0 "$mod_pop_category_slave_consumer_goods_upkeep_add$"
mod_pop_category_bio_trophy_consumer_goods_upkeep_mult:0 "$mod_pop_category_bio_trophy_consumer_goods_upkeep_add$"

mod_economic_situation_improve_add:0 "Economic Situation Improve"
mod_economic_crisis_accumulate_add:0 "Economic Crisis Accumulate"
mod_economic_crisis_accumulate_decline:0 "Economic Crisis Accumulate Decline"
mod_economic_crisis_threshold_add:0 "Economic Crisis Threshold"
mod_rec_situation_improve_add:0 "Economic Situation Improve"
mod_rec_civic_situation_improve_add:0 "$mod_rec_situation_improve_add$"
mod_rec_edict_situation_improve_add:0 "$mod_rec_situation_improve_add$"
mod_rec_crisis_accumulate_add:0 "Economic Crisis Accumulate"
mod_rec_civic_crisis_accumulate_add:0 "$mod_rec_crisis_accumulate_add$"
mod_rec_edict_crisis_accumulate_add:0 "$mod_rec_crisis_accumulate_add$"
mod_rec_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_add$" #暂用危机积累的本地化
mod_rec_civic_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_mult$"
mod_rec_edict_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_mult$"
mod_rec_crisis_threshold_add:0 "Economic Crisis Threshold"
remark_rec_incrisis:0 "(In Crisis)"
mod_rec_incrisis_civic_situation_improve_add:0 "$mod_rec_situation_improve_add$ $remark_rec_incrisis$"
mod_rec_incrisis_civic_crisis_accumulate_add:0 "$mod_rec_crisis_accumulate_add$ $remark_rec_incrisis$"
mod_rec_incrisis_civic_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_mult$ $remark_rec_incrisis$"
mod_rec_incrisis_crisis_threshold_add:0 "$mod_rec_crisis_threshold_add$ $remark_rec_incrisis$"

mod_planet_metallurgists_produces_mult:0 "£job_foundry£ $job_foundry_plural$ and £job_smelting_workers£ $job_smelting_workers_plural$ Output"
mod_planet_artisans_produces_mult:0 "£job_artisan£ $job_artisan_plural$ and £job_smelting_workers£ $job_smelting_workers_plural$ Output"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,21 @@
mod_pop_category_slave_consumer_goods_upkeep_mult:0 "$mod_pop_category_slave_consumer_goods_upkeep_add$"
mod_pop_category_bio_trophy_consumer_goods_upkeep_mult:0 "$mod_pop_category_bio_trophy_consumer_goods_upkeep_add$"

mod_economic_situation_improve_add:0 "经济状态改善"
mod_economic_crisis_accumulate_add:0 "经济危机积累"
mod_economic_crisis_accumulate_decline:0 "经济危机积累减少"
mod_economic_crisis_threshold_add:0 "经济危机阈值"
mod_rec_situation_improve_add:0 "每月经济状态"
mod_rec_civic_situation_improve_add:0 "$mod_rec_situation_improve_add$"
mod_rec_edict_situation_improve_add:0 "$mod_rec_situation_improve_add$"
mod_rec_crisis_accumulate_add:0 "每月经济危机积累"
mod_rec_civic_crisis_accumulate_add:0 "$mod_rec_crisis_accumulate_add$"
mod_rec_edict_crisis_accumulate_add:0 "$mod_rec_crisis_accumulate_add$"
mod_rec_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_add$" #暂用危机积累的本地化
mod_rec_civic_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_mult$"
mod_rec_edict_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_mult$"
mod_rec_crisis_threshold_add:0 "经济危机阈值"
remark_rec_incrisis:0 "(经济危机时)"
mod_rec_incrisis_civic_situation_improve_add:0 "$mod_rec_situation_improve_add$$remark_rec_incrisis$"
mod_rec_incrisis_civic_crisis_accumulate_add:0 "$mod_rec_crisis_accumulate_add$$remark_rec_incrisis$"
mod_rec_incrisis_civic_crisis_accumulate_mult:0 "$mod_rec_crisis_accumulate_mult$$remark_rec_incrisis$"
mod_rec_incrisis_crisis_threshold_add:0 "$mod_rec_crisis_threshold_add$$remark_rec_incrisis$"

mod_pop_ethic_pacifist_attraction_mult:0 "道德主义思潮吸引力"
mod_pop_ethic_militarist_attraction_mult:0 "军国主义思潮吸引力"
Expand Down

0 comments on commit 9de6610

Please sign in to comment.