Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX CRASH: call getIndexForTarget only when targetSequence is not nil #30

Merged
merged 1 commit into from
Jan 11, 2025

Conversation

ninovanhooff
Copy link
Contributor

A crash introduced in Panels 2.0 occurs when a cutscene ends without a targetSequence.

The cause is that getIndexForTarget is called even when targetSequence is nil

In this PR, a nil check is added to prevent a crash. I did not test this with a branching storyline, only that the original behavior of calling the callback with nil is restored.

Please consider wether this is merely a workaround or an actual fix

@cadin cadin merged commit dad5a94 into cadin:main Jan 11, 2025
@ninovanhooff ninovanhooff deleted the fix/cutscene-ended-crash branch January 12, 2025 21:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants