Rewrote 3D coordinates into class Point3D