So I was wondering if you would get more zoom the higher the megapixel camera you have.
The resolution you get from
any lens will be severely limited by that lens's f/stop, even if you get a great lens that is well-corrected for aberrations. As others mentioned, it's the diffraction which will limit the camera's performance.
A series of articles explains it:
https://blog.kasson.com/the-last-word/whats-your-q/
Up to a point, the camera will perform better with more megapixels; beyond that, no.
--
http://therefractedlight.blogspot.com
Philosophy presented by Jim Kasson in that series of articles is a little bit different than common approach of choosing suitable lens and sensor combination. Usually, people want to have pixel sharp image which leads to a lens that outresolves sensor. This leads to presence of aliasing and moire artifacts due to Bayer CFA. Jim outlines an opposite approach there. That means that he derives a sensor resolution so that all information provided by the lens is captured by the sensor without artifacts.
By his calculations, diffraction limited f/8 optics requires 1.6 um pixels at Q = 2.8 which corresponds to roughly 340 MP FF sensor.
Still not sure that will deal with false colour moire.
You need to double it, given that red and blue are half the sensor frequency, and you might also want to use blue as the defining wavelength, in which case you need more spatial resolution again, and the sharpest aperture.
That requires more like 4,000 MP.
However, if you also account for human acuity, and the MTF of displays and prints, all of which are multiplied to get the perceived sharpness, I would think about 500 MP would be enough for practical purposes.
You could also use it in a quad Bayer arrangement, which would make for much easier processing - no demosaicing required and 125 full-colour megapixels.