2024-09-12 22:51:39 +02:00
|
|
|
|
|
|
|
# -------------------------------------------------------------------
|
|
|
|
# ORTHOGRAPHIC
|
|
|
|
# Your personal aerial satellite. Always on. At any altitude.*
|
|
|
|
# Developed by MarStrMind
|
|
|
|
# License: Open Software License 3.0
|
|
|
|
# Up to date version always on marstr.online
|
|
|
|
# -------------------------------------------------------------------
|
|
|
|
# log.py
|
|
|
|
# Convenience call to log output
|
|
|
|
# -------------------------------------------------------------------
|
|
|
|
|
|
|
|
import datetime
|
2024-12-17 17:18:05 +01:00
|
|
|
from colorama import init as colorama_init
|
|
|
|
from colorama import Fore
|
|
|
|
from colorama import Style
|
2024-09-12 22:51:39 +02:00
|
|
|
from defines import *
|
|
|
|
|
|
|
|
def mstr_msg(fnc, msg):
|
|
|
|
if mstr_show_log == True:
|
2024-12-17 17:18:05 +01:00
|
|
|
colorama_init()
|
2024-09-12 22:51:39 +02:00
|
|
|
now = datetime.datetime.now()
|
2024-12-17 17:18:05 +01:00
|
|
|
|
|
|
|
print(f' {Fore.GREEN}'+now.strftime("%H:%M:%S")+f'{Style.RESET_ALL} | {Fore.YELLOW}[' + fnc + f']{Style.RESET_ALL} | {Fore.CYAN}'+ msg + f'{Style.RESET_ALL}')
|
|
|
|
#print(f"{Fore.GREEN}" + now.strftime(" %H:%M:%S" + " | ["+fnc+"] | " + msg))
|