Skip to content

Commit 273996a

Browse files
authored
fix: improved stability (#817)
* bug fix * fix: improved stability
1 parent 58c275c commit 273996a

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

lib/ascended.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ function G.FUNCS.get_poker_hand_info(_cards)
137137
a_power = 0
138138
end
139139
end
140-
if a_power > 0 then
140+
if to_number(a_power) > 0 then
141141
G.GAME.current_round.current_hand.cry_asc_num = a_power
142142
-- Change mult and chips colors if hand is ascended
143143
if not hidden then

lib/misprintize.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -482,7 +482,9 @@ function Cryptid.manipulate(card, args)
482482
end
483483
end
484484
--ew ew ew ew
485-
G.P_CENTERS[card.config.center.key].config = config
485+
if G.P_CENTERS[card.config.center.key] then
486+
G.P_CENTERS[card.config.center.key].config = config
487+
end
486488
end
487489
return true
488490
end

lib/overrides.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -915,7 +915,7 @@ function create_card(_type, area, legendary, _rarity, skip_materialize, soulable
915915
end
916916

917917
if forced_key and not G.GAME.banned_keys[forced_key] then
918-
_type = (G.P_CENTERS[forced_key].set ~= "Default" and G.P_CENTERS[forced_key].set or _type)
918+
_type = (G.P_CENTERS[forced_key] and G.P_CENTERS[forced_key].set ~= "Default" and G.P_CENTERS[forced_key].set or _type)
919919
end
920920

921921
local front = (SMODS.set_create_card_front and (_type == "Base" or _type == "Enhanced")) or nil

0 commit comments

Comments
 (0)