KarmaSpidr
Percy is familiar with dreams, especially the Demigod kind.
Being able to (unwillingly) spy on your enemies and see events that happened thousands of years ago, but are important today, is a very useful ability to have. They could also be tortured at times. Percy would be forced to watch terrible happen, wishing he could stop it, only to be powerless to do anything but watch.
As Percy watched the purple titan effortlessly take down the Avengers, he realised this was probably one of those dreams.
Aka, Percy is forced to watch the end of Infinity War