These frame captures tell the story. With extra lighting or shorter distance, the differences would be less, but here are the three aimed down a dimly lit street. All three cameras are units purchased from Andy.
Dahua IPC-HFW5231E-Z12 (series 1)

Empire IPC-B52IR-Z12E-S2 was a definite step up from the first generation Z12. Still, a 1/2.8 inch sensor at 2MP, but pretty good. Low clouds completely block lights from distant ridge.

Empire IPC-B54IR-Z4E-S3 brings out considerably more detail and still does well in the dim lighting. 4MP with 1/1.8 inch sensor is definitely a sweet spot.

If the limited zoom range of the Z4-S3 can cover your required reach, definitely get Z4-S3 instead of a Z12-S2.
Dahua IPC-HFW5231E-Z12 (series 1)

Empire IPC-B52IR-Z12E-S2 was a definite step up from the first generation Z12. Still, a 1/2.8 inch sensor at 2MP, but pretty good. Low clouds completely block lights from distant ridge.

Empire IPC-B54IR-Z4E-S3 brings out considerably more detail and still does well in the dim lighting. 4MP with 1/1.8 inch sensor is definitely a sweet spot.

If the limited zoom range of the Z4-S3 can cover your required reach, definitely get Z4-S3 instead of a Z12-S2.