Alright, enough theory. How do we actually do this in Godot? Turns out, Godot gives us some pretty cool tools to make this happen, mainly revolving around the
node.
The basic idea is to have a second camera in your scene that's only looking at the things you want on the minimap, & then display what that camera sees inside a UI element.
The magic starts with a
node. This node essentially creates a separate rendering surface. You can then put a
or
inside it to capture your scene from a different perspective (like a top-down view).
To actually SEE what this
is capturing, you need to display it in a
. This container takes the output of its
child & renders it as a regular UI element. Pretty cool, right?