UnrealCLR icon indicating copy to clipboard operation
UnrealCLR copied to clipboard

Unreal Engine 5 compatibility update

Open tonetechnician opened this issue 2 years ago • 11 comments

This PR contains the start of a migration to UE5 Preview. I struggled to find a way to get a macro that associates UE5 with Preview instead of Early Access. Closest I could find was the BRANCH_NAME macro. Maybe @nxrighthere you know of a better way? I guess once UE5 stable is out Early Access won't need to be supported.

There is also a deprecated warning for UObject->IsPendingKill function. I've left that out for now, I imagine if it is being deprecated we could just omit it in UE5.

Hope this helps!

tonetechnician avatar Mar 04 '22 14:03 tonetechnician

Thanks. I'll check it.

nxrighthere avatar Mar 04 '22 20:03 nxrighthere

BoxSphereBounds became a generic type and should be changed accordingly in my codegen tool. I need to think about how to wrap it properly.

nxrighthere avatar Mar 13 '22 12:03 nxrighthere

Yeah, that sounds right.

I believe they made it generic for the large world coordinates. I'm not sure if this will change back to a specific type with 5.0 stable. Reading the codebase, I saw there was mention that floats will become doubles in 5.0 to support large world coordinates.

tonetechnician avatar Mar 14 '22 07:03 tonetechnician

Will it work with preview2 as well? In the preview 1 the float renamed to Real (probably double type), but in the preview 2, the float came back.

teddybee avatar Mar 15 '22 13:03 teddybee

Yeah, I think there's been a few changes with these classes. Haven't yet tried to port to Preview 2, but on my task list for the week so can feedback here!

tonetechnician avatar Mar 15 '22 14:03 tonetechnician

Changing the Bounds structure will break compatibility with UE4, and this structure is based on double data types by default in UE5. Also, System.Numerics.Vectors doesn't support double-precision in .NET. 🤔

nxrighthere avatar Apr 05 '22 20:04 nxrighthere

There are a bunch of other methods that require refactoring for double precision. It seems that I have to make a separate branch for UE5 and maintain it along with master or drop support of UE4 entirely. 🙄

nxrighthere avatar Apr 05 '22 20:04 nxrighthere

There are a bunch of other methods that require refactoring for double precision. It seems that I have to make a separate branch for UE5 and maintain it along with master or drop support of UE4 entirely. 🙄

Consider using "#if" solutions instead of maintaining different branches.

yajiedesign avatar Apr 13 '22 11:04 yajiedesign

Cool stuff... Any idea on a timeframe for when a UE5 compatible version will be ready for download? Or is there a test branch I can download now?

eabemitchell avatar Apr 15 '22 15:04 eabemitchell

Nice! Any news regarding UE5 support?

dacanizares avatar May 14 '22 23:05 dacanizares

Consider using "#if" solutions instead of maintaining different branches.

That's probably an acceptable way to solve it, but I have no clue what to do with the double-precision math since it's not supported yet in System.Numerics.Vectors.

nxrighthere avatar May 30 '22 16:05 nxrighthere