Edit of asset "CLog" Rejected
This asset edit has been rejected. Reason: Download URL responds with "not found".
| Old/Current | New/Edit | |
|---|---|---|
| Title | CLog | |
| Description |
v1.0.6: Improved to display timer output. CLog is a simple logging utility for Godot 4. It provides enhanced console output with support for source code links, colors, and performance timers. ──────────────────────── Compatibility ──────────────────────── Supports Godot 4.5 or later. ──────────────────────── Features ──────────────────────── * Source Navigation Clicking on a log entry in the console will take you directly to the source code. * Rich Text Output Supports colored logs and text formatting. * Performance Timers Measure execution time with starting, ending, and canceling timers. Note: Source navigation is implemented using a workaround. If navigation stops working, try restarting the plugin or the editor. In IDEs such as VS Code, you can jump to the source code by using Ctrl + Click on the file path. VS Code Display Example: (media/vscode_demo.png) ──────────────────────── Usage ──────────────────────── Standard Output Logs a simple message to the console. ```gdscript CLog.o("Some message") CLog.o("Value A:", 100, "Value B:", true) ``` ──────────────────────── Error Logging Logs an error message with a highlighted style. ```gdscript CLog.e("An error occurred") ``` ──────────────────────── Warning Logging Logs a warning message. ```gdscript CLog.w("This is a warning") ``` Both CLog.e and CLog.w internally call push_error() and push_warning() respectively. This ensures they appear in Godot’s Debugger panel and are recorded in the built-in engine logs. ──────────────────────── Custom Color Output Logs a message using a specific color. ```gdscript CLog.c(Color.ORANGE, "Custom orange message") ``` ──────────────────────── Once (log once by key) Logs a message only once for a specific unique key. This is useful for logging inside _process() or loops without flooding the console. ```gdscript func _process(_delta: float): # This will be printed only once for the key &"start_processing" CLog.once(&"start_processing", "Process loop started") ``` ──────────────────────── Performance Timers Measure how long a specific process takes. ```gdscript # Start a timer var id = CLog.timer_start("Process Name") # End the timer and print elapsed time CLog.timer_end(id) # Cancel the timer without printing CLog.timer_cancel(id) ``` ──────────────────────── Release Mode Logging By default, CLog suppresses output in release builds for performance and security. This behavior can be toggled using the disable_output_on_release_mode property. ```gdscript # Enable logging even in release mode CLog.disable_output_on_release_mode = false ``` |
|
| Category | Tools | |
| License | MIT | |
| Repository Provider | Custom | |
| Repository Url | https://github.com/anchork/CLog_for_Godot4 | |
| Issues Url | https://github.com/anchork/CLog_for_Godot4/issues | |
| Godot version | Godot 4.5 | |
| Version String | 1.0.6 | 1.0.3 |
| Download Commit | https://github.com/anchork/CLog_for_Godot4/releases/download/v1.0.6/clog-v1.0.6.zip | https://github.com/anchork/CLog_for_Godot4/releases/download/v1.0.3/clog.zip |
| Download Url (Computed) | https://github.com/anchork/CLog_for_Godot4/releases/download/v1.0.6/clog-v1.0.6.zip | https://github.com/anchork/CLog_for_Godot4/releases/download/v1.0.3/clog.zip |
| Icon Url |
https://raw.githubusercontent.com/anchork/CLog_for_Godot4/refs/heads/main/media/icon.png
|
|