Always fun reading folks in this era commenting on actions taken long before - their grandparents were around... All of those rifles recovered at Gettysburg that were still loaded (unfired) doesn't say as much about the terrible stress on the combatants as it does about the terrible effects of battle's queen.. the artillery that was killing advancing soldiers before they could ever get into range to fire their weapons.... Remember this about the Civil War - they used Napolean's tactics but the armies on both sides used much more lethal weaponry (and cannon fire...). Made for a terribly bloody affair from start to finish...
As far as stress under fire making it impossible to count your rounds... That's why you train, practice, and train some more.... To be able to keep your head in very very bad situations is why training and repeated practice is so important for anyone actually going into an armed confrontation..... I worked with folks that really could tell you exactly how many rounds they'd fired at any given moment - and where each one of those rounds went - even in a lethal action where the other guy is shooting back. No, that's not something an ordinary soldier or casual armed citizen has any ability to do. The potential is there though as long as you have the dedication, skill, and practice over and over again...