command tweaks
This commit is contained in:
parent
952ec87ba4
commit
c6cc3a4c99
7
main.rb
7
main.rb
@ -32,7 +32,7 @@ if File.exists?("/usr/bin/mpd")
|
|||||||
mpd = true
|
mpd = true
|
||||||
end
|
end
|
||||||
|
|
||||||
bot = Discordrb::Commands::CommandBot.new token: options[:bot_token], prefix: '!'
|
bot = Discordrb::Commands::CommandBot.new token: options[:bot_token], prefix: '!radio '
|
||||||
|
|
||||||
bot.command :start do |event|
|
bot.command :start do |event|
|
||||||
system("mpc play")
|
system("mpc play")
|
||||||
@ -50,16 +50,19 @@ bot.command :reload do |event|
|
|||||||
system("mpc clear")
|
system("mpc clear")
|
||||||
system("mpc update")
|
system("mpc update")
|
||||||
system("mpc add /")
|
system("mpc add /")
|
||||||
|
nil
|
||||||
end
|
end
|
||||||
|
|
||||||
bot.command :pause do |event|
|
bot.command :pause do |event|
|
||||||
event.respond("pausing playback")
|
event.respond("pausing playback")
|
||||||
system("mpc pause")
|
system("mpc toggle")
|
||||||
|
nil
|
||||||
end
|
end
|
||||||
|
|
||||||
bot.command :skip do |event|
|
bot.command :skip do |event|
|
||||||
event.respond("skipping")
|
event.respond("skipping")
|
||||||
system("mpc next")
|
system("mpc next")
|
||||||
|
nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user