-
Couldn't load subscription status.
- Fork 44
Open
Labels
enhancementNew feature or requestNew feature or request
Milestone
Description
this includes prefixing the source file that started the log
static func log_prefix(stack) -> String:
if len(stack) > 1:
var call_site = stack[1]
var basename = call_site["source"].get_file().get_basename()
var line_num = str(call_site.get("line", 0))
if call_site["source"].match("*/test/*"):
return "{" + basename + ":" + line_num + "}: "
elif call_site["source"].match("*/addons/*"):
return "<" + basename + ":" + line_num + ">: "
else:
return "[" + basename + ":" + line_num + "]: "
return ""ref https://github.com/russmatney/log.gd/blob/main/addons/log/log.gd#L516-L527
and also print_rich when in the editor to use
- colors for each log level and
- reduce visual noise by hiding information like timestamps or
- the mod loader log names within bbcode hint tags (
[hint={tooltip text displayed on hover}]{text}[/hint])
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request