Also are you depressed or feel sad a lot? That can wreak havoc with your productivity, motivation and quality of life.
If that is the case, then you gotta decide whether you want to be happy. Once you decide that and fix your goal on being a happy, cheerful person, there are several ways to get there.
I will mention what worked for me and was imparted to me by a student of Tony Robbins. Smile regularly especially when you feel negative or under the weather. Say to yourself aloud that you choose to be happy. Use different techniques to snap yourself out of bad moods such as snapping your finger, jumping up and down or clapping your hands.
Another possibility and very likely is that you have ADHD. If so there are different techniques to help you mitigate your symptoms like adhd medication(ritalin, adderall, Marijuana in some cases), meditation, neurofeedback(though it is very expensive it could help)