What do you mean by guard distance?
Do you mean creep camp distance, which is how far a creep will chase an enemy before they return to their origin?
If so, this value can be changed in gameplay constants. Note that it is a global value, so if you need it to be specific to creeps/creep camps, you would have to code your own creep camping system in.