Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 150 lines (80 sloc) 4.921 kb
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
1 NodeJS IRC bot with plugin support
2 ==================================
3
4 How to get it
5 -------------
6
3605de1 @draggor readme updates
authored
7 npm install ircbot
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
8
9 Or you can clone this repo.
10
11 How to use it
12 -------------
13
a289aad @draggor little readme test
authored
14 Check out `example/bot.js` for creating an instance of the bot.
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
15
16 Plugins
17 =======
18
19 admin
20 -----
21
8be9efd @draggor Updating readme
authored
22 This plugin provides an interface for dealing with the bot via irc. It provides the following commands: `load`, `unload`, `prefix`, `permissions`, `summon`, `banish`. Commands by default are prefixed with `!`, though this is something you can change.
4455ffe @draggor Adding exploding dice to dice plugin, adding default options in plugins
authored
23
24 ### load
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
25
26 If you wanted to run the dice plugin on #chan1 and #chan2, and not reply to PMs, do:
27
28 !load dice chan:#chan1,#chan2 !pm
29
30 If you wanted to have the admin plugin only work for user Joe, do:
31
32 !load admin nick:joe
33
34 If you wanted the dice plugin to only respond to PMs, do:
35
36 !load dice !chan
37
38 If you wanted to ban Joe and Schmoe from the dice plugin, do:
39
40 !load dice !nick:Joe,Schmoe
41
42 If you want to block all PMs and block Joe from using the dice plugin in a chan, do:
43
44 !load dice !nick:Joe !pm
45
3605de1 @draggor readme updates
authored
46 If `chan` and `!chan`, or `nick` and `!nick` are found, the allow versions override the deny versions. If no allow/deny parameters are specified, it will respond to all channel messages and all PMs.
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
47
8be9efd @draggor Updating readme
authored
48 If you want to load a plugin with a different prefix, do:
49
50 !load dice cmdprefix:@
51
52 For the dice plugin only, commands that require a prefix will use `@` instead of `!`.
53
54 Lastly, some plugins may allow you to pass in other options. You do this in the same format as specified above. For example:
55
56 !load dice cap:50
57
58 ### unload
59
60 This simply takes a single argument, the name of the plugin to unload:
61
62 !unload dice
63
64 ### prefix
65
66 Use this to change the prefix character to trigger commands that require it:
67
68 !prefix admin ;
69
70 Going forward, if you wanted to load a plugin:
71
72 ;load dice
73
74 If dice had any prefixed commands, those would still default to `!` unless specified.
75
76 ### permissions
77
78 This will chance the chan and nick based restrictions similar to `load`, only it won't reload the plugin, so any state you have will be maintained.
79
80 !permissions admin nick:joe
81
82 This will make the admin plugin only respond to someone named joe from now on. It removes all other permissions and replaces it with what you put here.
83
84 ### summon
85
86 This takes a list of channels you wish to have the bot join:
87
88 !summon #chan1 #chan2 #chan3
89
90 ### banish
91
92 This takes a list of channels you wish the bot to leave:
93
94 !banish #chan1 #chan2 #chan3
95
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
96 dice
97 ----
98
8be9efd @draggor Updating readme
authored
99 This plugin provides a die roller, and also a limited calculator along with it. It will parse each line for dice expressions, evaluate them all, then return the results. By default it will have a cap of 100 dice.
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
100
101 For example:
102
103 Joe: I attack at [1d20+8] and deal [2d6+3] damage!
104 Bot: Joe: [1d20+8] => 13,8 => 21, [2d6+3] => 3,6,3 => 12
105
8be9efd @draggor Updating readme
authored
106 Some games need exploding dice, which is a feature that when the maximum value of the die is rolled you get to reroll it and total the results. The `e` and `E` operators will do this for you:
107
108 Joe: Come on luck roll! [2e6]
109 Bot: Joe: [2e6] => 5,6,3 => 14
110
111 The exploding rolls will always follow after the die that triggered it.
112
113 ### Option: cap
114
115 This sets the maximum number of dice tat will be rolled before taking into account exploding dice. The default is 100. With the default, `[101d100]` will cause an error to be displayed. Any chaining dice that has a result in over the cap will trigger the error, ie: `[50d50d6]` is rather likely to be well over the 100 cap. The option argument to pass in is in the form of `cap:100`, or:
116
117 !load dice cap:100
118
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
119 farkle
120 ------
121
3605de1 @draggor readme updates
authored
122 This plugin will allow one game of farkle per channel. When loaded, you should use the `!pm` option to block out PM use of this plugin (this is likely to be fixed in a future version).
cb7e9b4 @draggor Filling out the readme and fixing up the farkle plugin
authored
123
3605de1 @draggor readme updates
authored
124 use `!help` to learn more about this plugin.
edc807f @draggor Added some basic sw plugin documentation
authored
125
126 sw
127 --
128
129 This is a Savage Worlds plugin that provides commands to help with that RPG system. It has the following commands: `card`, `init`, `initshuffle`, `draw`, `shuffle`.
130
131 ### card
132
133 This command will display a randomly selected card from a standard deck, including jokers. Cards are in the format of VS, where V is the value selected from A,2,3,4,5,6,7,8,9,T,J,Q,K,A and S is a suit from D,H,C,S (Diamonds, Hearts, Clubs, Spades). Jokers are special, in that the red and black ones are JR and JB respectively.
134
135 ### init
136
137 This will draw one card off of the shared initiative deck. When it runs out it will automatically shuffle.
138
139 ### initshuffle
140
141 This will force the shared initiative deck to shuffle.
142
143 ### draw
144
145 This command without any arguments will draw one card off of your personal deck, which is tied to your current nick. Optionally you may pass in a number of cards to be drawn. If the cards to be drawn are greater than the number of cards left, it will shuffle first, and then draw.
146
147 ### shuffle
148
149 This command will shuffle the personal deck that is tied to your current nick.
Something went wrong with that request. Please try again.