administration.lua: Added antiflood flag.
bible.lua: Some better error handling. hearthstone.lua: Corrected help message. utilities.lua: Added string:index() to succeed get_word().
This commit is contained in:
@@ -19,6 +19,16 @@ get_word = function(s, i)
|
||||
|
||||
return t[i] or false
|
||||
|
||||
end
|
||||
|
||||
-- Like get_word(), but better.
|
||||
-- Returns the actual index.
|
||||
function string:index()
|
||||
local t = {}
|
||||
for w in s:gmatch('%g+') do
|
||||
table.insert(t, w)
|
||||
end
|
||||
return t
|
||||
end
|
||||
|
||||
-- Returns the string after the first space.
|
||||
|
Reference in New Issue
Block a user