One habit that I have found very disheartening is that of comparing myself to other people. I have a tendency to try to think of myself as being in the most favorable reference class* that makes any sense, and so then when I compare myself to other people, I naturally pick people from that reference class. Since I picked the nicest reference class in the first place, these comparisons usually don't work out well for me. I end up feeling depressed about my position in life, and it's very unproductive and unhelpful.
I have two strategies that I use to counteract this. The first is to try to think purely of myself in relation to myself, and not in relation to other people. Comparing myself to my past self is almost always a favorable one, and more helpful than favorable comparisons against other people, because it doesn't breed a superiority complex, and it demonstrates to myself that I can improve. So that's a better tactic.The other one that has helped me a great deal is thinking about myself in terms of trajectory instead of position. Focusing on position isn't actionable. It tells you that you're better than other people or positions you could be in, so you can rest on your laurels. It tells you that you're worse than different people, or alternate versions of yourself, but suggests no methods of improvement.
Thinking about your trajectory, on the other hand, changes all of that. If you're thinking about trajectory, you're not thinking about where you are currently, you're thinking about how your position is changing. So it doesn't matter if you're in a really bad situation, what matters is if your situation is improving or getting worse. And this lets you go meta, which is always a good thing: the second derivative, how how your situation is changing is changing.
This is really useful because, while the thing you actually care about is your position in life, you can't choose your position at any given moment. But you can, more or less, choose your trajectory. And your trajectory now determines your position later.
For instance, a few months ago I was in a really good position, but just sort of treading water. Not really improving or getting worse. Now I'm in a really similar position (that's what happens when you don't have a positive or negative trajectory, you're still in the same position later!), but I've started a new project (this blog), have two more projects that will be starting soon (National Novel Writing Month and a youtube channel), have made significant progress on two new games for my business, and am moving to Brooklyn in three weeks. My present situation hasn't changed much, but I'm setting myself up to have a lot more success in the future.
The bit about the second derivative that I mentioned earlier is also useful. To make the physics metaphor, position is the initial equation, velocity (how your position is changing) is the first derivative, and acceleration (how your velocity is changing) is the second derivative. Once you get into a good trajectory, and you feel comfortable and that you can keep up what you're doing, you can start working on improving the rate at which you're improving.
*a reference class is just a set of things that share a common trait, and so it makes sense to compare them. A reference class that makes me seem like I'm doing well is "recent college graduates." A reference class that makes me seem less impressive is "people I met in San Francisco who own their own business".