Unfortunately I can't tell you why it's crashing, but I don't think it has anything to do with the localization. Here's my entire file setup and the resulting, perfectly-functional localization:—
Code:
# common/buildings/anyasia_test_buildings.txt
uppakra_temple_01 = {
construction_time = very_slow_construction_time
type_icon = "icon_structure_buddhas_of_bamiyan.dds"
can_construct_potential = {
building_requirement_tribal = no
}
is_enabled = {
always = yes
}
cost_gold = 3000
character_modifier = {
monthly_piety_gain_mult = 0.1
diplomacy_per_piety_level = 1
}
county_modifier = {
tax_mult = 0.1
development_growth = 0.2
development_growth_factor = 0.75
}
ai_value = {
base = 100
modifier = { # Fill all building slots before going for special buildings
factor = 0
free_building_slots > 0
}
}
type = special
}
Code:
# history/provinces/z_anyasia_test_buildings.txt
70 = { #LUND
culture = norse
religion = norse_pagan
holding = tribal_holding
965.1.1 = {
culture = danish
religion = catholic
}
1020.1.1 = {
holding = castle_holding
special_building = uppakra_temple_01
}
1066.1.1 = {
buildings = {
common_tradeport_01
cereal_fields_01
pastures_01
}
}
}
Code:
# localization/english/anyasia_test_building_l_english.yml
l_english:
building_type_uppakra_temple_01:0 "Uppakra Temple"
building_type_uppakra_temple_01_desc:0 "This text should appear. [GetTitleByKey('c_skane').GetName] <- This text succeeds this."
building_uppakra_temple_01:0 "$building_type_uppakra_temple_01$"
building_uppakra_temple_01_desc:0 "$building_type_uppakra_temple_01_desc$"
View attachment 891287
One thought that came to mind when I was coding this was that, if you've put it in Lund as I have, it might be related to Lund's province definition having
special_building_slot = lund_cathedral_01 defined by default—I don't have really any experience modding buildings, but I note that every province with one of these slots defined has
only one slot defined and if it has any special building defined in the history at all, it's the one defined by the slot. Perhaps a mismatch between this and your custom building is responsible for the crash? I didn't test it—you'll see I removed that line from my province definition above—but It's really the only immediate thing coming to mind, unfortunately.
Edit: Or maybe it's the lack of key version in your localization (the
0 following the colon in mine, absent in yours)? That seems even less likely, given I don't think it's required, but hey, who knows, I'm at a loss, so any little discrepancy becomes suspect, heh.