Some time before the events of the game, Mephiles the Dark was sealed by the time-traveling Shadow the Hedgehog inside the Scepter of Darkness, which was given to him by the dying Duke of Soleanna. However, he left it out in the open, citing that he "knows what will happen to it anyway." It eventually came into the possession of Dr. Eggman and Rouge the Bat was sent to steal it from him under G.U.N.'s orders. Shadow (before he had traveled back in time) went to rescue Rouge and during their escape, Dr. Eggman attacked the duo in hopes of reclaiming the scepter. After a struggle between the three, the scepter was broken, which resulted in the release of Mephiles.
Some time later, Shadow and Rouge came across an archaeologist called Adrianna who was studying the scepter, and after saving her from an attack by Iblis' minions, she read to them an ancient text she discovered about the scepter and Mephiles, although she was unable to comprehend its meaning. After that, the two constructed a new scepter from the Candle of Darkness so that they could re-imprison Mephiles. Ultimately, however, this new scepter could not seal Mephiles and was destroyed in the attempt because he had grown too powerful from the Chaos Emeralds, combined with the present Mephiles absorbing the shade of Shadow when he was released.
Interestingly, when Rouge returns from the future, a G.U.N. soldier calls it the "Book of Darkness" over her intercom, but the in-game subtitles still refer to it as a Scepter. This is most likely a translation error, as "Tobari" (帳) also means "Book" in Japanese.
When the Scepter was broken, it disabled all Badniks around it. This, along with Eggman's order to fall back when it was destroyed, implies that electromagnetism may have been part of the Scepter.