ProjectWorldToXXX functions returning extremely wrong/different values in packaged build

In our game, we are projecting actor locations to screen to overlay hud elements on them.

In PIE and Standalone, all the ProjectWorldToScreen/WidgetPosition functions return expected values.

But when we make a packaged build, given the same inputs, these functions are returning values approximately 3000x larger than expected.

I’ve double checked all the code around these nodes as well as things like the viewport scale and size, and everything is behaving normally except the ProjectWorldToXXX functions.

Any ideas on avenues to troubleshoot?

Did some debugging. Called ProjectWorldToScreen on the Tick of the player object to give me a predictable location to observe. The function returns the correct screen position until I make the player move at all. Even the slightest nudge, and the values go from correct to these grossly inflated values which seem to be more like 14000x larger.

Did you normalize all vectors that need to be normalized? And is player starting location at 0,0,Z with rotation of 0,0,0 ? Try spawning with different rotation.

I’ve spent all day trouble shooting. I’m convinced its something going wrong in the ProjectWorldToScreen functions…

Today, I moved these UI elements from a UMG that was basically doing the projection via BP scripting to Screen Space Widget components.

Even the widget components that are doing no special math, but are just simply attached to an enemy actor show in the correct screen position in PIE and Standalone, but disappear (presumably at these exploding screen coordinates) in a packaged build. I attached an arrow component to just double-triple-check that the widget was physically in the correct place.

There’s nothing unusual about any of the actors’ locations.

When I was handling the placement of these elements in BP scripting, all the locations were correct, and only the output from the projection functions were awry.

Update: I am taking a pass at cleaning up the packaging… hopefully this is the root of the problem and I will automagically fix it.

I’m really curious to the outcome of this, as I will need to implement world to screen space projected UI widgets at some point.