I see there is get_property_list()
, accordint to the doc it should return this:
Return the list of properties as an array of dictionaries, dictionaries contain: name:String, type:int (see TYPE_* enum in globals) and optionally: hint:int (see PROPERTY_HINT_* in globals), hint_string:String, usage:int (see PROPERTY_USAGE_* in globals).
So I tried:
class Foo:
var one = 1
var two = "two"
var three
func _ready():
var obj = Foo.new()
var list = obj.get_property_list()
for d in list:
print("> " + d["name"])
But the result is completely off Oo
> Reference
I tried this instead:
var list = Foo.get_property_list()
for d in list:
print("> " + d["name"])
More weirdness :o
> Reference
> Resource
> resource/path
> resource/name
> Script
> GDScript
> script/source
Either its a bug, or the function is badly named...