You sound like a responsible student whose good intentions slip out of sight when something distracts your attention — like television, video games, Internet chats, or the chance to take a nap, perhaps?
Everyone, young and older, has to battle the temptation to put off work when anything more fun comes along. Of course, as you've found out, the price you pay for play is frustration, disappointment, and grades that just don't cut it if you expect to continue your education and make the most of your life.
One way to figure out what's distracting you is to keep a journal, or at least some notes on what takes you away from the studying that you know you need to do — before the end of the semester. Set a study time and place for each day, and commit to the plan. If you decide to go to the mall instead, write yourself a quick message before you walk out the door. You may awaken to the fact that you've just fallen victim to your old bad habits — again. And you may think twice about enjoying the temporary satisfaction of hanging out when staying put will give you a far better chance of test and homework success.
If you do choose to make schoolwork your priority — and you stick with your studies — remember to reward yourself. Plan fun stuff for your free time. And expect to really celebrate when you start performing as well as you know you can with the right personal discipline!