mirror of
https://github.com/edubart/otclient.git
synced 2025-04-29 17:19:20 +02:00
string:contains()
This commit is contained in:
parent
fe585d27d8
commit
939e16c59a
@ -49,3 +49,11 @@ function string:explode(sep, limit)
|
||||
table.insert(t, tmp)
|
||||
return t
|
||||
end
|
||||
|
||||
function string:contains(str, checkCase, start, plain)
|
||||
if(not checkCase) then
|
||||
self = self:lower()
|
||||
str = str:lower()
|
||||
end
|
||||
return string.find(self, str, start and start or 1, plain == nil and true or false)
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user