-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdctool.py
79 lines (68 loc) · 2.71 KB
/
dctool.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
import Client
import Exploits
import requests
import traceback
import time
from consolemenu import ConsoleMenu
from consolemenu.items import SubmenuItem, FunctionItem
from threading import Thread
def about():
print('''Discord Tool v0.1.3
Alpha version, expect spectacular bugs
Coded by Raffy E
\tThanks to Discord for the available API endpoints
\tThere should be more of them, just saying
Who even cares at this point''')
input()
def safe_remove_menu(task_menu):
time.sleep(1)
tasks_menu.remove_item(task_menu)
def terminate_task(task, name, task_menu):
print(f'[{name}]\nTerminating...')
task.run = False
task.join()
print('Done.')
input()
Thread(target=safe_remove_menu, args=[task_menu]).start()
def create_task(name, main, *arg):
print(f'[{name}]')
args = []
for a in arg:
args.append(input(a + ': '))
task = Thread(target=main, args=args)
task_menu = FunctionItem(name, terminate_task, [task, name], should_exit=True)
task_menu.args.append(task_menu)
tasks_menu.append_item(task_menu)
task.start()
print('Started successfully.')
input()
Client.login()
gen_menu = ConsoleMenu('Send messages and files')
gen_menu.append_item(FunctionItem('Send message', Client.send_message))
gen_menu.append_item(FunctionItem('Send file', Client.send_file))
gen_menu.append_item(FunctionItem('Bulk send', Client.bulk_send))
gen_menu.append_item(FunctionItem('User info', Client.user_info))
gen_menu.append_item(FunctionItem('Server list', Client.get_servers))
gen_menu.append_item(FunctionItem('Member list', Client.create_list))
gen_menu.append_item(FunctionItem('Download avatar', Client.download_avatar))
exploit_menu = ConsoleMenu('Exploits and misc features')
exploit_menu.append_item(FunctionItem('Infinite typing', create_task,
['Infinite typing', Exploits.typing, 'Channel ID']
))
exploit_menu.append_item(FunctionItem('Status changer', create_task,
['Status changer', Exploits.status_changer]
))
exploit_menu.append_item(FunctionItem('Friend finder', Exploits.friend_list))
exploit_menu.append_item(FunctionItem('Crash link', Exploits.crash_link))
exploit_menu.append_item(FunctionItem('Local Storage reassembly', Exploits.reassembly))
tasks_menu = ConsoleMenu('Terminate running tasks')
menu = ConsoleMenu('Discord Tool v0.1.3')
menu.append_item(FunctionItem('Info', Client.info))
menu.append_item(SubmenuItem('General', gen_menu, menu=menu))
menu.append_item(SubmenuItem('Exploits', exploit_menu, menu=menu))
menu.append_item(SubmenuItem('Tasks', tasks_menu, menu=menu))
menu.append_item(FunctionItem('About', about))
menu.formatter.set_items_bottom_padding(0)
menu.formatter.set_items_top_padding(0)
menu.formatter.set_title_align(align='center')
menu.show()