I have this top-down view of the world where the submarine, when looking through the periscope, has a very limited and narrow view of the world:
![Image](https://i.postimg.cc/wBQ1Z9Zg/image.png)
It can see the destroyer when the periscope faces it (the periscope can rotate) it but not the one's on either side. I want to build a 3D 'scene' that is very simple, very retro and very flat. Specifically, I'd like to show that one destroyer, as a flat 2D image that is positioned correctly (a little left of centre) and scaled down to the right size to give the perception of distance. Obviously, when the periscope "moves" left and right, the 2D flat image moves in the opposite direction.
I have a few things to work with. I know the x/y of the periscope. I know which way it is facing (degrees from north). I know the periscope has a 40 degree field of view (20 degrees left/right), I know the x/y of the destroyer(s), the viewable area (periscope viewport) is physically 350 pixels radius and I don't care about the destroyers facing/orientation (for now).
I've had a few failed attempts at the math and to project the image in the right position laterally with the right scale. This is complicated by the fact each destroyer has an x/y but the physical shape obviously is a rectangle that is more than a single point.
I'm not looking for a full-blown 3D immersive environment. My ambitions are minimal and was hoping someone has done math like this before, in terms of translating relative position from the viewer into correct placement in an X/Y sense and then scale to right size based on distance. I'm not even trying to get the y value right (on the horizon or below the horizon) at this stage.
This is the vision:
![Image](https://i.postimg.cc/J4HcgBq8/periscopesample.png)
Even some journals on how Wolfenstein or Doom3D pulled this off would be great reading.