i dont really know how to describe this in text but whatever.
so what im trying to make is a text replacer script, for a require.
but heres the problem. like, string.gsub only replaces text that is exactly the same as the pattern, so if i do like
print(string.gsub('Text','text','t3xt'))
it returns Text 0
so yeah this is basically that one “anti-ban” script but way less annoying (it doesnt replace all the text and force presses enter) i probably shouldnt have made this
this is my script:
local keywods:{[string]:string} = {
['ban'] = 'b4n';
['kick'] = 'k1ck';
['shutdown'] = '5hu7d0wn';
['crash'] = 'cr4sh';
}
local keywords:{[string]:string} = keywods
game["Run Service"].Heartbeat:Connect(function()
for i,v in pairs(game.Players.LocalPlayer.PlayerGui:GetDescendants() :: {Instance}) do
if v:IsA('TextLabel') then
for keyword,toreplace in pairs(keywords) do
local g = {string.find(v.Text:lower(),keyword)}
-- do something idk
end
end
end
end)