fix: guard pre-5.4/5.5 UE APIs so the plugin builds on older UE (verified 5.3) - #493
Conversation
…fied 5.3) Three files used newer-UE APIs without the version guards used elsewhere in the plugin, breaking compilation on UE older than 5.4/5.5: - EAllowShrinking::No overload of FString::RightChopInline/LeftInline (UE 5.4+) - standalone PhysicsEngine/SkeletalBodySetup.h include (UE 5.5+) - redundant UObject/StrProperty.h include Added the same #if ENGINE_MAJOR_VERSION == 5 && ENGINE_MINOR_VERSION >= N guards used elsewhere and dropped the redundant include (FStrProperty comes from the already-included UObject/UnrealType.h). Verified building cleanly on UE 5.3.2. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
👋 Thanks for your first Pull Request! We love contributions. Please ensure you have signed off your commits and followed the contribution guidelines. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
💤 Files with no reviewable changes (1)
📝 WalkthroughSummary by CodeRabbit
WalkthroughAdds ChangesUE Version Compatibility Fixes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~5 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Fixes #492.
Three files used newer-UE APIs without the version guards used elsewhere in the plugin, breaking compilation on UE older than 5.4 / 5.5. Verified building cleanly on UE 5.3.2 (0 errors,
UnrealEditor-McpAutomationBridge.dlllinks). I built 5.3 specifically; the guards restore the pre-5.4 / pre-5.5 API forms, but I have not independently built 5.0–5.2. Guard style matchesCore/Compatibility/McpVersionCompatibility.h.Changes
EAllowShrinking::Nooverload (UE 5.4+) — guarded with>= 4; falls back to thebooloverload on ≤5.3 (two call sites in…EnvironmentSnapshotPaths.cpp).PhysicsEngine/SkeletalBodySetup.h(standalone header, UE 5.5+) — guarded with>= 5. On ≤5.4 the completeUSkeletalBodySetuptype is still reachable viaPhysicsEngine/PhysicsAsset.h(itsUE_ENABLE_INCLUDE_ORDER_DEPRECATED_IN_5_5block, default-on there), so theSkeletalBodySetups[i]->…member access is unaffected.#include "UObject/StrProperty.h"—FStrPropertyis declared in the already-includedUObject/UnrealType.hon all UE versions.No behavior change on 5.5+.
CHANGELOG.mdupdated under[Unreleased].Checklist
npm run lint— passes locally on this branch.npm run test:smoke— passes locally on this branch (Smoke Test PASSED, 23 tools).CHANGELOG.mdupdated under[Unreleased].C++-only change to the bridge plugin; does not touch the TypeScript server. CI (lint/smoke/CodeQL) doesn't compile the plugin, so the UE 5.3 build above is the compile evidence.