Chinese media released this photo of the crew defending their ship
The captain of a Chinese ship has told the BBC how he and his crew fought off a gang of armed Somali pirates with petrol bombs and water cannon.
Nine pirates boarded the Zhenhua 4 on Wednesday but were forced off the ship by Capt Peng Weiyuan and his crew after they mounted an unexpected fightback.
Helicopters from a multi-national force also took part in the four hour battle, which saw the pirates back down.
China has announced it is to send naval ships to combat piracy in the region.
Speaking by satellite phone from the Indian Ocean, Capt Peng told the Newshour programme on the BBC World Service that the pirates attacked the vessel using two speedboats.
"They opened fire, they wanted us to stop," he said.
"We had 27 crew members on the boat and we shouted at them saying 'go away', but they were very fast."
Capt Peng said he tried to manoeuvre his ship out of the way but eventually the pirates climbed aboard after putting ladders up the side of the Zhenhua 4.
"Seven pirates got on our ship and two remained on the speedboat. The seven that got on were very threatening," he said.
But instead of surrendering, the crew retreated to their living quarters, which overlook the deck.
"We had a lot of beer bottles and we made a lot of cocktail [petrol] bombs," said Capt Peng. "We were well prepared. We threw them at them.
"After the first attack they retreated but somehow they got very good weapons - anti-tank weapons - which they fired at us, and succeeded in coming up to our living quarters.
"They came to the first platform which is very close to our living quarters.
"We were locked inside and the door was very thick. They were shouting 'open the door'. So we climbed further up and we used everything to threaten them, bottles, petrol.
"Eventually we used high-pressure water cannon to shoot at them. They were also shooting at us and one bullet passed me about 10in (25cm) away.
"Eventually they retreated, they couldn't fight any more. There was smoke, there was fire."
Asked for shoes
The captain described how the defeated pirates made some unexpected requests as they prepared to leave the Zhenhua 4.
"The head of the pirates said 'stop, stop, we can't go on fighting any more. Let us go'. And I said: 'We will let you go. Leave our ship'."
The pirates were well-armed, the ship's captain said
Mr Peng said that the pirates then asked for shoes because they were barefoot and the deck was covered in broken glass.
Pairs of leather shoes were thrown to them and the pirates retreated - only to return a few minutes later asking for fuel for their speedboats.
Capt Peng added that while the fighting was going on helicopters appeared overhead and started firing at the pirates.
"They helped us succeed," he said.
On Thursday, Chinese foreign ministry spokesman Liu Jianchao told journalists that preparations to dispatch naval vessels were under way.
BBC diplomatic correspondent Jonathan Marcus says it will be the Chinese navy's first active deployment beyond the Pacific Ocean.