Sounds like your starting on the right track, the enemy (or self-induced unhealthy desires if you believe in those more), has had you in a trap, your being overweight has you feeling self-conscious which is making you hide, but this is limiting your exercise, and probably increasing your food intake (let's face it, a lot of people eat more often if they are just sitting at home) which is adding to your weight problem and your lack of confidence.
Going to the gym is a start, but walking and running help more with weight loss. Taking walks would be more effective, or if you would be more likely to walk with another reason, go do an errand on foot (remember what your bringing back though, you do not want to get stuck at the store with heavy items and have to carry them back), this is more effective than going to the gym.
As for your confidence and the effect your situation has on it, the enemy wants your self-confidence to be low. And even if you went on a successful regimate and came out looking like a body builder next summer, this issue would probably persist until addressed. Right now, standing in your way of having healthy confidence is your weight issue. What determines if you are going to gain weight or lose weight over time is the amount of calories you eat and expend on a daily basis. If you consume more calories than you use through movement, your body is going to store the extra either in muscle if they are used often, or fat, and if you eat less calories than you use through movement, your body will pull the extra calories from your reserves, first in your muscles that are not usually used, then your fat, which is your extra food reserve, calories are a measurement of food. So to lose weight, you have to expend more energy in calories than you intake in food. There are free resources over the internet to help you figure out what you expend in calories and what you take in for calories, then all you have to do is plan your day for the amount you expend is more than what you take in, it is good to not make it a large difference, but that is the simple concept behind weight loss.
Your porn habit is also probably hurting your confidence, because you seem to feel guilty about it. Spending a lot of time doing what you identify as a unhealthy or ugly habit makes you feel guilty over it, this guilt leads to thoughts like "how could anyone want to be around me", this effects you even when your not doing the activity, if you feel guilty, you tend to think other people can sense it on you, sometimes even think everyone can tell what you do when you're alone, so you talk yourself into thinking everyone will automatically reject you, also hurting your self confidence. One of the common traps with guilt over addiction, is you have to do everything you can to end the addiction as fast as possible. This is not the best policy if you continue to fail quitting cold turkey. With porn there are several tactics to wean yourself down your addiction, the benefit of this is you can still do it, but slowly you decrease the extent of which you do it. Let's say you watch one of these films for two hours out of your day, you personally know more what you do, but for purposes of stating the concept, let's say two hours. Try cutting back to an hour and a half a day, for however long you need to become comfortable with that, then down to the next increment of your choosing for the next period of your choosing, and keep decreasing the time you watch porn each day until you have to stop to decrease it further, if you get down to say 15 minutes, you can start going whole days without it if quitting at that point is still too difficult. Or, if there's other factors that you enjoy other than just viewing the videos, maybe take a different approach and force yourself to watch the videos without incorporating any activities which go along with it, if this is too difficult, perhaps force yourself to go a little bit longer each time where you just watch the porn in the beginning before adding any extra activities other than simply viewing it. This would help you wean off any secondary pleasures that may even be more addictive than watching the porn. Even doing the habit less should be something you should be happy about, and should boost your confidence, because even though you still do it, you are doing it less and working toward not doing it at all. If you choose weaning down, avoid the temptation to wean back up, if your current limit is 20 minutes, don't go above 20 minutes (mean, if you do 22 one day, don't beat yourself up, but do not go up to something like 30 or 40 from 20).
Now, the enemy will attempt to stop your progress in any of these areas, this is where spiritual values come in. the biBle says this becomes like warfare. What he will probably do, is tempt you with laziness to keep you from exercising regularly enough to lose weight, and cause feelings of wanting to watch porn more when you are trying to watch it less, you should be able to identify what that looks like for you, it says to treat these feeling as if they are literally your worst enemies working inside your head and body, to keep you doing the behaviors that are hurting you emotionally and spiritually. This gives you a way to motivate yourself further to resist these temptations, because you are no longer just trying to stop watching porn, and lose weight, it becomes a matter of an fighting against an enemy which has long sense sought your destruction. This makes every minute of resisting the feelings to not exercise and watch porn as if you are winning a fight against your enemy, your friend's enemy, your parents enemy, and every step you take when you feel like quitting, every piece of extra food you turn down, and everytime you put off watching porn, is a victory over your worse enemy, which is no small thing when it comes to spiritual strength, according to the biBle, if eve, the first woman, had a victory of like this over not eating a fruit, we would not surely die. Each victory of this defeats your enemy, attests to your spiritual strength, and helps you overcome your problems. which means, if you are walking, and you do not turn around because you feel it is becoming more challenging, you are winning a battle in a war as if you were a powerful warrior, if you put off watching porn, even to later, you are proving yourself more powerful than the enemy in that battle, if someone makes fun of you for your appearance, and you don't let it cause you to fall back in your progress, or go home and isolate, you have won a battle against your enemy using the very thing he despises and is trying to keep from you, your confidence. Do these things, and you will prove capable of having determination, self-control, emotional strength, all of which attest you would be foolish to not have confidence, because these qualities are qualities of a healthy, strong and respectable man. Having victory over spirits of the enemy, improving your own life, and making yourself even more respectable to others than you already are. The enemy might send temptations your way to reverse your progress, you might get made fun of for your body, don't let it stop you from losing weight, your parent's divorce might provide means to depress you into not having motivation to exercise and give in to your wants, try to think of giving in as letting evil in them cause more evil in you, and resist it for the sake of strength, he may tempt you to eat extra food, remember extra food will add to your weight unless compensated by more exercise, every piece of extra food makes your weight loss require extra work, or the porn you subscribe to may corm out with a promotional, making it more attractive to view often, which would be the enemy making your addiction more attractive, every temptation you resist makes you stronger and more able to resist future temptation, and remember that everything I have suggested makes you a stronger person everytime you practice them, and you should feel stronger and more confident everytime you accomplish them, even partially, do not let thoughts of thinking these are too small of things to amount to you being worthy of confidence rob you of confidence once you achieve these things because it is not so, they are important. These are the things that make the weak man strong, they are not to be diminished.
And if you fail, show weakness, give in, now or at any point, do not despair, feel it is hopeless, or let it tempt you into giving up, this is what jesus coming for your forgiveness is for, and it is only one of the ways he strengthens people.