Man if I could produce the sounds in my head, I would be one to reckon with. I've taken piano lessons before and it helped alot, but if you're not constantly practicing then you forget. I used take the song I was trying to learn and straight jack the keys, rhythms, and melodies and turn it into some hip-hop shit.
Mostly I just sit there and play around with different notes, chords, and scales. I tend to program my drums first and then the bassline. It just depends though, cuz sometimes I'll fuck with the melody first. The reason I do drums and bass first is because I always try to to program my drums in a distinct way because there are only so many drum pattrens used in popular music, and I seem to play phat ass basslines that usuaully end up being the track mover.
I wish I could produce whats in my head.