How to erase all "page visit data" in Gamebook mode

Valda
Hi guys, I use a lot the command of "If player has seen page X" then he gets a link to page Y.

I wanted to know, how do I erase all the data? Let's say a player died and I want him to go back to a certain "checkpoint-page" but I want to delete all the pages he visited in the past. How can I do that?

Pertex
You can call the following script:

foreach (page, AllObjects()) {
if (HasBoolean(page, "visited")) {
page.visited = false
}
}


page.jpg

This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums