ChatterBukkit

This plugins allows you to chat with a Bot in-game.

==Main Idea==
How many times have you wanted to have a friend with you, when its too early/late and there's no one to talk with you? Well, now you can call a Bot to chat with you!

==Features==
- Allows you to chat with CleverBot using a command.

==Planned Features==
- More Bots!
- Possibility to change your nickname at the eyes of the Bot!

==How to use==
First of all, just type /chatterbukkit (you can also use /cb instead).
That should bring up a list of possible options. Options differ if you have created sessions or not.
To create a chat session, just type "/cb cleverbot". That will create a CleverBot session.
Now, just type "/cb <message>", to chat with him. Messages might take a tiny bit to show up, but that's normal. This plugin connects with the website of the Bot you're using.
After you're done chatting, just type "/cb destroy" to destroy your current session.
If you logout, it does it automatically for you.
In the future, I'll implement more bots to chat with. For now, deal with the Cleverness of CleverBot.

==How it works==
Attention: This page contains some more technical aspects of the plugin. This plugin uses an external API that you can see below the details for it.
The messages that are sent to the Bot or the ones received from the Bot use this base of communication: the message attached to the message digest (using a MD5 algorithm, the digest is a digest of the message, obviously). All messages are Strings encoded in UTF-8.
This plugin works on the base of the command. Once you create your session, this plugin creates a HTTP Connection between the Bukkit server and the Bot's website, and sends the Bot the message "Hi, I am <Your nickname here, if you're console it says Console>". After that, it starts a new Thread on the Bukkit server, which is assigned to your specific session, and, waits for an answer from the Bot. After it receives data from the Bot, it confirms the digest. The Digest is detached from the message, then the plugin calculates its own digest, and makes sure both digests are the same, otherwise throws an error. After that, it prints the message to you.
Once you send a message, it repeats the process, but instead of sending the message "Hi, I am <nickname>" it sends your message, and the rest is the exact same thing.
If you destroy the session, the plugin sends the message "Bye!" and starts the Thread, with a special variable. That variable, if set to true, the thread voids your session after receiving a message from the bot. (By voiding, I mean that it totally removes all of the references to the player, the bot, the chat session, and then it totally gets rid of your session from the HashMap that is storing the currently active sessions. Once Java's Garbage Collector gets to work, it will totally remove any reference to it, just for the record :)

==Permissions==
All permissions default always to players with OP.
There is only one simple permission:
chatterbukkit.cleverbot -> Allows you to chat with CleverBot, using the command /chatterbukkit (you can also use /cb)

==Installation==
Just download the latest version of the plugin, and place it in your plugins folder. Then, restart or reload your server.

==Bugs==
Please report ANY bugs you find, any exceptions that appear on the console, but they are not supposed to, anything related to it, pretty much, using Bukkit Dev's Ticket tracker.

==Developers/Source code/Credits==
For developers, you can check the source code of the project inside the plugin's jar.

Now the credits: I used an external API, "chatter-bot-api", by "pierredavidbelanger". Here's the link for it, for those of you interested: https://code.google.com/p/chatter-bot-api/


Comments

Posts Quoted:
Reply
Clear All Quotes

About This Project

Categories

Members

Recent Files