Added editcounter command documentation and usage examples.
@@ -17,6 +17,7 @@ A quick listing of all commands included with Owlbot.
|
||||
| `!deletecommand` | `!delcmd` | Delete a custom command. |
|
||||
| `!commandmodonly` | `!cmdmodonly` | Toggle moderator-only access. |
|
||||
| `!resetcommand` | `!resetcmd` | Reset a command's use counter to 0. |
|
||||
| `!editcounter` | `!editcount` | Set, increment, or decrement a named counter. |
|
||||
| `!commandcooldown` | `!cmdcooldown` | Set a cooldown in seconds. |
|
||||
| `!addalias` | | Add an alias to a command. |
|
||||
| `!removealias` | | Remove an alias from a command. |
|
||||
|
||||
@@ -35,6 +35,7 @@ Delete it when it's no longer needed:
|
||||
| `!deletecommand` | `!delcmd` | `!deletecommand !name` | Moderator | Delete a custom command. |
|
||||
| `!commandmodonly` | `!cmdmodonly` | `!commandmodonly !name <on\|off>` | Moderator | Toggle moderator-only access. |
|
||||
| `!resetcommand` | `!resetcmd` | `!resetcommand !name` | Moderator | Reset a command's use counter to 0. |
|
||||
| `!editcounter` | `!editcount` | `!editcounter name <value>` | Moderator | Set, increment, or decrement a named counter. |
|
||||
| `!commandcooldown` | `!cmdcooldown` | `!commandcooldown !name <seconds>` | Moderator | Set a cooldown in seconds (0 to disable). |
|
||||
| `!addalias` | | `!addalias !command !alias` | Moderator | Add an alias to an existing command. |
|
||||
| `!removealias` | | `!removealias !alias` | Moderator | Remove an alias from a command. |
|
||||
@@ -176,6 +177,15 @@ The module serves a command list page at `/owlbot/custom_commands/list` showing
|
||||
!addcommand !win We won! Total wins: $(count wins)
|
||||
!addcommand !loss We lost. Total losses: $(count losses)
|
||||
|
||||
# Set a counter to an absolute value
|
||||
!editcounter deaths 0
|
||||
|
||||
# Increment a counter
|
||||
!editcounter deaths +1
|
||||
|
||||
# Decrement a counter
|
||||
!editcounter deaths -3
|
||||
|
||||
# Nested placeholders: random range from arguments
|
||||
!addcommand !customrand $(rand $(1) $(2))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user