Does anyone else use sleep deprivation as a (probably) unhealthy way of coping with different situations?

I, for example, have a "favorite person" problem, where I "obsess" over a friend to the point where my whole mood during a day completely depends on them. If everything is good between us, I'm happy, but if I start to feel abandoned or rejected, my anxiety, overthinking and bad thoughts hit the roof.

A few times already, I've found myself using sleepless nights as a way to cope with a bad "favorite person" day. For example, if one day I feel rejected, I may end up not sleeping that night, because if I sleep, I feel as if the whole day was wasted. I feel as if I ended that day with failure. But if I don't sleep at all, my mind doesn't seem to "reset", and the next day doesn't feel like a new day. Both days just feel like one long day. So, by not sleeping, I feel as if the day isn't over yet, as if I didn't fail, and as if I can still save it.

Is anyone else familiar with sleep deprivation as a coping mechanism?