Camera2d limits not limiting zoom on all axes

I finally solved it for anyone who finds this thread in the future.

What I ended up using was two “VisibleOnScreenNotifier2D” nodes that I then positioned via my script at the given panMaxLeft and panMaxRight respectively. I then referenced the two nodes in my camera script and used the inbuilt methods is_on_screen() to see when both of the nodes are on screen at the same time. If they are, then I shouldn’t be able to zoom out anymore. If only one node is on screen, then I shouldn’t be able to pan anymore toward that direction, and vice versa.

I did also set my camera limits on the left and right to be the panMaxLeft and panMaxRight, since the limits make it so that the camera sort of shifts toward the other direction if you try to zoom out whilst having hit a given limit. I hope this is helpful.