diff options
author | Elias Fleckenstein <eliasfleckenstein@web.de> | 2021-03-14 13:37:36 +0100 |
---|---|---|
committer | Elias Fleckenstein <eliasfleckenstein@web.de> | 2021-03-14 13:37:36 +0100 |
commit | 5923e8db837b5ec4400c982ab9d9adf8b0ea3ade (patch) | |
tree | 9f00b1c17006a3c95cc29b70807b6deb69de7dcf /bot.lua | |
parent | e0f95cf2a9a86bfafabc8eb9f9e4b6e7dc592490 (diff) | |
download | furrybot-5923e8db837b5ec4400c982ab9d9adf8b0ea3ade.tar.xz |
Add solo RPG commands
Diffstat (limited to 'bot.lua')
-rw-r--r-- | bot.lua | 25 |
1 files changed, 17 insertions, 8 deletions
@@ -122,7 +122,7 @@ function furrybot.repeat_string(str, times) return msg end -function furrybot.simple_rpg_command(action) +function furrybot.interactive_rpg_command(action) return function(name, target) if furrybot.online_or_error(name, target) then furrybot.send(name .. " " .. action .. " " .. target .. ".", furrybot.colors.rpg) @@ -130,6 +130,12 @@ function furrybot.simple_rpg_command(action) end end +function furrybot.solo_rpg_command(action) + return function(name) + furrybot.send(name .. " " .. action .. ".", furrybot.colors.rpg) + end +end + function furrybot.request_command(on_request, on_accept) return function(name, target) if furrybot.online_or_error(name, target) and on_request(name, target) ~= false then @@ -215,13 +221,16 @@ function furrybot.commands.cmd() end -- rpg -furrybot.commands.hug = furrybot.simple_rpg_command("hugs") -furrybot.commands.cuddle = furrybot.simple_rpg_command("cuddles") -furrybot.commands.kiss = furrybot.simple_rpg_command("kisses") -furrybot.commands.hit = furrybot.simple_rpg_command("hits") -furrybot.commands.slap = furrybot.simple_rpg_command("slaps") -furrybot.commands.beat = furrybot.simple_rpg_command("beats") -furrybot.commands.lick = furrybot.simple_rpg_command("licks") +furrybot.commands.cry = furrybot.solo_rpg_command("cries") +furrybot.commands.laugh = furrybot.solo_rpg_command("laughs") +furrybot.commands.confused = furrybot.solo_rpg_command("is confused") +furrybot.commands.hug = furrybot.interactive_rpg_command("hugs") +furrybot.commands.cuddle = furrybot.interactive_rpg_command("cuddles") +furrybot.commands.kiss = furrybot.interactive_rpg_command("kisses") +furrybot.commands.hit = furrybot.interactive_rpg_command("hits") +furrybot.commands.slap = furrybot.interactive_rpg_command("slaps") +furrybot.commands.beat = furrybot.interactive_rpg_command("beats") +furrybot.commands.lick = furrybot.interactive_rpg_command("licks") furrybot.commands.sex = furrybot.request_command(function(name, target) furrybot.ping_message(target, name .. " wants to have sex with you. Type !accept to accept or !deny to deny.", furrybot.colors.system) |