I created a physical material with following properties: Density = 7.85, RaiseMassToPower = 1.0. Then I applied this physmat to a material that is used on a 100x100x100 cm cube.
calculated mass is 11,775.000 Kg. Shouldn’t it be 7,850.000 Kg?
I took a look in BodySetup.cpp and here:
// Then scale mass to avoid big differences between big and small objects.
const float BasicVolume = GetVolume(ComponentScale);
cube’s volume was being calculated as 1,500,000… shouldn’t it be 1,000,000?
mesh I’m using is StaticMesh’/Game/Environment/BasicShapes/Meshes/Shape_Cube.Shape_Cube’, I think it’s from content examples or maybe starter content.
Also, on a related note, applying a different physical material to multiple Materials (not Material Instances) via Property Matrix causes a crash when you try to save.
I’ve assigned a member of our staff to look into mass issue, and they’ll be with you as soon as they can. Please open a separate post for crash involving Property Matrix, with as many reproduction details as you can and crash logs from project. Thanks!
reason for incorrect volume is that if you look at collision setup of ShapeCube you’ll see that instead of using a simple cube we have 3 overlapping triangular pieces (Oops!). When you replace this with an actual box calculation is correct.