In the late 1970s, H&K partnered with Hensoldt to create the ZP/AP (Ziel/Aiming; Projektor/Projector) and then ZPP/APP (Ziel/Aiming; Punkt/Point; Projektor/Projector). This was essentially a calibrated flashlight with an aiming point and pressure switch. It projected a beam of light that was specifically 2m wide at 50m distance, with a black spot in the center which would measure 30cm at 50m. This could be focused and zeroed o the black spot was a functional aiming point, allowing both target identification and engagement...
A very similar concept was used in the by the
British Special Air Service most famously during the 1980 Iranian Embassy Siege. Instead of the ZPP their MP5s where fitted with Maglite D-cell flashlights on top however.
Ian's video on the ZPP: [8:47]
https://youtu.be/mYcLNA7QmXg?si=