I've been studying for my B2 exam coming this October.
Generally, it takes around 600 hours for a B2 level (listening, writing, speaking). I would EQUALLY alternate between these three. The more hours you put in, the faster it'll take you. In my opinion, speaking the the most important > listening > writing/reading.
For example, I study 6 hours a day, so, if I started at a low A1 level, it'll take me about 100 days to be B2. If you can take a summer and immerse yourself in the language, you'll be B2 summers end.
If you study 3 hours a day, it'll take you 200 days.
1 hour a day, it'll take you about 2 years. You get the idea. Also be confident in yourself. It's easy to doubt yourself when the language isn't native. Good luck!