Skip to content

Commit 350d6d1

Browse files
authored
SPA - Avoid excessive SOL with indigenous subsistence ownership (#78)
* Trying something out with indigenous subsistence ownership * Only in homelands
1 parent 6aa4c2c commit 350d6d1

File tree

3 files changed

+111
-1
lines changed

3 files changed

+111
-1
lines changed
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# on_actions to apply traditional indigenous governance modifiers
2+
3+
on_game_started = {
4+
on_actions = {
5+
MoG_SPA_indigenous_subsistance_setup_action
6+
}
7+
}
8+
9+
MoG_SPA_indigenous_subsistance_setup_action = {
10+
effect = {
11+
every_state = {
12+
refresh_indigenous_subsistance_modifier = yes
13+
}
14+
}
15+
}
16+
17+
on_monthly_pulse_country = {
18+
on_actions = {
19+
MoG_SPA_indigenous_subsistance_monthly_pulse
20+
}
21+
}
22+
23+
MoG_SPA_indigenous_subsistance_monthly_pulse = {
24+
effect = {
25+
every_scope_state = {
26+
refresh_indigenous_subsistance_modifier = yes
27+
}
28+
}
29+
}
Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
refresh_indigenous_subsistance_modifier = {
2+
set_local_variable = {
3+
name = pop_indig
4+
value = 0
5+
}
6+
7+
set_local_variable = {
8+
name = pop_total
9+
value = 0
10+
}
11+
12+
if = {
13+
limit = {
14+
has_modifier = mog_spa_indigenous_subsistance
15+
}
16+
remove_modifier = mog_spa_indigenous_subsistance
17+
}
18+
19+
save_temporary_scope_as = state
20+
every_scope_pop = {
21+
limit = {
22+
AND = {
23+
is_employed = yes
24+
workplace = { is_subsistence_building = yes }
25+
}
26+
}
27+
change_local_variable = {
28+
name = pop_total
29+
add = total_size
30+
}
31+
if = {
32+
limit = {
33+
AND = {
34+
NOT = {
35+
is_pop_type = slaves
36+
}
37+
culture = {
38+
OR = {
39+
has_discrimination_trait = indigenous_american_heritage
40+
has_discrimination_trait = indigenous_oceanic_heritage
41+
}
42+
}
43+
state.state_region = {
44+
is_homeland = prev.culture
45+
}
46+
}
47+
}
48+
change_local_variable = {
49+
name = pop_indig
50+
add = total_size
51+
}
52+
}
53+
}
54+
if = {
55+
limit = {
56+
local_var:pop_indig > 0
57+
}
58+
set_local_variable = {
59+
name = indig_ratio
60+
value = {
61+
value = local_var:pop_indig
62+
divide = local_var:pop_total
63+
multiply = {
64+
value = 1
65+
subtract = modifier:building_group_bg_subsistence_agriculture_allowed_collectivization_add # It's assumed ranching has the same value
66+
}
67+
min = 0
68+
}
69+
}
70+
add_modifier = {
71+
name = mog_spa_indigenous_subsistance
72+
multiplier = local_var:indig_ratio
73+
}
74+
}
75+
}

Soft Pop Adjustments/common/static_modifiers/MoG_SPA_static_modifiers.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Apply an immigration penalty to extractive Company Colonies like BIC & DEIC
1+
# Apply an immigration penalty to extractive Company Colonies like BIC & DEIC
22
mog_company_migration_penalty = {
33
icon = "gfx/interface/icons/timed_modifier_icons/modifier_flag_negative.dds"
44
state_migration_pull_mult = -0.7
@@ -35,4 +35,10 @@ mog_spa_base_sol_from_literacy = {
3535
icon = "gfx/interface/icons/generic_icons/sol_icon.dds"
3636
state_upper_strata_expected_sol_add = 6.52670 # Calibrated on the base modifier being 15 -> for total = 21.52670. (11.52670 above middle class = 3x middle class income)
3737
#state_expected_sol_from_literacy = 5 # Calibrated on the base modifier being 5 -> for total = 10.
38+
}
39+
40+
mog_spa_indigenous_subsistance = {
41+
icon = "gfx/interface/icons/law_icons/elder_council.dds"
42+
building_group_bg_subsistence_agriculture_allowed_collectivization_add = 1
43+
building_group_bg_subsistence_ranching_allowed_collectivization_add = 1
3844
}

0 commit comments

Comments
 (0)