Sets up initial project structure
Initializes the project with core files including: - Editor configuration (.editorconfig, .gitattributes, .gitignore, .vscode/settings.json) - Log.gd addon for enhanced debugging - Loggie addon for advanced logging - Project assets folder
This commit is contained in:
parent
f8140c83ff
commit
02b3be35b0
144 changed files with 7399 additions and 0 deletions
21
addons/loggie/channels/terminal.gd
Normal file
21
addons/loggie/channels/terminal.gd
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
class_name TerminalLoggieMsgChannel extends LoggieMsgChannel
|
||||
|
||||
func _init() -> void:
|
||||
self.ID = "terminal"
|
||||
self.preprocess_flags = 0 # For this type of channel, this will be applied dynamically by Loggie after it loads LoggieSettings.
|
||||
|
||||
func send(msg : LoggieMsg, msg_type : LoggieEnums.MsgType):
|
||||
var loggie = msg.get_logger()
|
||||
var text = LoggieTools.convert_string_to_format_mode(msg.last_preprocess_result, loggie.settings.msg_format_mode)
|
||||
|
||||
match loggie.settings.msg_format_mode:
|
||||
LoggieEnums.MsgFormatMode.ANSI, LoggieEnums.MsgFormatMode.BBCODE:
|
||||
print_rich(text)
|
||||
LoggieEnums.MsgFormatMode.PLAIN, _:
|
||||
print(text)
|
||||
|
||||
# Dump a non-preprocessed terminal-ready version of the message in additional ways if that has been configured.
|
||||
if msg_type == LoggieEnums.MsgType.ERROR and loggie.settings.print_errors_to_console:
|
||||
push_error(LoggieTools.convert_string_to_format_mode(msg.string(), LoggieEnums.MsgFormatMode.PLAIN))
|
||||
if msg_type == LoggieEnums.MsgType.WARNING and loggie.settings.print_warnings_to_console:
|
||||
push_warning(LoggieTools.convert_string_to_format_mode(msg.string(), LoggieEnums.MsgFormatMode.PLAIN))
|
||||
Loading…
Add table
Add a link
Reference in a new issue