GDScript: allow local classes to be used as types
This commit is contained in:
parent
2c9536b655
commit
ba13aae9af
1 changed files with 6 additions and 0 deletions
|
@ -5438,6 +5438,12 @@ GDScriptParser::DataType GDScriptParser::_resolve_type(const DataType &p_source,
|
|||
// Inner classes
|
||||
ClassNode *outer_class = p;
|
||||
while (outer_class) {
|
||||
if (outer_class->name == id) {
|
||||
found = true;
|
||||
result.kind = DataType::CLASS;
|
||||
result.class_type = outer_class;
|
||||
break;
|
||||
}
|
||||
for (int i = 0; i < outer_class->subclasses.size(); i++) {
|
||||
if (outer_class->subclasses[i] == p) {
|
||||
continue;
|
||||
|
|
Loading…
Reference in a new issue