I make games for both reasons. I love programming, and I love video games in general, and since they can bring in some income, might as well.
I spend mainly time on marketing, not too much money, just time link building and distributing.
Only on a few major sites would you want to spend money on marketing, or to just hire a dedicated marketer who has a good track record.
A web version of a game can be distributed on different places and linked to from everywhere online, it's a great marketing tool that can also bring in income itself.