Skip to content

Commit f62d732

Browse files
Merge pull request #513 from TheBearodactyl/main
add "force tooltips" setting
2 parents ba46233 + 2924c2f commit f62d732

File tree

4 files changed

+12
-2
lines changed

4 files changed

+12
-2
lines changed

Cryptid.lua

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,12 @@ local cryptidConfigTab = function()
234234
ref_table = Cryptid_config,
235235
ref_value = "experimental",
236236
})
237+
cry_nodes[#cry_nodes + 1] = create_toggle({
238+
label = localize("cry_force_tooltips"),
239+
active_colour = HEX("22c705"),
240+
ref_table = Cryptid_config,
241+
ref_value = "force_tooltips",
242+
})
237243
cry_nodes[#cry_nodes + 1] = create_toggle({
238244
label = localize("cry_feat_https module"),
239245
active_colour = HEX("b1c78d"),

config.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ return {
88
},
99
["family_mode"] = false,
1010
["experimental"] = false,
11+
["force_tooltips"] = true,
1112
["HTTPS"] = true,
1213
["menu"] = true,
1314
}

localization/en-us.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4471,6 +4471,7 @@ return {
44714471
cry_mus_exotic = "Exotic Jokers (Joker in Latin by AlexZGreat)",
44724472
cry_mus_high_score = "High Score (Final Boss [For Your Computer] by AlexZGreat)",
44734473
cry_mus_alt_bg = "Background Music (by MathIsFun_)",
4474+
cry_force_tooltips = "Force Tooltips",
44744475
cry_family = "Family Friendly Mode",
44754476
cry_experimental = "Experimental Mode",
44764477

lovely/lib_ui.toml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,9 @@ target = "engine/node.lua"
7878
pattern = "if self.children.h_popup then"
7979
position = 'at'
8080
match_indent = true
81-
payload = "if self.children.h_popup and not (self.force_popup and self:force_popup()) then"
81+
payload = '''
82+
if self.children.h_popup and not (self.force_popup and self:force_popup() and Cryptid["force_tooltips"]) then
83+
'''
8284

8385
# Let description tooltips work for any object
8486
[[patches]]
@@ -96,4 +98,4 @@ target = "card.lua"
9698
pattern = "if self.highlighted and self.area and self.area.config.type ~= 'shop' then"
9799
position = 'at'
98100
match_indent = true
99-
payload = "if self.highlighted and self.area and self.area.config.type ~= 'shop' and not self.area.config.collection then"
101+
payload = "if self.highlighted and self.area and self.area.config.type ~= 'shop' and not self.area.config.collection then"

0 commit comments

Comments
 (0)