added "useallstars" utility function and fixed two flag bugs