Skip to content
This repository has been archived by the owner on Nov 20, 2024. It is now read-only.

fix: Clipped attachments don't have an assigned batcher #21

Merged

Conversation

uorbe001
Copy link
Contributor

When updating the batchableSpineSlot, this assumes the batcher is defined, but when an attachment is clipped the batcher is never assigned leading to that call crashing because the batcher is undefined. This is just a quick fix to prevent this error.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
When updating the `batchableSpineSlot`, [this assumes the batcher is defined](https://github.com/pixijs/spine-v8/blob/main/src/SpinePipe.ts#L151), but [when an attachment is clipped the batcher is never assigned](https://github.com/pixijs/spine-v8/blob/main/src/SpinePipe.ts#L114) leading to that call crashing because the batcher is undefined. This is just a quick fix to prevent this error.
Copy link
Member

@GoodBoyDigital GoodBoyDigital left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice! good catch!

@Zyie Zyie merged commit 24339b0 into pixijs:main Jun 17, 2024
1 check passed
@uorbe001 uorbe001 deleted the fix/clipped-attachments-dont-have-a-batcher branch June 18, 2024 07:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Undefined batcher in SpinePipe.updateRenderable() with empty clipping vertices
3 participants