In the first game, opening the g file would have been a good idea if he was already castled short and you were in the position to attack his king. As it turned out, you were the one who was castled short while he could castle long, and he was in the position to attack your king...
How are you suppose to play Middle Game?

I don't understand, what was I suppose to do? Castle long?
Well, since you were already castled, recastling wasn't an option, while he still hadn't committed to castling. This is the kind of considerations you should have had in mind before exchanging on f3. You want to open files toward their king not toward your own. (King safety=much more important than doubled pawns)

Are you sure you cant afford my coaching :P
I've had free--FREE-- coaches who have contributed pretty much nothing to my ability... What makes you think a paid coach would be any different?
coaches are pretty much useless unless they are titled or extremely good coaches which are rare and/or expensive. Plus there's no way to tell a coach is good or not--but most of the time, I'll bet they're bad.
Unless you're a soviet era coach that has raised many masters, I don't think it's worth paying... And since coaches cannot guarantee anything, why would I risk my money? I already risked money on chess mentor for a year, that provided nothing for me...
Let me take that back, titled players are no guarantee for a good coach either. Just take a look at some of the "video lessons" on chess.com, some of those titled players (no offense guys), are not that great lecturers (some are, so don't make assumptions).

I edited the post, I agree titled means nothing... and yes ability to explain concepts works great. But even your free advice of "don't hang pieces" I've been following ever since, but my opponents don't hang it either... Sometimes these 1300-1400 players don't make any blunders... And I rarely get any tactical opportunities, to use my TacticTrainer training for.
And don't get me wrong, I'm sure you're a great coach and raised many other 1800s. I just don't have any guarantee I'll become better by simple coaching. Plus, I'm not going to make a living out of chess, so why invest in something like that without guarantees?

So you're saying it was a mistake to take the knight and double his pawns...
In that position, yes, I think so. I also think that he missed a winning continuation earlier on, probably 18. Qh5 would have done it.

So you're saying it was a mistake to take the knight and double his pawns...
In that position, yes, I think so. I also think that he missed a winning continuation earlier on, probably 18. Qh5 would have done it.
I know I was screwed after that pawn move, but I was asking about how I could have won, rather than how he could have won (and yes I thought he would do a discovered check too, but instead took bishop etc).

So you're saying it was a mistake to take the knight and double his pawns...
In that position, yes, I think so. I also think that he missed a winning continuation earlier on, probably 18. Qh5 would have done it.
I know I was screwed after that pawn move, but I was asking about how I could have won, rather than how he could have won (and yes I thought he would do a discovered check too, but instead took bishop etc).
Um I don't want to mention a paycheck but... I tried to help what I could at this hour.

Dont make me go through your games and prove you wrong ;)
You can never prove me wrong, (it's possible, but improbable).
I've had 100s of games computer analyzed, telling me exactly what I did wrong, how my opponent could have expoited that, and telling me what my opponent did wrong, and how I could have exploited that.
I've had high rated friends, give me some tips and such, including yourself (which I am very very grateful for), or go through my games telling me what I could have done, or what I should do. I've had 1800+ friends pretty much coach me through voice-chat letting me practice on an opponent and coaching me while I play the game. I've had people coach me strategically or positionally, and yet it still hasn't made a significant improvement in my game.
I think the best improvement for me was a lot of tactics trainer, but even still, I still occasionally may lose to 1200s or so.
I've invested time into articles, videos, and forum discussions on how I could improve, trying to implement all of the suggestions made.
I've come to the realization-------there IS NO magic/secret way to improve. There's a ton of practice and some lessons that need to be memorized, some variations that need to be learned, some positional moves that can be improved, and some improved board-vision via tactics trainer. All of which after many many years of intense practice, can get one from 1300 to lets say 2000, but there is no short-time coaching that one can do, and make your game improve vastly.
Over the years, I've watched very interesting players that go from around my level, to many months later, to 1500-1600, but only after thousands of games...

@Atos Thank you for your time in giving me the advice of not opening up files opposite my king via exchanges. I'll definitely burn that into my brain and hope it doesn't happen again...

Actually if you can pay a little bit more, you can upgrade your membership to diamond, and take advantage of chess mentor, plus videos. Some of the questions you ask here are already answered there.
Basically you need to have a plan from the beginning, and you should try following it through out the game. Now you are wondering how you are going to come up with a plan. That's why I am suggesting you to follow the courses on this site. I don't think all that study material can be summarized in couple forum posts.
Wishing you best

I had diamond membership for a year, it didn't help... Chess Mentor doesn't improve my game, I got to 1830 on it.

I edited the post, I agree titled means nothing... and yes ability to explain concepts works great. But even your free advice of "don't hang pieces" I've been following ever since, but my opponents don't hang it either... Sometimes these 1300-1400 players don't make any blunders... And I rarely get any tactical opportunities, to use my TacticTrainer training for.
And don't get me wrong, I'm sure you're a great coach and raised many other 1800s. I just don't have any guarantee I'll become better by simple coaching. Plus, I'm not going to make a living out of chess, so why invest in something like that without guarantees?
Seriously? Man, I'd like to be able to swing that!

Here are the middle-game principles I follow:
Never move the pawns in front of your king unless you absolutely have to. In your first game, I would have played 15. ...Ne8 instead of 15. ...g5. Yes, e8 is a bad place for your knight, but you can move your knight back later. Your pawn, once moved, is moved for ever.
Put your pieces where they control lots of important squares. In your second game you should have played 10. Nd5, which is a powerful place for your knight, or you could have moved your queen which would take the pin off your other knight, allowing it to control the important d4 square.
Reduce the control your opponents pieces have. In your second game, 10. Be3 or 10. Qe1 would have allowed you to capture black's knight when he played Nd4.
Choose a strategy, even if it may be a bad one. At least your pieces will be coordinated toward a certain goal. In your first game you go with a pawn attack on the queen-side and center, this is actually a good strategy in this position even though you don't seem to think so. As you try different strategies you will learn which ones to use in which positions.

ivan has the right ideas, some principles is what I need to do better in middle game... Some sort of algorithm to determine the best plan.

9... d5, so instead of exchanging and double-pawn, it's better to do some quick exchanges in the center...
8. Nxe5, I don't think I would have ever seen that. The only time, that I know mentally to sacrifice queen is in the Elephant trap. But that's very specific...
I still think, using induction, one can determine a set of principles, for the middle game, that allow for improved skill.
For players like me, below 1500, a lot of the middle game seems random, if they see a hanging piece they go after it, but if no hanging piece, they develop randomly, and try to move forward while things are protected, or if there's a possible checkmate try to set it up. However, experts and masters may have other strategies like, "oh I must get this center pawn out" or "I need to develop my bishop on this diagonal for a future checkmate"
Hooray for Legal's mate...I always keep an eye out for the possibility just because it's cool, but as a Queen's Gambit player it doesn't turn up often. :P
Getting back on topic...eXecute, while the middlegame of your first game went rather poorly, your opponent messed up too by being unable to follow through with the attack and letting you trade down to a rook-pawn endgame (with material equality to boot!). You almost certainly had a draw there, it was an endgame mistake rather than a middlegame one that actually caused your loss (though like I said, if your opponent had played better in that middlegame you would probably have lost at that point...very soon after he started his attack you'd already lost two kingside pawns; so even if his middlegame attack had petered out he should have been able to go to a won endgame if not for a few mistakes he made).
I do the opening just fine, follow all the principles of opening, and try to stick to book moves, but every time, the middle game begins, I end up losing because I just don't know how to protect my king after castle, or i don't know how to make an attack with pawns or win the game after the opening...
Every time, I just don't know what I'm doing in middle game, do I advance pawns? Do I move my major pieces around and waste time? Do I defend something (which is what I do and it ends up badly for me)?
Is there any middle game principles? I keep wasting all my time on thinking about what to do in middle game, and I end up losing to time or checkmate due to time pressure...
Here's 2 examples of me losing like that: