After school binge attack!

Options
I lost 40 pounds last year, and I know how to eat well, but I have fallen into some seriously nasty habits since September. I've had a lot of health issues crop up that have prevented me from exercising and whenever I can't exercise I inevitably eat horribly as well and I have gotten locked into this. I've gained 8 pounds in three months.
So my main issue is when I get home from school at 3, I have the incredible urge to eat everything in sight. Usually salty things.
Today when I got home I ate an entire bag of sun chips. That's 980 calories (I told myself not to look it up, but I did anyway -_- ) How can I stop myself from doing this!? I need to get back on the wagon but I think it rolled over me and didn't stop to pick me back up.