Add accessibility feature for Equinox

This commit is contained in:
Emik 2026-02-11 18:46:56 +01:00
parent 4f8902411b
commit 4fe62bba97
Signed by: emik
GPG key ID: 6B0CD72A5E503BDF
3 changed files with 24 additions and 2 deletions

1
config.lua Normal file
View file

@ -0,0 +1 @@
return {["equinox_assist"] = false}

View file

@ -318,7 +318,10 @@ local orig_draw = Card.draw
---@diagnostic disable-next-line: duplicate-set-field
function Card:draw(...)
if equinox() and not self.states.hover.is and not self.states.focus.is then
if equinox() and
not SMODS.Mods.Roland.config.equinox_assist and
not self.states.hover.is and
not self.states.focus.is then
add_to_drawhash(self)
else
return orig_draw(self, ...)
@ -329,7 +332,9 @@ local orig_draw_self = UIElement.draw_self
---@diagnostic disable-next-line: duplicate-set-field
function UIElement:draw_self(...)
if equinox() and not self.config.button and not self.config.button_UIE then
if equinox() and
not self.config.button and
not self.config.button_UIE then
add_to_drawhash(self)
else
return orig_draw_self(self, ...)

View file

@ -20,3 +20,19 @@ SMODS.Atlas {
SMODS.current_mod.optional_features = function()
return {cardareas = {deck = true, unscored = true}}
end
SMODS.current_mod.config_tab = function()
return {
n = G.UIT.ROOT,
config = {r = 0.1, minw = 8, minh = 6, align = "tl", padding = 0.2, colour = G.C.BLACK},
nodes = {{
n = G.UIT.C,
config = {minw = 1, minh = 1, align = "tl", colour = G.C.CLEAR, padding = 0.15},
nodes = {create_toggle({
label = "Assist: Only hide text during Equinox Blind",
ref_table = SMODS.Mods.Roland.config,
ref_value = "equinox_assist",
})},
}},
}
end