I think the square (at least in M2TW) is not totally hardcoded. I know Taiji, a gameplay developer of DLV, managed to make town squares to don´t work at all, so you can´t capture the city. You needed to kill all defenders inside the city to win the battle. It have been some time since i played DLV, so i don´t remember exactly how the mechanic functioned, you can always ask him at the tw center forum.
Bookmarks