Sex offender agrees to plead guilty to enticing girl