Well, since it is the pit, wearing the uniform of your enemy isn’t ostensibly a war crime, it is a warcrime:
http://www.yale.edu/lawweb/avalon/lawofwar/hague02.htm
Relevant passages are in annex to the convention, section I, Chapter I, Article 1.
Article 1
The laws, rights, and duties of war apply not only to armies, but also to militia and volunteer corps, fulfilling the following conditions:
To be commanded by a person responsible for his subordinates;
To have a fixed distinctive emblem recognizable at a distance;
To carry arms openly; and
To conduct their operations in accordance with the laws and customs of war.
In countries where militia or volunteer corps constitute the army, or form part of it, they are included under the denomination “army.”
Article 2
The population of a territory which has not been occupied who, on the enemy’s approach, spontaneously take up arms to resist the invading troops without having time to organize themselves in accordance with Article 1, shall be regarded a belligerent, if they respect the laws and customs of war.
While any actual civilian who takes up arms to resist invasion is exempted by article 2 from the requirement in article 1 “To have a fixed distinctive emblem recognizable at a distance,” any soldier or member of a militia who removes his uniform can at best hope to be treated as a spy, and as such be liable to execution (after a proper trial, of course) if caught in the act.
Mind you, the only ones likely to be tried for war crimes are usually on the losing side, but there you go. Anyway, it’s only GI Joe. I always wondered why nobody ever got killed with all those blue and red lasers zapping back and forth.