Spoiler warning! This section contains plot details about the game.
Depending on protagonist's choices one of three endings can be achieved:
If you defeat Magusar before finishing all the main story chapters in Librom, the game ends immediatly after Magusar's defeat, with the protagonist musing about how his/her actions have saved himself/herself, but the future of the world is still uncertain.
If you complete all the main story chapters and choose to sacrifice Magusar in the final battle, then the Sacred Chalice fulfills your wish and returns the world to its original form, however the protagonist is left with the curse of Magusar and his right arm, unsure of what the future holds for him/her or the world but still believing that hope can change it for the better.
If you complete all the main story chapters and choose to save Magusar, the protagonist begin a cycle of defeating and saving Magusar over and over again, while the line between the protagonist and Librom becomes blurred and they become one. They fight with Magusar for years until the protagonist's body breaks down and can no longer fight. Like the original Librom, they sacrifice their body to become a book that will pass on both their story and Librom's tale to the next prisoner that can take on Magusar.