MCLoreChat (Discord lore editor)

Description and Usage


This plugin allows you to host a Discord bot from your spigot server that allows you to edit and add lored items in a player's inventory. 

The commands for this bot have to be put into a server, with a channel that the bot can see and send messages in. Simply put the name of the designated channel into the config (by default, it's lore-channel) and you can run the Discord commands from there.

!LoreAdd [Playername] [Item]
Name:[Desired item name/color codes/]
>&[Color code] (Whatever you put after a less-than symbol is placed in front of every following line until the next '>'. Generally used for coloring whole paragraphs.)
[Lore goes here]
[You can just do a line break for a new line]

 

[Or even the next paragraph]

That would result in this item being added to the specified player, as long as you put the correct item name in the third argument line. 


I edited it for the example item, the exact command used to create this item was 

!Lorehand Mind stick
Name:&f[Desired item name/color codes/]
>&f[Color code]
[Lore goes here]
[You can just do a line break for a new line]
> &f

[Or even the next paragraph]


The other two Discord commands are !lore help, which displays help for how to use the commands. And !Lorehand. It does exactly the same thing as !Loreadd, except it doesn't require an item argument and it instead overwrites the lore and display name of whatever item you're holding.

The only in-game command so far is /sendlore, which will send formatted lore from the item to the designated channel so that you can edit an existing item easily. It uses the permissions loreitems.send or loreitems.*

Example of use: I held this item, and ran the command.


The bot then sent this message in the designated channel, which I can then use with the !lorehand or !loreadd commands to edit the lore.


More Examples. It can go up to 255 characters per line, but fifty characters is commonly used where I play for nice-looking paragraphs and easy editing.




Good as new.


Installation

Version 1.0.1 should work on spigot 1.12-1.15.2, and possibly future and past versions as well. If it doesn't, complain at me on Discord and I'll might see what I can do.

Follow the tutorial here for creating a bot account, and copy its token. Then, put the mclorechat.jar into your plugins directory along with the config folder. If you don't have the config folder, it'll generate on startup.

Paste the bot token into the config where it says token, and adjust the designated channel as you like. There's a third option which allows you to disable the !Loreadd command if you'd like players to be able to name their items and add lore, but not insert items into their inventory. Once you have the token in the config, restart the server and it will connect the bot to Discord and generate an invite link. Invite that and presto, you can run commands from the designated channel.

Contact me at HeartOChaos#5042 on Discord if you have any problems or questions. 

 

This plugin is open source. I'm not sure if I exported it correctly, but all the code is there, so it should be usable in one way or another.


Comments

Posts Quoted:
Reply
Clear All Quotes

About This Project

  • Project ID
    406930
  • Created
    Sep 7, 2020
  • Last Released File
    Sep 9, 2021
  • Total Downloads
    174
  • License

Categories

Members

Recent Files