Basically it was a physical book, but you didn't read it in a linear way, there were no chapters as such, you would read a passage, and then make a choice, and depending on the choice you would then go to a completely different page of the book. You literally were creating your own adventure. Well Swordbreaker: The Game is basically that but on a Xbox.
You play as the hero who starts the game inside an abandoned castle, and your ultimate aim is to find the hidden treasure, but of course you have obstacles along the way and each screen you come to is another choice, make the wrong choice and you may lose one of your three lives, lose all lives and that's it, you have to start all over again. You may choose to help a Librarian or push over a bookcase, you might choose to help alien, or kill them, every choice matters.
http://www.gamingcouchpotato.co.uk/2020/09/review-swordbreaker-game-on-xbox-one.html