The steps I've learned to take that have been helpful to me in preventing:
hunger - a small but sustaining snack before the critical time, making sure I eat really well most of the time, and keeping hydrated;
anger - breathing, meditation; I'm a placid kind of person so anger is rarely an issue for me;
loneliness - communication in some form, whether in real life - even a smile and a brief exchange with the grocery checkout operator - or via internet, listening to talkback radio, SR, emails, reading, listening to affirmations on YT; dispelling gloom with lighthearted movies & tv;
tiredness - relaxation techniques, rest, good sleep habits, knowing when to stop overdoing things.
Take care, all