Board Thread:Questions and Answers/@comment-29905311-20170130083321/@comment-29905311-20170131084710

Mabian wrote: The line you're thinking of is "friendship.../it's really great, right?/let's quit fighting." That line shows up after you've accepted his offer of mercy. It does not change depending on what previous runs you've done, as the only permanent flag in the games files that is ever changed occurs after you've completed a Genocide run.

Meanwhile, Sans observes more and knows more than just how many times he's killed the protagonist.

But if you are dissatisfied with both explanations, then the only other recourse is that Sans is just guessing, as Flowey does at the end of the True Pacifist route in saying "You've probably heard this a hundred times already." He is just making a presumption that in another timeline you befriended him and hoping that it works. I doubt that sans could simply figure out he was friends with the protagonist especially since it is true another reason I doubt that sans simply guessed is that why out of all things sans could have told the protagonist he chose to tell him the lines that I mentioned above which are true and have really happened also I have watched numorus sans fights most of the players that played these fights didn't complete a pacifist run prior and when I watched these fights sans said the line that you said which is that friendship is a good but he didn't say the lines that I mentioned above