The ETraceTypeQuery and EObjectTypeQuery enums declared in EngineTypes.h aren't fully exposed to Python. Both enums have 32 entries, but Python is only aware of the first 2 for ETraceTypeQuery and the first 6 for ObjectTypeQuery. This is reflected on the API docs as well (unreal.TraceTypeQuery, unreal.ObjectTypeQuery).
Type the following in the Python console within the editor:
print(unreal.TraceTypeQuery.TRACE_TYPE_QUERY1)
Note the output: <TraceTypeQuery.TRACE_TYPE_QUERY1: 0>
Type the following in the Python console within the editor:
print(unreal.TraceTypeQuery.TRACE_TYPE_QUERY3)
Editor will display an error
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-130769 in the post.
| 1 |
| Component | UE - Editor - Workflow Systems |
|---|---|
| Affects Versions | 4.27, 5.1 |
| Target Fix | 5.1 |
| Created | Oct 5, 2021 |
|---|---|
| Resolved | Aug 31, 2022 |
| Updated | Jan 22, 2024 |