Why is mass NaN

I have a newly imported Static Mesh. If I look at the Mass in KG property in the BP editor, it reads NaN. When I print its mass, I always get 1. This is breaking the physics as it behaves like a feather in a storm. I have tried the following:

  • Increasing the mass scale on the BP with the static mesh to arbitrarily large amounts
  • Applied a custom physics material to the static mesh itself with arbitrarily large densities
  • overriding the physics material in the BP again with arbitrarily large densities
  • At run time, multiplying by 10 the physics material density every frame ([As described in this question about changing the mass at run time][1]).

None of these have any effect on the printed mass of the object and when a force is applied to the object is immediately flies off to infinity.

What step am I missing to stop the mass being not a number. I see in the documentation of the getMass it interprets mass 0 as mass infinity (NaN) so presumably it is because the mass is 0, but why?

When imported, I have had to scale it up by a factor of 10000, could that be causing problems?

[1]:

Having stepped through some more, it would appear it is because the volume of the object is 0. How can I make my static mesh not have a volume of 0.

Adding a collision mesh changes the mass (according to the BP editor) from NaN to infinity. In either case, the calculated mass is still 1.0 and the object behaves incorrectly.

I would expect adding a collision mesh to only be infinite mass if the object is not set to simulating. It’s possible you only have complex collision and the lack of simple collision is causing some problems (possibly a bug)

Could you try adding simple collision like a cube using the static mesh editor and see if that changes the reported mass?

Yes sorry, that is what I meant I had done. I added a box mesh as follows:

  • Open the mesh in the static mesh editor
  • Clicked collision>box simplified collision from the menu bar

Trying that fresh this morning has worked even though I would swear to having done the exact same thing yesterday. le sigh… Is it worth me writing up an answer or should I just close this?