You can avoid using the OnMapChange event, which isn't called when the map is changed by command I think. This way:
When loading the coords, save the name of the map in some variable.
When executing one of your scripts commands, first check if CurrentMap equals the map name you have stored. If it's different load the coords.