in reply to Question regarding variable scope
Take a look at perldoc perlsyn (the section on Foreach) for more information but the short answer is yes.
and is there a way to get the behavior I'm looking for, short of using some kind of intermediate variable?
As Roger shows above just change your looping variable, and set $black_player to the value you before you exit the loop.
-enlil
|
|---|