 The mangonels and ballistas along the walls were prepared for action, and in late November the city gates were opened.The entire Baghdadi army then came out of the city, while river boats loaded with bowmen and artillery moved up the Tigris.They attacked the Samarran army and routed them, forcing them to flee.