It sounds like you are running your MT/MA on the script in hunter tank / puller tank mode as eqsubi15 mentioned above or you would be able to stop the script with /mqp or even better, avoid being near others while using automation. If that is the case, then eqsubi is right;
As a general rule, I avoid others when hunting if they are in a given area/camp before I enter it and I often leave if someone comes to a camp/area while I am there so they can also have a turn to get what they need. As such, I have never seen a need for such a condition, nor do I think one exists tbh.
Definitely not trying to be accusatory here, but one could also easily infer that a reason a condition like this would be necessary is because the script is being run while AFK, which is not recommended or supported. Hopefully, this is not the case.