Fix of 3D problems

This was really stupid