You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-09 12:50:35 +00:00
Improve to_string() and add it to Resource
This commit is contained in:
@@ -1044,7 +1044,7 @@ String Object::to_string() {
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
return "<" + get_class() + "#" + itos(get_instance_id()) + ">";
|
||||
return _to_string();
|
||||
}
|
||||
|
||||
void Object::set_script_and_instance(const Variant &p_script, ScriptInstance *p_instance) {
|
||||
@@ -1850,6 +1850,10 @@ void Object::notify_property_list_changed() {
|
||||
emit_signal(CoreStringName(property_list_changed));
|
||||
}
|
||||
|
||||
String Object::_to_string() {
|
||||
return "<" + get_class() + "#" + itos(get_instance_id()) + ">";
|
||||
}
|
||||
|
||||
void Object::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("get_class"), &Object::get_class);
|
||||
ClassDB::bind_method(D_METHOD("is_class", "class"), &Object::is_class);
|
||||
|
||||
Reference in New Issue
Block a user