File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
addons/block_code/block_code_node Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -85,7 +85,9 @@ func _get_configuration_warnings():
85
85
if get_parent () is BlockCode :
86
86
warnings .append ("The parent must not be a BlockCode." )
87
87
if get_parent ().script :
88
- warnings .append ("This BlockCode will override the existing script in the parent node." )
88
+ var parent_script_name : StringName = get_parent ().script .get_global_name ()
89
+ if not (parent_script_name and block_script and parent_script_name == block_script .script_inherits ):
90
+ warnings .append ("This BlockCode will override the existing script in the parent node." )
89
91
if get_parent ().find_children ("*" , "BlockCode" , false ).size () > 1 :
90
92
warnings .append ("The parent should only contain one BlockCode." )
91
93
if block_script and _get_custom_or_native_class (get_parent ()) != block_script .script_inherits :
You can’t perform that action at this time.
0 commit comments