Pentax K-x 12.4 MP vs the Nikon d3100?

Ok i was set on buying a Nikon d3100 but then somebody suggested the K-x. I know its older, but it comes with two lenses and still is cheaper than the d3100.however, i don't want to sacrifice quality. What is the difference on quality? I've also heard that lenses matter more than the camera? What is a better buy? (i'm not going to buy any extra lenses in the near future)
Added (1). * is higher shutter speed and fps important enough to choose which camera i want?

The D3100 is at least a year ahead in technology than the K-x
At only $700, the D3100 has many more features than the K-x and uses "green" Li-ion batteries that can last for at least 5 years (I have some six year old Nikon Li-ion batteries that are still working like new). The K-x uses the very ungreen, AA's.
Plus the Nikon does something that that Pentax can't. Start your camera system with one that has over 60 different lens choices and professional full frame cameras if you ever decide to add one to your system
Here are links so you can compare the two yourself.
http://www.nikonusa.com/...D3100.html
http://www.pentaximaging.com/slr/K-x_Bright_Blue/

Quality-wise, there's no difference. Pentax is also a major brand of cameras just like Canon and Nikon. It is a brand easily recognized by the most experienced photographers. Lens-wise, I believe Pentax is better. Camera (or body), Nikon is better (I admit). Better buy? Two lenses versus one. Why don't you dig up some more about the K-x. If that 1/6000s maximum shutter speed won't sway you over, maybe the brightest viewfinder will.
As far as lenses are concerned, Pentax doesn't make a lot of duplicates so the lineup is pretty short. Pentax however assures that any lens made by or for the Pentax camera can be used on any Pentax dSLR. That includes some very cheap screwmount lenses that can be used with an equally cheap adapter. It also includes more costly manual K-mount lenses from Voigtlander and Zeiss that are available brand new. If you are after glass quality more than technology, the options with a Pentax are almost endless.

I think you should go with Pentax K-x 12.4MP Digital SLR with 2.7 inch LCD and 18-55mm f/3.5-5.6 AL Lens (Navy)
High resolution 12.4 megapixel CMOS image sensor features sensor-shift Shake Reduction for stabilized image
Large 2.7 inch LCD features Live View with contrast, phase difference, and Face Detection autofocus (up to 16 faces).
Capture widescreen HD video in full 720p resolution (1280x720) at 24 FPS cinematic framerate, using any PENTAX 35mm lens.
Highly compact DSLR body design allows for 1 handed operation and comfort when travelling.