Skip to content

Commit c5204a2

Browse files
AThousandShipsdsnopek
authored andcommitted
Add default argument processing for NodePath
(cherry picked from commit 37e7a6d)
1 parent a6e5caa commit c5204a2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

binding_generator.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2431,6 +2431,7 @@ def correct_default_value(value, type_name):
24312431
"null": "nullptr",
24322432
'""': "String()",
24332433
'&""': "StringName()",
2434+
'^""': "NodePath()",
24342435
"[]": "Array()",
24352436
"{}": "Dictionary()",
24362437
"Transform2D(1, 0, 0, 1, 0, 0)": "Transform2D()", # Default transform.
@@ -2444,6 +2445,8 @@ def correct_default_value(value, type_name):
24442445
return f"{{}}"
24452446
if value.startswith("&"):
24462447
return value[1::]
2448+
if value.startswith("^"):
2449+
return value[1::]
24472450
return value
24482451

24492452

0 commit comments

Comments
 (0)