mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-06 03:08:55 -05:00
[Docs] More detailed info about args in Getting Started (#4058)
* initial removal and partial re-adition * lets not miss a line in removal * dont merge yet Co-authored-by: jack1142 <6032823+jack1142@users.noreply.github.com> * yep ready now i think Co-authored-by: jack1142 <6032823+jack1142@users.noreply.github.com>
This commit is contained in:
parent
4453b5653a
commit
4fdea931b9
@ -81,15 +81,23 @@ parameters.
|
||||
|
||||
[p]help command
|
||||
|
||||
The parameters are shown as enclosed in ``< >`` if they're required, or
|
||||
``[ ]`` if optional.
|
||||
As an example, the ban command will show this in the help message, assuming
|
||||
your prefix is ``!``:
|
||||
``Syntax: !ban <user> [days] [reason]``
|
||||
.. note::
|
||||
Arguments enclosed in ``< >`` are **required** for the command to work.
|
||||
|
||||
This means that it is necessary to provide ``user``. However, the
|
||||
``days`` value (number of messages to delete) is optional, as well as
|
||||
the ``reason`` value, used for the modlog.
|
||||
Arguments enclosed in ``[ ]`` are **optional** for the command;
|
||||
you can decide whether to use them or not.
|
||||
|
||||
If your argument includes spaces like ``Hello world!``, most of the time
|
||||
you will need to place it in double quotes like this: ``"Hello world!"``.
|
||||
Sometimes (especially for the last argument) these double quotes are not
|
||||
required.
|
||||
|
||||
Arguments followed by ``=value`` means that, if not specified,
|
||||
the argument will be equal to ``value``.
|
||||
|
||||
For example, the command ``[p]cleanup messages`` in the cleanup cog has
|
||||
the syntax ``cleanup messages <number> [delete_pinned=False]``, which means
|
||||
``delete_pinned`` default will be false, unless you specify it as true.
|
||||
|
||||
You can use help to show the **categories** too, generally called cogs.
|
||||
Just do something like this (notice the capitalization):
|
||||
@ -339,23 +347,4 @@ The cog guides are formatted the same. They're divided into 3 sections:
|
||||
|
||||
* **Arguments**
|
||||
|
||||
A list of all arguments needed (or not) for the command, with more details.
|
||||
|
||||
.. tip::
|
||||
Arguments enclosed in ``< >`` means that the argument is **required**
|
||||
for the command to work.
|
||||
|
||||
Arguments enclosed in ``[ ]`` means that the argument is **optional**
|
||||
for the command; you can decide to use it or not.
|
||||
|
||||
If your argument includes spaces like ``Hello world!``, most of the time
|
||||
you will need to place it in double quotes like this: ``"Hello world!"``.
|
||||
Sometimes (especially for the last argument) these double quotes are not
|
||||
required.
|
||||
|
||||
Arguments followed by ``=something`` means that, if not specified,
|
||||
the argument will be equal to ``something``.
|
||||
|
||||
For example, ``[days=1]`` in the ``ban`` command means that the number
|
||||
of days of messages to be deleted will be equal to ``1`` if not
|
||||
specified.
|
||||
A list of all arguments needed (or not) for the command, with more details.
|
||||
Loading…
x
Reference in New Issue
Block a user