As “The Return of the King” is taking the world by storm I think it is suiting to point to this entertaining and informative article from Popular Science last November (after the release of “The Two Towers“). The article explains the AI system that is used to control the characters in the massive battle scenes.
Each orc in a battle has a “mind of his own” making decisions and responding to unexpected happenings. The same goes for every elf, man, uruk-hai, ghost, troll, ent and what have you. The decision trees that are used in the AI system are quite complex, and even though “intelligence” is hardly a word one would directly associate with an average orc, the AI orcs perhaps turned out to be more clever than intended:
“In another early simulation, Jackson and Regelous watched as several thousand characters fought like hell while, in the background, a small contingent of combatants seemed to think better of it and run away. They weren’t programmed to do this. It just happened.” (page 4)