You are absolutely right. A screening fleet should have 2 objectives: 1) destroy the ships arriving for a port battle or 2) delay the enemy ships so that when they spawn in the port battle, they are at a disadvantage in position and hopefully lower numbers.
In regards to the battle itself, it appears the brits also didn't have a battle caller. They didn't adapt to the situation as it developed. This lead to the perpetual brawl and the sinking of all but 4 ships. In addition, the brits failed to perceive the goal of the battle for the pirates. If the brits could have surmised what the pirate plan was, they could have escaped with more ships.