Merge pull request #96330 from rune-scape/little-regression

GDScript: Fix small mistake in script valid checks
This commit is contained in:
Rémi Verschelde 2024-09-04 18:55:31 +02:00
commit dbdc4eb204
No known key found for this signature in database
GPG Key ID: C3336907360768E1

View File

@ -138,7 +138,7 @@ void GDScript::_super_implicit_constructor(GDScript *p_script, GDScriptInstance
}
}
ERR_FAIL_NULL(p_script->implicit_initializer);
if (likely(valid)) {
if (likely(p_script->valid)) {
p_script->implicit_initializer->call(p_instance, nullptr, 0, r_error);
} else {
r_error.error = Callable::CallError::CALL_ERROR_INVALID_METHOD;