Mass Calculaiton

Hi, I am making a custom weapon system and I need to know how unreal engine calculates mass.
I tried to create a 100x100x100 cube with dynamic meshes but it mass calculated to 177,1256164484 something something…
So, a cube has a volume of a^3 and calculation should be a just integer but ue gave me that weird meaningless number. Probably it is multiplied by a constant but I don’t know what that weird number is.

That value is the default mass of a cube. You can simply navigate to the Details window while your actor is selected, and change it’s mass under the Physics section :innocent:

Pleaase, I’m not start unreal yesterday. I know that basic sheets. Answer my question. I want to know how that default mass calculated.

The greyed out default value that you can see from the settings I mentioned is determined by the scale of the actor, and you can further adjust it’s effect on the actor by adjusting the mass scale setting under the same section or assigning a physics material to the actor and playing with it’s density.

I think this is the explanation you’re looking for. But you can also assign the mass yourself, and in that case you’ll see that no other meaningful attribute changes which is not in fact how physics work. So you shouldn’t think it like it’s something that’s realistically calculated by other attributes, it’s actually assigned. That default value is assigned the way I explained above, but that doesn’t mean there’s some kind of a calculation like what you might expect. The engine is not a universe where everything abides by the rules of physics.

Okay, I figure it out. All my problem was about defaultphysicalmaterial.


That 0,75 value is causes that weird float mass. When I make it 1 every default mass calculation turned to reasonable integer values.