According to that game, Darth Vader accidentally saved the galaxy by killing the Separatist scientists who were about to unleash a new droid army powered by the tech of the assassin droid HK-47.
In Star Wars, astromechs like R2-D2 are invaluable assets consistently used across the galaxy for various tasks and have served Jedi, Sith ... is an assassin droid disguised as an astromech ...