MP is all about supposedly capturing more detail which in essence is true, however unless you are going to be printing images larger than A4 size you are unlikely to ever see the difference. They do allow you to crop smaller parts of the image as once again they have potentially more detail in a smaller space however it is not the most important aspect of a photo.
The quality of the lens is the most important, after all a photo is all about light getting to the sensor or sensors. The wider the lens the more light that can enter and the clarity of the lens the more a clean image can be passed to the sensor without distortion. I would always chase these aspects of a camera rather than MP.
I mentioned sensors above and this can be critical, most cameras have crop sensors which work on a wider field of view which reduces both the light being measured and the detail captured. These sensors are small hence the use in most cameras. Full frame sensors don't crop hence the capture more light and sharper detail. If you're taking long exposure shots, or shots in low light using high ISO values full frame sensors really show their abilities.
My now aging Canon 6D is only 20MP but it is has full frame sensor and by using Canon L Series lens which are wider, 82mm as opposed to normal SLR lens of 50mm, produces outstanding images even when cropping to quite small sections of an image. I occasionally look to replace it but to be honest it does everything I need so I don't bother though I do get tempted by a Canon 1D-X III until I look at the price