尝试大改,可读性有点差的版本,基本做到能实时处理弹幕

This commit is contained in:
2022-06-03 23:08:43 +08:00
parent 3f95b07009
commit 74a15849ab
16 changed files with 181 additions and 204 deletions

33
output/print.py Normal file
View File

@ -0,0 +1,33 @@
from colorama import init, Fore
from output import IOutput
RED = Fore.RED
GREEN = Fore.GREEN
BLUE = Fore.BLUE
CYAN = Fore.CYAN
MAGENTA = Fore.MAGENTA
YELLOW = Fore.YELLOW
WHITE = Fore.WHITE
RESET = Fore.RESET
init()
class Print(IOutput):
def chat_output(self, msg):
print(f"\n{BLUE}[+] {msg} {RESET}")
def like_output(self, msg):
print(f"\n{CYAN}[+] {msg} {RESET}")
def member_output(self, msg):
print(f"\n{RED}[+] {msg} {RESET}")
def social_output(self, msg):
print(f"\n{GREEN}[+] {msg} {RESET}")
def gift_output(self, msg):
print(f"\n{MAGENTA}[+] {msg} {RESET}")
def userseq_output(self, msg):
print(f"\n{YELLOW}[+] {msg} {RESET}")