Author Topic: Discord Lorebot  (Read 226 times)

0 Members and 1 Guest are viewing this topic.

Oligo

  • Immortal
  • Fodder
  • *
  • Posts: 69
  • Favorite Zone: Dunmir
Discord Lorebot
« on: June 18, 2017, 12:36:25 AM »
For folks familiar with my prior IRC and Skype versions of Lorebot, I ported much of the lore retrieval functionality to Discord.
Current lorebot database has 4,783 lores in database.

You can add LoreBot on Discord with the following tag, it is case sensitive.

Code: [Select]
@LoreBot#2504

https://github.com/longhorn09/lorebot

You will need Node, MySQL, and a Discord bot token from Discord.

Code: [Select]
# Node installation
sudo apt-get update -y
sudo apt-get install nodejs
sudo apt-get install npm

# MySQL installation
sudo apt-get install mysql-server

# Lorebot for Discord installation
git clone https://github.com/longhorn09/lorebot.git
cd lorebot
npm install
npm start
« Last Edit: Today at 05:39:17 PM by Oligo »

el conquistador

  • Newbie
  • Posts: 24
Re: Discord Lorebot
« Reply #1 on: June 19, 2017, 10:53:51 PM »
i really like the sound of a lorebot

but i have a policy about downloading mysterious stuff from programming wizards with russian sounding names  :D

Oligo

  • Immortal
  • Fodder
  • *
  • Posts: 69
  • Favorite Zone: Dunmir
Re: Discord Lorebot
« Reply #2 on: June 20, 2017, 12:10:02 AM »
but i have a policy about downloading mysterious stuff from programming wizards with russian sounding names  :D

It's all open source, so you can view the source code yourself and see there's nothing malicious in it.
Also russian programming wizards would be Jaba (created JMC while playing Arctic) and Shesh.
I'm a mere novice in comparison.

Thymorical

  • Fodder
  • *
  • Posts: 72
  • Favorite Zone: Abyss
Re: Discord Lorebot
« Reply #3 on: June 20, 2017, 04:37:48 AM »
Does lore bot still not work when idle user?

sam

  • Newbie
  • Posts: 5
Re: Discord Lorebot
« Reply #4 on: June 20, 2017, 06:14:54 AM »
but i have a policy about downloading mysterious stuff from programming wizards with russian sounding names  :D

It's all open source, so you can view the source code yourself and see there's nothing malicious in it.
Also russian programming wizards would be Jaba (created JMC while playing Arctic) and Shesh.
I'm a mere novice in comparison.

such humbleness from a person who controlled 10 chars at once and won in a pk fight against 10 human chars!

Oligo

  • Immortal
  • Fodder
  • *
  • Posts: 69
  • Favorite Zone: Dunmir
Re: Discord Lorebot
« Reply #5 on: June 20, 2017, 08:03:17 AM »
Does lore bot still not work when idle user?
Lorebot runs and responds regardless if user is idle or not.
Lorebot is currently setup to run as a daemon process, so it doesn't require human intervention.
It's actively running in the Amazon cloud right now so it's on 24/7.

It uses a npm library called forever.

Code: [Select]
forever start lorebot.js
The current Discord version of Lorebot is much more responsive than the prior Skype and IRC incarnations, a credit to Discord's API.
The idle behavior you're referring to was a limitation of Skype's API.

Long term plan is to also integrate it directly into MUSHClient once I expose its services as a RESTful API.
« Last Edit: June 20, 2017, 08:48:45 AM by Oligo »

Flair

  • Guardian
  • Newbie
  • **
  • Posts: 38
Re: Discord Lorebot
« Reply #6 on: June 20, 2017, 10:25:45 AM »
Hit me up over email or here Oligo, if you want some input code for your bot.  The one I did allows for people to add to the DB, as well as search by affect/effect

Oligo

  • Immortal
  • Fodder
  • *
  • Posts: 69
  • Favorite Zone: Dunmir
Re: Discord Lorebot
« Reply #7 on: June 20, 2017, 11:02:38 AM »
Hit me up over email or here Oligo, if you want some input code for your bot.  The one I did allows for people to add to the DB, as well as search by affect/effect

Ok appreciate the offer. I don't foresee any roadblocks currently and of course another contributor is always welcome on Github. I'd been nursing along Trogg's original XML schema from 2003 thru various IRC and Skype versions of Lorebot. But for Discord I finally took the time to write a script and load the XML into MySQL so now searching by Affect, Worn, Mat Class, Value, etc should be trivial to implement in the coming weeks.
« Last Edit: June 20, 2017, 01:02:33 PM by Oligo »

Flair

  • Guardian
  • Newbie
  • **
  • Posts: 38
Re: Discord Lorebot
« Reply #8 on: June 20, 2017, 05:33:02 PM »
Sure thing, I'll fork and PR against yours :)  I have a Mongo version with schema as well