Thoughts bring emotions, and it can be very hard to get rid of them if you don't take care of the emotional side. Give no weight to these thoughts, they mean nothing.
So firstly calm yourself and breathe, use the Complete Yogic Breath as it's very calming: https://www.joyofsatan.org/www.angelfire.com/empire/serpentis666/Complete_Breath.html
Once you are calm, then try to keep your mind free of thoughts, or focus on something positive. It's okay if you will still have some intrusive thoughts here and there, just ignore them and don't react emotionally. Remember, they mean nothing to you.
The more you do Void Meditation the more control you will have on your thoughts, but also on your emotions, since developing concentration also develops self control and willpower.