And when there isn’t a specific law, there is a general “conspiracy to commit” law ( https://en.wikipedia.org/wiki/Criminal_conspiracy ), which is what I’m sure is involved in this case.
“Conspiracy” makes it sound funny, but the basic idea is that when multiple people (and “multiple” means “at least two”) have conversations about committing a specific crime and one takes concrete steps toward committing that crime, then all people involved can be punished for conspiracy. Of course, the ones who were undercover agents don’t get punished. And the fact that the plan wouldn’t work doesn’t matter. If the FBI sells fake explosives to somebody and that person plants them outside a building and tries to set them off, the fact that they were fake doesn’t help them beat the rap.
The issue with stalking is that there isn’t a law against being in the same area as somebody else (unless there’s a restraining order). So, unfortunately, the police can’t make an arrest until a law is broken or the potential stalker at least tries to break the law.