diff --git a/cmake/scripts/SquirrelExport.cmake b/cmake/scripts/SquirrelExport.cmake index d0c2283550..c1305066ab 100644 --- a/cmake/scripts/SquirrelExport.cmake +++ b/cmake/scripts/SquirrelExport.cmake @@ -342,7 +342,7 @@ foreach(LINE IN LISTS SOURCE_LINES) else() string(APPEND SQUIRREL_EXPORT "\n SQ${API_CLS}.PreRegister(engine, \"${API_SUPER_CLS}\");") endif() - if(NOT "${SUPER_CLS}" STREQUAL "ScriptEvent") + if(NOT "${SUPER_CLS}" MATCHES "^ScriptEvent") if("${CLS_PARAM_2}" STREQUAL "v") string(APPEND SQUIRREL_EXPORT "\n SQ${API_CLS}.AddSQAdvancedConstructor(engine);") else()