ItemVaultLogger: static-singleton log facade for the plugin. Addon scripts route runtime output through error / warn / info instead of Godot's push_error / push_warning so a game can redirect, filter, or suppress it. Games inject an ItemVaultLogSink via set_log_sink() at boot. With no sink (or after the game releases it), logging routes through Godot's push_error / push_warning / print, preserving editor + stderr output. Static singleton on purpose: plugins avoid wiring a logger into every script, and games set the sink once. Call sites stay close to plain push_warning with no constructor parameters or scene wiring. Usage: var _sink := MyGameLogSink.new() ItemVaultLogger.set_log_sink(_sink) ItemVaultLogger.error("InventorySave", "version mismatch")
Source: addons/item_vault/logging/item_vault_logger.gd
Syntax
class ItemVaultLogger extends RefCountedMembers
| Name | Kind | Summary |
|---|---|---|
set_log_sink | Method | |
clear_log_sink | Method | |
get_log_sink | Method | |
error | Method | |
warn | Method | |
info | Method | |
error | Method | |
warn | Method | |
info | Method |