Hi, Many boys of your age masturbate a lot and then face problem like this. This is actually not a problem but only a temporary disinterest in sex. It's like this: you are thirsty and a glass of water would quench your thirst, but you drank 2-3 glasses of water. You dont feel like drinking any more water for some time no? In fact you would find water repulsive for the next couple of hours. Does that mean your thirst has vanished for ever?
Sexual desire is like thirst and hunger. If you get more than what you need, there will be some disinterest or even aversion for a short period.. and therefore diminished bodily response (ex: poor erection). If you start worrying about it, then it becomes a problem. You probably masturbated more than your body needed at that time, that's why the so called problem. Actually masturbation is harmless.
Next Steps
Just stop masturbation for a couple of weeks. Stop worrying about the problem. If you are still anxious, take some herbal supplements or multivitamins.