How to remove meta data

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Hubber116sx

How do you remove meta data from a node? I can’t find any remove_meta() function.

:bust_in_silhouette: Reply From: Kyle Guarco

Browsing Godot’s source code gives you the answer. It isn’t very clear at first, but setting the value to null erases the key.

From godot/object.cpp:L1048 (blob from the 3.1 branch):

if (p_value.get_type() == Variant::NIL) {

EDIT Switched the blob to the 3.1 branch for accuracy.