Run function on Photon if leaving a specified location.