Reword editor warning for ItemSelection
This commit is contained in:
parent
b4772546b3
commit
5d02cd16c7
|
@ -17,11 +17,15 @@ var item_count: int:
|
||||||
|
|
||||||
func _get_configuration_warnings() -> PackedStringArray:
|
func _get_configuration_warnings() -> PackedStringArray:
|
||||||
var warnings := PackedStringArray()
|
var warnings := PackedStringArray()
|
||||||
|
var children := get_children()
|
||||||
|
|
||||||
|
if not(children.is_empty()):
|
||||||
|
var self_class_name := get_class()
|
||||||
|
|
||||||
for child in get_children():
|
for child in get_children():
|
||||||
warnings.append(
|
warnings.append(
|
||||||
"ItemSelection can only have children of type Button, but {0} is of type {1}".format(
|
"{0} can only have Button children, but {1} is of type {2}".format(
|
||||||
[child.name, child.get_class()]))
|
[self_class_name, child.name, child.get_class()]))
|
||||||
|
|
||||||
return warnings
|
return warnings
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue