For me, it's creativity.
But, with that creativity i first needed technique.
Once you hear a few things, and know what sounds right, it becomes easier to make new things that sound right.
Try listening to some really good drum lines and really tune in onto certain parts. For example, if you wanna learn the beat, listen to the bass and snare. If you wanna listen to fills, listen to the toms more. Be able to feel when the next fill is about to come, or that next crash is about to it.
Listening really helps a lot with this, but you can't be listening just because, you have to be really listening and looking for key aspects of the drums. Another thing to keep in mind is to listen how the drums move with the other musicians that he/she is playing with.
Well that's my little babble on doing drums from the creative aspect. I got a lot more I could say, but i'll leave that to any questions/concerns you may have. ^_^;;