Unreal version 4.26.2 (it was compiled a week ago and the release date is 14th April.
Linux Ubuntu 20.04
Intellisense was so bad that for the BullCows project all the code beneath the #include … lines was underlined in red squiggles!
The code compliled fine, as the fault was with Intellisense only.
Other users on other Unreal forums said that this was due to Intellisense not knowing where the #include … .h files were (even though VS Code compiler knew).
EDIT:
If I may ask, did previous fixes involve pasting about 200 lines worth into the “defines”: section of the configuration files ?
https://drive.google.com/file/d/10TyPGe_3xewDJ9SCqYg1eHgrByNFXIoG/view
Here is the link.
However it appears to be for Windows users.
Is there a similar fix we should be aware of ?
EDIT 2:
Intellisense Error Output in VS Code:
[10/06/2021, 9:48:04 pm] For C source files, IntelliSenseMode was changed from "linux-clang-x64" to "linux-gcc-x64" based on compiler args and querying compilerPath: "/usr/bin/gcc"
[10/06/2021, 9:48:05 pm] For C++ source files, IntelliSenseMode was changed from "linux-clang-x64" to "linux-gcc-x64" based on compiler args and querying compilerPath: "/usr/bin/gcc"
[10/06/2021, 9:48:05 pm] Unable to resolve configuration with compilerPath "cl.exe". Using "/usr/bin/gcc" instead.
[10/06/2021, 9:48:18 pm] "Grabber.cpp" not found in "/home/chickpea/ue/UnrealEngine/Engine/Source/ThirdParty/ShaderConductor/ShaderConductor/External/DirectXShaderCompiler/tools/clang/bindings/python/tests/cindex/INPUTS/compile_commands.json". 'includePath' from c_cpp_properties.json in folder 'Building_Escape' will be used for this file instead.
[10/06/2021, 9:53:40 pm] "Grabber.cpp" not found in "/home/chickpea/ue/UnrealEngine/Engine/Source/ThirdParty/ShaderConductor/ShaderConductor/External/DirectXShaderCompiler/tools/clang/bindings/python/tests/cindex/INPUTS/compile_commands.json". 'includePath' from c_cpp_properties.json in folder 'Building_Escape' will be used for this file instead.
Note: even adding the directory containing Grabber.cpp into the c_cpp_properties.json file will not enable Intellisense to see the file.
Hovering over #include “Grabber.h” in the Grabber.cpp file which is part of our Building Escape tutorial reveals:
#include errors detected. Consider updating your compile_commands.json or includePath. Squiggles are disabled for this translation unit (/home/chickpea/Documents/Unreal Projects/Building_Escape/Source/Building_Escape/Grabber.cpp).C/C++(1696)
cannot open source file "UBT_COMPILED_PLATFORM/UBT_COMPILED_PLATFORMPlatformCompilerPreSetup.h" (dependency of "Grabber.h")C/C++(1696)
Hovering over #include “Engine/World.h” reveals:
cannot open source file "Engine/World.h"C/C++(1696)
I have already added the directories containing each of these header files into c_cpp_properties.json file.
{
"name": "Linux",
"includePath": [
"/usr/include",
"/usr/local/include",
"/usr/include/c++/7.2.0",
"/usr/include/c++/7.2.0/backward",
"/usr/include/c++/7.2.0/bits",
"/usr/include/linux",
"/usr/include/x86_64-linux-gnu",
"/usr/include/x86_64-linux-gnu/c++/7.2.0",
"${workspaceRoot}",
"/home/chickpea/Documents/Unreal Projects/Building_Escape/Source",
"/home/chickpea/ue/UnrealEngine/Engine/Source/Runtime/Core/Public",
"/home/chickpea/ue/UnrealEngine/Engine/Source/Runtime/Engine/Classes/Engine"
],
"defines": ["${default}"],
"intelliSenseMode": "clang-x64",
"browse": {
"path": [
"/usr/include",
"/usr/local/include",
"${workspaceRoot}"
],
"limitSymbolsToIncludedHeaders": true,
"databaseFilename": ""
},
"compilerPath": "/usr/bin/gcc",
"cStandard": "gnu17",
"cppStandard": "gnu++14",
"compileCommands": "/home/chickpea/ue/UnrealEngine/Engine/Source/ThirdParty/ShaderConductor/ShaderConductor/External/DirectXShaderCompiler/tools/clang/bindings/python/tests/cindex/INPUTS/compile_commands.json"
}
I wish I were more knowledgeable on this subject.
I’m not sure where to look - are there quirks that experienced folk are aware of?