Yes, it is critical to not let your focus split, and always stay true to the most important goal.
If you're a robot.
"Doing cool stuff" is one of the major, most basic drives behind progress of science and technology. Definitely more honest than "doing it for the money" or "doing it for social status", where you can always find ways to cheat if the going gets annoying. "Doing cool stuff" is up there with "doing it to save ourselves from an imminent, lethal threat" - the other highly reliable motivator that has little tolerance for bullshit, and was responsible for most of the rapid progress thorough history. Of the two, I'd prefer the one that doesn't involve violence and fear of death. It's probably more sustainable, too.
See also: something something Feynman on having fun in research.
Consider also: Most progress happens in small increments; the set of people motivated by wanting to solve climate is small, so it doesn't really hurt to also add the people motivated by doing cool shit in parallel. The chance of getting critical increment doubles; the chance of any one in any of the two groups having the full solution is ~zero.