`FOV / (FOV + z)`
So, to your 2D vector (x, y) you give it a z component (x, y, z) and use the above formula to draw it as a 3D scene. Pretty cool, right?! FOV stands for field of view.
I don't know, I've been working a lot lately and on the weekends I'm working on my next game; so I kinda miss doing this small projects that I can finish in under a hour, just to entertain myself.
I don't think this sketch deserves a GitHub post, but let me know if you think it does and I'll publish it.