This is Deathwing Over Veynaa, the second book from Douglas Hill's Last Legionary series. While the series has come up in many other questions, this may be the first time anymore has asked specifically about the second (and possibly least read) volume.
Here are the two most common covers:
Everything you describe is part of the plot. The main plot, as described by Wikipedia:
Keill Randor is sent to a planet by the Overseers, to determine if their recent turn to aggression has its roots in the Warlord's influence. On the planet, he encounters a new leader, an albino called Quern. It transpires that Quern is an altered human, and strongly telepathic, though Glr is able to shield Keill's mind from Quern's probing. Quern has developed a planet-killing weapon, and has convinced the ruling council that this weapon justifies their new aggression. They are attacking from a position of absolute strength. The weapon turns out to be the very same weapon which killed Keill's planet; a form of radiation spore which multiplies rapidly in an oxygen atmosphere, killing every living thing.
However, it turns out that Kiell's female interest, Joss, is also a Deathwing agent. She almost gets Kiell caught by a robot, but (as Deathwing agents always do) she wants to kill him herself and stops to gloat. In the ensuing fracas, she ends up trapped in the arms of a crushing robot that had earlier been after Kiell. He abandons the spacecraft they are on, which is carrying Quern's last radiation bomb, but before he goes, he programs the ship to jump into Overlight, with no corresponding exit coordinates.
There is a PDF of the book that is easy to locate online, but be warned that the OCR is quite poor. (The main setting, The Cluster, keeps being rendered as "The Ouster.")