2024-10-03 08:17:41 +03:00
require 'discordrb'
require 'dotenv'
require 'sqlite3'
Dotenv . load
bot = Discordrb :: Commands :: CommandBot . new token : ENV [ 'TOKEN' ] , client_id : ENV [ 'CLIENT_ID' ] , prefix : ENV [ 'PREFIX' ]
2024-10-03 09:04:32 +03:00
bot . command :help do | event , * message |
2024-10-04 19:02:48 +03:00
event . author . pm ( " You've asked for help. In order not to flood the channel where you sent the command, I have sent the list of commands here, in your PMs. Enjoy!
2024-10-07 22:28:22 +03:00
** Quote system **
` ` `
; quote < category ( optional ) > - displays a quote from the category
; addquote < category > < quote > - adds a quote into a category
; quotecategories - shows all categories
; showquote < id > - shows the quote with the id provided ` ` `
** Networking related commands **
` ` `
; ip < ips > - Display basic information about an IP address . You can input multiple IPs . We are required to state that the information provided by this command comes from the IP2Location database .
` ` `
2024-10-09 10:51:54 +03:00
** Miscellaneous **
` ` `
; days < date in % d / % m / % Y format > - shows you the days until that date
` ` `
2024-10-04 19:02:48 +03:00
" )
2024-10-03 09:04:32 +03:00
event . message . delete
2024-10-03 08:17:41 +03:00
nil
end
2024-10-04 20:59:56 +03:00
# stolen from https://github.com/Suylo/Discord-Bot/blob/master/index.rb
systems = Dir [ " systems/*.rb " ]
systems . each { | i | require_relative " #{ i } " }
2024-10-04 09:09:06 +03:00
bot . include! QuoteSystem
2024-10-04 19:02:48 +03:00
bot . include! NetworkModule
2024-10-04 22:17:09 +03:00
bot . include! TriggerSystem
2024-10-06 14:12:09 +03:00
bot . include! StarboardSystem
2024-10-09 10:51:54 +03:00
bot . include! MiscModule
2024-10-03 08:17:41 +03:00
bot . run