diff --git a/src/scripting/backend/codegen.cpp b/src/scripting/backend/codegen.cpp index 2af0f9ae7..249537aaa 100644 --- a/src/scripting/backend/codegen.cpp +++ b/src/scripting/backend/codegen.cpp @@ -6464,6 +6464,12 @@ FxExpression *FxMemberIdentifier::Resolve(FCompileContext& ctx) } } } + else + { + ScriptPosition.Message(MSG_ERROR, "%s is not a member of %s", Identifier.GetChars(), ccls->TypeName.GetChars()); + delete this; + return nullptr; + } } }