So I'm trying to make a FOV visualizer that instead of using many ray-casts, it uses the derivative of the scene geometry (All the geometry is defined by functions) to find lines that pass through the character and is tangent to said geometry.

But to do this I need to solve systems of nonlinear equations. Is this possible with GDScript? Or do I need to import some C++ library, and how do I do that?

I know for example the NumPy library can easily do this with fsolve(), but it seems like python support is still a bit wonky.

Thanks.

Ok, thanks. So would a C++ library be the easiest way to go about doing this?