File tree Expand file tree Collapse file tree 1 file changed +28
-0
lines changed
Expand file tree Collapse file tree 1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -15,9 +15,37 @@ G.playing_cards = {}
1515set_screen_positions()
1616'''
1717payload = '''
18+ -- Add align config to existing areas that should use it
19+ self.jokers.config.align_buttons = true
20+ self.consumeables.config.align_buttons = true
21+
1822for _, mod in ipairs(SMODS.mod_list) do
1923 if mod.can_load and mod.custom_card_areas and type(mod.custom_card_areas) == "function" then
2024 mod.custom_card_areas(self)
2125 end
2226end
27+ '''
28+
29+ # Check area.config.align_buttons if an area should align buttons like normal
30+ [[patches ]]
31+ [patches .pattern ]
32+ target = ' card.lua'
33+ match_indent = true
34+ position = ' at'
35+ pattern = '''
36+ ((self.area == G.jokers) or (self.area == G.consumeables)) and "cr" or
37+ '''
38+ payload = '''
39+ self.area.config.align_buttons and "cr" or
40+ '''
41+ [[patches ]]
42+ [patches .pattern ]
43+ target = ' card.lua'
44+ match_indent = true
45+ position = ' at'
46+ pattern = '''
47+ ((self.area == G.jokers) or (self.area == G.consumeables)) and {x=x_off - 0.4,y=0} or
48+ '''
49+ payload = '''
50+ self.area.config.align_buttons and {x=x_off - 0.4,y=0} or
2351'''
You can’t perform that action at this time.
0 commit comments