This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extends Node2D | |
class_name LayeredVisual2D | |
# TODO: add visibility checks, to cull rendering + updating layers if not within screen rect | |
@export var source_node_path: NodePath | |
@export var source_node_bounds: Rect2 | |
@export_group("Layer", "layer_") | |
@export var layer_count: int = 4 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extends Node | |
# Produces manual profiling results, utilizing Google's Trace Event Format for analysis with profilers tools! | |
# - Details of the format here: https://docs.google.com/document/d/1CvAClvFfyA5R-PhYUmn5OOQtYMH4h6I0nSsKchNAySU/preview | |
# | |
# Instructions: | |
# - Add as an autoload to your project, preferably first if your other autoloads want to (maybe) use this during `_ready()` | |
# - Call `start_benchmark(_label: StringName)` to signal the start of a function/scope/etc, the label is unused and purely for code reading clarity | |
# - Call `end_benchmark(label: StringName)` to end the profile for a function/scope/etc | |
# - Then during runtime, the profiling results will be stored and on runtime exit, serialized for usage externally |