This repository has been archived on 2021-04-24. You can view files and clone it, but cannot push or open issues or pull requests.
Mikubot/plugins/pluginsold/service_template.lua

19 lines
428 B
Lua

local function run(msg, matches)
-- avoid this plugins to process user messages
if not msg.service then
-- return "Are you trying to troll me?"
return nil
end
print("Service message received: " .. matches[1])
end
return {
description = "Template for service plugins",
usage = "",
patterns = {
"^!!tgservice (.*)$" -- Do not use the (.*) match in your service plugin
},
run = run
}