Skip to content

Commit ff0016d

Browse files
committed
fix automatic stake sticker localization
1 parent 3a0feb8 commit ff0016d

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

lib/overrides.lua

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1166,8 +1166,7 @@ end
11661166
--Cryptid (THE MOD) localization
11671167
local function parse_loc_txt(center)
11681168
center.text_parsed = {}
1169-
if not center.text then
1170-
else
1169+
if center.text then
11711170
for _, line in ipairs(center.text) do
11721171
center.text_parsed[#center.text_parsed + 1] = loc_parse_string(line)
11731172
end
@@ -1185,6 +1184,7 @@ local function parse_loc_txt(center)
11851184
end
11861185
local il = init_localization
11871186
function init_localization()
1187+
il()
11881188
if G.SETTINGS.language == "en-us" then
11891189
G.localization.descriptions.Spectral.c_cryptid.text[2] = "{C:attention}#2#{} selected card"
11901190
G.localization.descriptions.Spectral.c_talisman.text[2] = "to {C:attention}#1#{} selected"
@@ -1199,9 +1199,9 @@ function init_localization()
11991199
G.localization.descriptions.Voucher.v_crystal_ball.text[1] = "{C:attention}+#1#{} consumable slot"
12001200
G.localization.descriptions.Joker.j_seance.text[1] = "If {C:attention}played hand{} contains a" -- damnit seance
12011201
end
1202-
if Cryptid.obj_buffer and Cryptid.obj_buffer.Stake then
1203-
for i = 1, #Cryptid.obj_buffer.Stake do
1204-
local key = Cryptid.obj_buffer.Stake[i].key
1202+
if Cryptid.object_buffer and Cryptid.object_buffer.Stake then
1203+
for i = 1, #Cryptid.object_buffer.Stake do
1204+
local key = Cryptid.object_buffer.Stake[i].key
12051205
local color = G.localization.descriptions.Stake[key] and G.localization.descriptions.Stake[key].colour
12061206
if color then
12071207
local sticker_key = key:sub(7) .. "_sticker"
@@ -1223,7 +1223,6 @@ function init_localization()
12231223
end
12241224
end
12251225
end
1226-
il()
12271226
end
12281227

12291228
--Fix a corrupted game state

0 commit comments

Comments
 (0)