Tiny, tiny, discord nuker lib in python.
- Make sure you have a bot.
- Go to your bot page in the discord developer portal, scroll down a bit and check every "privileged intent"
- Download nuker.py and requirements.txt
- Install the requirements by using pip install -r requirements.txt
- In your file, include the nuker lib using
from nuker import nuker
- Well... Boom! You've successfully set it up.
myNuker = nuker("token here", prefix=prefix, invis=True / False, ownerid=yourownerid, assignCmd=True / False)
The token should be a bot token. If you do not supply a prefix, it will default to "!". Invis will immediately set the bot's status to invisible when you run it if it is set to true. It also defaults to true. Ownerid is the user id of the owner. With this set, the only person who will be able to use commands is the user with the id. If you do not set it, it will default to none. AssignCmd simply determines if the assignCmd command will exist.
Now, how would you assign commands? You would use the assignCommand method.
myNuker = nuker("token here", prefix=prefix, invis=True / False, ownerid=yourownerid)
myNuker.assignCommand(typeofcommand, nameofcommand)
Command types consist of "delchannels", "delroles", "masschannel", "massrole", "massnick", "masskick", and "massban".
You may also use the default set assignCmd command, which will be documented below.
There are no parameters to this. This will simply load the bot.
myNuker = nuker("token here", prefix=prefix, invis=True / False, ownerid=yourownerid)
myNuker.assignCommand(typeofcommand, nameofcommand)
myNuker.run()
Command types: "delchannels", "delroles", "masschannel", "massrole", "massnick", "masskick", and "massban"
Syntax for the commands.
{prefix}assignCmd [nameofcommand, typeofcommand]
This will assign a certain command to a certain function. For example, if you were to send "!assignCmd joe masschannel" and then use "!joe 10 rand" It would create 10 random channels.
{prefix}delchannels [no args]
This will delete all channels. Pretty quickly, in fact!
{prefix}delroles [no args]
This will delete all roles.
{prefix}masschannel [optional: amount, optional: name]
If no args are specified, it will do 100 random channels. If no name is specified, it will do random names. If the name value is "rand" it will random names.
{prefix}massrole [optional: amount, optional: name]
If no args are specified, it will do 50 random roles. If no name is specified, it will do random names. If the name value is "rand" it will random names.
{prefix}massnick [male/female/all, filter, nick]
The male/female/all arg is in case you wish for a random nick. If you do, "male" will use male names and "female" will use female names. Any other arg will use all nicknames. The filter arg is if you only want to nick people who have a certain username. If you do, you would specify the username in that arg. Sadly, spaces are not supported as of now. If you do not wish to filter, just supply "*". The nick arg is, well, what you want to nickname the people. If it is "rand", it will use names that you specified in the first argument.
{prefix}masskick [optional: reason]
This command will kick everyone.
{prefix}massban [optional: reason]
This command will ban everyone.