How about a thrall slot for gates and/or draw bridges, and make that a requirement for the auto close to work? Like a door man. Maybe add it for t3 doors too.
Maybe they could auto open too if you are approaching the gate?
Maybe they defend it too like a placed fighter would, except they are more stationary and only attack enemies trying to attack the gate?