Ramses II came into the picture only a couple of Pharaohs behind Amenhotep IV, (or Akhenaten) who had drastically changed the religion from polytheism to monotheism. After Akhenaten and his descendants lost power, Pharaohs like Tutankhamun and Ramses II made sure that polytheism was reinstated and the temples and shrines to Akhenaten's gods were hunted down and destroyed. Once this was satisfactory to him, Ramses put up new and grander temples, hoping to appease the gods for the switch the earlier Pharaoh had made. I don't know how you'd feel about some person coming along and forcing you to change your religion from something you've followed your whole life, but I know I'd be pretty mad. If the Ancient Egyptians felt that way, they sure must have been glad when Ramses came along!