Three Chinese warships sailed out of Sydney on Friday after an unannounced visit that came amid a tussle for influence between Australia and China in the Pacific.