There were probably more than a 100 combatants.. and by the looks of it they planned out the operation well.
One has to understand that the Pakistan state has constantly been reactionary and not proactive against the TTP. Basically, they wait for things to happen to take action against them; be it the GHQ, Airbases , Convoy ambushes etc. Before Kamra, most PAF bases save Shahrea-e-Faisal and those in the major cities were easier to get into than cheap nightclubs.
Additionally , the populace(and politicians) of KPK(and Punjab to an extent) have an on and off romance with the Taliban and since many of them are from the province.. there will always be willing and unwilling sympathizers. There is no way to tell apart whether the police officer is fake and there is no way to suspect whether the passer by is a terrorist or just a grocer going home from his shop. A clean egress could be easy as long as you have someone within those walls telling you where the security forces are looking for you.
Moreover, it depends on how many streets were there for them to cross and how many were simply urban lanes that were going to be easy routes out.
This is D.I Khan and A is the jail.. you can see the many little streets and paths they could take to slip out in the early assault.