add status check loop script