I'm surprised no one else has replied to this. I'll explain briefly my techniques in-case you don't see this message - strangely, some people don't go back to their posts after a couple weeks.
While I'm gaming, I'll go to YouTube, play some instrumentals and randomly come up with a hook. I practically always start with the hook/chorus.
I also sometimes just go look for beats and put them in a special playlist. So I'll go on youtube in my list of who I'm subbed to and see new beats. Listen, If I like, I'll come with the theme and hook.
After the chorus, I freestyle the beat. Usually on the first freestyle, I come up with a concept and some nice bars which sounds good, and I'll use that. I find it easier to freestyle first than write straight off the top. Once I've freestyled the verses, I will make corrections, improve bars and change certain things.
For inspiration; I actually don't really know. I listen to music literally all day. There's never 10 minutes where I'm not listening to any type of music. I hear others and think "Damn, I wanna make others like my music the way I like this person's".
I hardly ever say to my self "Right, I'm going to sit down and write a song." I usually just come up with the hook, find a beat if I don't have one already, and write more of the songs.
I've fallen into a nasty habit of not finishing songs before starting another. I sometimes can't think of verses, and instead write loads of hooks for different songs.
I personally find hooks very very easy to write, yet find verses quite difficult. Doesn't always apply.
I hope that helps you.