Sensor script