Have you ever known that you were absolutely in the wrong mood for what you had to do next?
You know that your attitude changes your effectiveness. The question becomes how you can change your own attitude. Your current attitude colours all your perceptions. That makes it very hard to perceive the differences that would allow you to build a different attitude. Many people don't even try. They just wait it out, hoping that the next mood that hits will be more useful. Or they pretend that attitude is something that only happens to other people.
A more useful approach has three steps:
1) Move your body.
2) Connect with a new rhythm.
3) Borrow the best available attitude.
It's hard to change your own mind. It's easier to change your body. If you want to signal yourself to get moving, try moving. A walk, a run, a climb up stairs: any of them will get the blood flowing, adjust your breathing and rhythms, and suggest to your whole brain that it look for ways of moving forward. If you can't make it to a gym, then make an extra trip down the hall or take the stairs when you go for coffee. Moving creates change in your body that begins to change the energy and thoughts available to you.
Notice your natural rhythm. It will show up in your gestures, your walk, your breathing, your voice. "Natural" means the rhythm that accompanies your current attitude. If you would prefer a different attitude, then begin to find a different rhythm. Listen to music that is a little slower or faster (not a lot, just a little) than your own rhythm. Notice someone who is walking faster or slower and let them set your pace. Listen to the voices around you and let yourself get in sync with one that suits the attitude you would rather have now.
And finally, notice that there are people available to you who have some of the energy, focus, or optimism that would be useful to you. Borrow some of that. The great thing about allowing yourself to be drawn into someone else's useful attitude is that they are reinforced, not drained. So when you allow yourself to connect and move into the flow of someone whose attitude would make you more effective, you do something good for yourself without cost to anyone else. You also find that you are looking at the people around you as potential resources.
I wonder how your day will change when you realize that you are surrounded by the resources you need to change your own attitude. You can have energy or focus, be driven or relaxed, see into the future or pay attention to the details. Sometimes it's a good thing to change the world and sometimes you can use the world to change you.