microsoft / microsoft/vscode-cpptools

Add better IntelliSense support for Unreal Engine UPROPERTY

Open
#10,308 8 comments 7 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Feature Request Language Service
Dominant language
TypeScript
Stars
6.2k
Forks
1.7k
Avg merge
14h 46m
Merged PRs (30d)
61

Description

    Just wanted to tell you my experiences

I am a VSCode user and I always like to setup all my dev environment in it because it is so handy,
but with UE there are some weird behavior with it

I was watching a video that the guy was using CLion or Netbeans or whatever for UE dev and as soon as he typed UPE.., UPROPERTY appeared and as soon as he typed parenthesis (like UPROPERTY(..) ) it lists all the ObjectMacros.h UP Enum elements that can be used in UPROPERTY. I don't know how it detect which filed should be showed up but it would be amazing if we have such thing in vscode

When I tried to do that, vscode didn't even show me the UPROPERTY

image

I have "compileCommands": "../MyProject/.vscode/compileCommands_Default.json", and I realized that ObjectMacros.h is in this path C:\Program Files\Epic Games\UE_5.1\Engine\Source\Runtime\CoreUObject\Public\UObject and this path is in this rsp file C:\Program Files\Epic Games\UE_5.1\.vscode\compileCommands_Default\CoreUObject.270.rsp as /I "C:\Program Files\Epic Games\UE_5.1\Engine\Source\Runtime\CoreUObject\Public" that is the parent folder of UObject folder, but it contains CoreUObject.h header file that included #include "UObject/ObjectMacros.h"

so theoretically it should show EditDefaultsOnly or other enum elements in vscode but it doesn't!

this is my includePath

"includePath": [
                "${workspaceFolder}/Source/**",
                "${workspaceFolder}/Plugins/**",
                "${workspaceFolder}/Intermediate/**",
                "C:/Program Files/Epic Games/UE_5.1/Engine/**"

with or without it, it does not work!

this is mine

image

any idea?

Originally posted by @madoodia in https://github.com/microsoft/vscode-cpptools/issues/5849#issuecomment-1363282154

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the missing completions using ObjectMacros.h, CoreUObject.h, the CoreUObject.270.rsp file, and the supplied compileCommands and includePath settings. Start by checking IntelliSense completion behavior for UPROPERTY and its enum elements; done means UPROPERTY and options such as EditDefaultsOnly are suggested in the Unreal Engine setup.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, unreal-engine, vscode
Domain
developer-experience, tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.