Can Plasma thc 300 post be modified ?

I have been using plasma thc 300 post, with the thc 300 unit and mach3 for the last few years, and now i need to use corner slow down.
Thc300 g31 corner slow down post does not work, the g31 line of code is the one that does not work on my setup.
So my question is : can the “Plasma THC300 - G31 - corner slowdown” post be modified to use “g28.1” instead of “g31” ?

I have the switch from floating head assigned to Z home.
with this setup, if i use g31, the z axis goes down past my switch.

When i assign the input from switch to probe, the z axis does not even go down to touch the plate.

Reading on different forums i understand that it is better to use g28.1 than g31 .