modified for negascout testing
now runs without runtime error