Peter could be a disgruntled noble in the fanfiction. He might be someone who has been overlooked for promotions or honors by the emperor, and this has led to his resentment and desire to kill the emperor.
One possible motive could be political ambition. Maybe Peter wants to take over the emperor's power and position in the fictional world. If the emperor has a lot of control and influence, Peter might see killing him as a way to gain that for himself.
Well, the way Peter killed MJ in the comics could vary depending on the storyline and the creative direction of the writers. Sometimes, it could be due to complex plot developments or conflicts within the comic universe.
One reason could be extreme guilt. Maybe he failed to save someone important and can't bear the burden of that failure. In some fanfictions, if he accidentally caused harm to his loved ones, like Aunt May getting hurt because of his superhero activities, the guilt might be overwhelming.