I've been looking through the FAF GitHub for functions that controls shield states. I'd like to be able to set a naval unit to disable shields when submerged and re-enable when on the surface.
You need OnLayerChange and EnableShield/DisableShield in Unit.lua for when a unit is moving into/out of water. You'll also need to modify EnableShield to prevent them from being turned on when in the water.