How to imitate with a script Vel>Lev dependency in the Amp section for a zone?

There is the Vel>Lev knob for each zone, which “determines how the velocity affects the level of the envelope”. I’d like to set it to 0 (turning off) and imitate the Vel>Lev dependency with a script, having my own input “velocity” argument, rather then real incoming velocity.

Which commands like changeVolume, changeVolumedB or Volume argument in playNote() is it better/simpler to use? And what is the actual formula for Vel>Lev dependency? Assuming I choose linear “Level Velocity Curve” in the corresponded menu.