added conditional for checking game mode