Together, they would lead the 212th Attack Battalion in several large-scale battles against the droid armies. Throughout this time, Cody often served with Jedi General Obi-Wan Kenobi, building the respect that can be seen between the two in Revenge of the Sith. Properly named CC-2224, Commander Cody first appeared on screen in Revenge of the Sith, after which The Clone Wars would go on to cover some of his history in the war. Although born identical for all practical purposes, some of these clones, Cody among them, were given additional training meant to qualify them for positions of greater power and responsibility.
An event first mentioned off-handedly in A New Hope, the Clone Wars was a conflict between the Galactic Republic and the Confederacy of Independent Systems that served as the backdrop to the TV series and film of the same name, as well as to Revenge of the Sith. The Republic's forces were composed primarily of a large clone army grown by Kaminoan scientists from the genetic blueprint of bounty hunter Jango Fett. When Emperor Palpatine initiated Order 66 in Star Wars: Episode III - Revenge of the Sith, Commander Cody was among the clone troopers that turned against their Jedi compatriots - but he survived long after betraying Obi-Wan Kenobi.