Fixed math bug in getVirtualZValue

Also moved the method to import3dBuildings