fixed znear problems