ultra mega special case (lua string matching fuckery)

This commit is contained in:
tommy aka doge 2022-09-11 21:35:00 -04:00
parent 9559a8c819
commit 6076d4b179

View File

@ -49,8 +49,7 @@ for _, game in next, API.GAMES do
if type(k)=='string' then
for i = 1, self.count do
local v = self[i]
if type(v) == 'table' and v.DisplayName:lower():find(tostring(k):lower()) then
if type(v) == 'table' and v.DisplayName:lower():find(tostring(k:gsub('%%', '%%%%'):gsub('^%^', '%%^'):gsub('%$$', '%%$'):gsub('%(', '%%('):gsub('%)', '%%)'):gsub('%.', '%%.'):gsub('%[', '%%['):gsub('%]', '%%]'):gsub('%*', '%%*'):gsub('%+', '%%+'):gsub('%-', '%%-'):gsub('%?', '%%?')):lower()) then
return v
end
end