You might want to change `std::min` to `std::max`. I'm not sure why it choose min there. The question is which limit one uses: the max volume of the furniture or the terrain?

Maybe the furniture simply overrides the max volume of the terrain?