There are few die well that die in battle.
We may protest that old school D&D characters are not special, unique snowflakes, but who would be satisfied if their character dies from a random artillery shell (or cannon fire) while walking to the battlefield? But if you rule that player characters don't get affected by the vicissitudes of war, you're effectively granting them a degree of plot immunity - bullets fly, lightning bolts zing around, shells explode, but no PC will ever get scratched off camera. Blech.
I'm not a fan of granting player character plot immunity, so here are some ideas to handle the player role when the characters are in a mass combat action.
When the player characters are part of a mass combat without individual actions, one way to share the fate of the larger army is to reduce their resources proportionally to the larger army.
Nautical Example: Two ships trade cannon fire and break it off, and 50% of the crew is killed; it seems fair to reduce player character hit points by 50% (and potentially spells, too, if magic was assumed to be part of the battle).
The players still have a degree of plot immunity - you're not killing 50% of them, like the standard crew - but they feel a portion of the pain when their side takes casualties and damage. Would you give players a saving throw for their characters to avoid the same fate as their unit?
I seem to recall BECMI War Machine might have worked like this as well.
While the larger battle rages, the DM apportions some of the enemy forces to attack the player characters directly, running a standard combat for this side event. It may not have a material effect on the larger combat, other than stressing player resources.
Nautical Example: Boarding and grappling, or even close range small arms fire, where players are confronted by a subset of the opponents, can be handled by letting the players resolve the action using the standard rules.
Instead of engaging in the main fight, the PC's are able to conduct a parallel action that could influence (decisively) the main action. In traditional D&D mass combat systems, this usually involves "hero figures" on both sides (ie, the players take on the squad of ogre stormtroopers or the dragon, while the regular army fights the orc footsoldiers).
Nautical Examples: I don’t see that there always will be opportunities for heroic action - but you could imagine the following scenarios during a ship-to-ship combat: Singling out the opposing captain for a duel; jamming the rudder; destroying the sails and rigging; going below decks to ignite the powder.
More often than not, player "missions" would involve intelligence gathering, ruses, land sieges, or maybe even solo efforts against an enemy ship, and the player's side gains a material advantage during the mass combat due to their successful side missions.
It looks like I'll be doing a basic home brew system for naval combat for the pirate game. I really like Flashing Blades: High Seas, it's a fairly abstract system that looks like it would move quickly to the player action. Player characters would lose resources (the shared fate approach) during the early stages, as ships engage in cannon fire and then firing swivel guns and muskets during the boarding actions. Once the initial boarding turn is resolved, player characters would have the chance to look for individual targets.
The picture is Henry Every, by Angus Macbride from the Osprey book Pirates 1660-1730. His work is frequently in the Osprey books, a great reason for checking them out.