forked from OlympicCode/vHackOSBot-Python
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcoloredterm.py
43 lines (33 loc) · 1.18 KB
/
coloredterm.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
from colorama import init
from colorama import Fore, Back, Style
init()
class colored():
def __init__(self, msglog, message):
self.mlog = msglog
self.msg = message
def autocolored(self):
color = {
#global message
"ErrorRequest": Fore.RED,
"ErrorJson": Fore.RED,
"BadRequest": Fore.RED,
"showResult": Fore.RED,
# update message
"showMsgUpdatefull": Fore.BLUE,
"showMsgUpdate": Fore.BLUE,
# Network message
"showMsgEndAttack": Fore.GREEN,
"showMsgErrorAPI": Fore.GREEN,
"showMsgDoesntPossibleAttack": Fore.BLUE,
"showMsgWriteLog": Fore.YELLOW,
"showMsgCollectMoneyUser": Fore.BLUE,
"showMsgErrorSdk=0": Fore.BLUE,
"showMsgCollectMoneyUser": Fore.BLUE,
"showMsgCollectMoneyUser": Fore.BLUE,
"showMsgGenerateMWK": Fore.BLUE,
#Miner message
"MinerMsgLeft": Fore.BLUE,
"MinerStarting": Fore.BLUE,
"MinerMsgTime": Fore.BLUE
}
return "{} {} {}".format(color[self.mlog], self.msg, Style.RESET_ALL)