Difference between revisions of "Polarity"

From Botdom Wiki
Jump to: navigation, search
(inactive project)
 
Line 8: Line 8:
 
| license = [[Free software]] ([[GNU General Public License|GPL]])
 
| license = [[Free software]] ([[GNU General Public License|GPL]])
 
}}
 
}}
 +
{{DeadProject|nodl=yes}}
 +
 
'''Polarity''' is a bot developed by [[User:Khyperia|Khyperia]].
 
'''Polarity''' is a bot developed by [[User:Khyperia|Khyperia]].
  
Line 55: Line 57:
 
{{GPL}}
 
{{GPL}}
  
[[Category:Bots]]
 
 
[[Category:C#]]
 
[[Category:C#]]

Latest revision as of 00:09, 15 July 2015

Polarity
PolarityScreenshot.png
Developer(s): Khyperia
Programming language: C#
Development state: Alpha
Source model: Open source


License type: Free software (GPL)


Inactive Project
This project appears to be discontinued. This project has no available downloads

Polarity is a bot developed by Khyperia.

How to use

Running

To run Polarity, do the following:

Unzip the files into a directory of your choice.

Run Polarity. Don't freak out when a "fatal error" and a stack trace appears, read the exception, please. Make sure to change the config file information before running again. Not doing so will result in unspecified behavior. (I've never done it myself, so I have no idea what will happen)

Run Polarity again. It should soon say it joined the homeroom you entered into the config file (if you left PolarityPrinter.dll next to the application, this dll logs most information to the console. Without it, not much gets printed)

Interact with Polarity by joining the chatroom it is in on your own Deviantart client (such as chat.deviantart.com). Congratulations, you're running Polarity!

Creating plugins

To create a plugin, do the following:

Make a new "Class Library" in Visual Studio. This type of project produces a DLL.

Add a reference to the executable, and only the executable "Polarity.exe".

Add "using Khyperia.Polarity;"

Make your class extend Plugin (fully qualified name is Khyperia.Polarity.Plugin)

Implement Plugin (it is an abstract class) and fill in each method accordingly.

To register commands, simply place in your OnActivate() method "new Command("commandname", MyCommandFunction);" where MyCommandFunction is a delegate having the signature (string, string, string[]). (first string is room, second is command sender, third is args)

To register events, in your class type in "override" and Visual Studio should pop up with all the events. Simply press enter on the one you want, and it fills in the method. you do not have to call through to the base class, it is an empty method

All API methods are inside Plugin, this means that you can simply type in the method name and it will work. For example, you may call "Chat("Botdom", "Hello world");" from your class.

When you are ready to run, compile with f6, and place the output dll next to the executable. Run Polarity, or, if it is already running, trigger it with "reload". If it worked, congratulations!

Downloads

Go to polarity.codeplex.com and click on the big download button on the right. Other versions are also available here.

Changelog

Alpha

4/7/2012 Build 4 v1.1

Added many new features and bugfixes, such as tablump parsing and the run command.

4/6/2012 Build 1 v1.0

Initial release.

GreenCopyleft.svg
Heckert GNU white.png
This work is released under the GNU General Public License, which allows you to freely use, modify, or distribute it, as long as you give these rights to subsequent users of (this work or your derivative of it) too.