I was like that just a few weeks ago. I sorted promised myself, "if I succeed in getting what I'm looking for, then I won't kill myself, but if I fail to achieve my objective and get what I am looking for, then I'll kill myself near the end of May 2019". As of now, not actively suicidal as I have made a small recovery a few weeks ago and things went well.
To answer your question, yes there has been several times where I came close, and had a very detailed plan, such as when, where, and how I'd die (firearm - shotgun).