Skip seen text based on translation identifiers (#5628) #5740
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Skip node if the current translation_identifier was previously seen: this allows the player to skip through texts that were seen in a previous playthrough, even when the developer mistakenly deletes or regenerates .rpyc files while preparing a game update, which changes node identifiers and breaks the list of previously seen nodes.
Limitation: only applies to translatable content, so not to e.g. image displays.
This is still a solid QoL improvement for the player, who needn't remember each and every path they might have already gone through in the previous game update/"episode" months/years ago.
T 8000 ranslations are now considered seen after we progress to the next node (as with seen nodes), not when we execute them; this avoids skipping all texts unconditionally in the above, and also de-duplicates the counting code.
FIXME: ctx.translation_identifier is not reset so it can be used by the above; this probably should be fixed but currently allows discussing this first proof-of-concept.
Fixes #5628
What do you think of this approach? :)