Skip to content

Instantly share code, notes, and snippets.

@SwadicalRag
Last active September 20, 2015 08:42
Show Gist options
  • Save SwadicalRag/109ab07e46e8a1c58c91 to your computer and use it in GitHub Desktop.
Save SwadicalRag/109ab07e46e8a1c58c91 to your computer and use it in GitHub Desktop.
Lao "G" in Lua
hook.Add("Message","Lao G",function(_,__,msg)
if(msg:match("(%a*[Gg]%a*)")) then
for g in msg:gmatch("(%a*[Gg]%a*)") do
local g2,n = g:gsub("([Gg])","'G'")
print(g2)
end
print("There's the 'G'!")
end
end)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment