Any way to "hack" weather generation to manually force fog?

As far as what I’m asking… my thought process is: since the sim is capable of accurately depicting visibility in fog as reported by a Metar, isn’t there some way to manually control the visibility value being reported to the sim so that the desired vis is depicted. I understand there is not, in the normal UI. I’m wondering if there’s some way it can be done with a little mod.