Being creative and getting ideas to pop up is based primarily on three factors:
1. Your state of mind
If your mind is somewhere else or if you're busy or have strong emotions I find that it makes it harder to get ideas flowing. Once your state of mind gets better they slow start flowing back.
2. Your environment.
I find that being on the seaside or on holiday in general improves creativity. That has more to do with experiencing new things more than the fact of being on holidays per se. Being bored does it too, just not as much.
3. Your attitude
I also noticed that once they stop coming, they don't come back right away even if you follow the steps above. Initially they take quite some time to start flowing again. You need to force them by applying these 3 points. If you do, with time, they'll come back. I call this idea starvation. It is not a battle that you fight once, it is a constant fight. If you get too comfortable and don't experience enough they will come less often.
The difference is pretty big and really interesting to explore.
This is just my experience and I have no idea if it's the same for everyone or not. I guess that since every brain is different it'll be a bit different for you. That said the general gist of it should be similar.