added methods for getting and updating x y and z positions
merged