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 issue with vision bounds not including the vision origin #4645

Conversation

kwvanderlinde
Copy link
Collaborator

@kwvanderlinde kwvanderlinde commented Jan 17, 2024

Identify the Bug or Feature request

Fixes #4637

Description of the Change

The vision sweep is only well-behaved if it has bounds surrounding the origin. It is not enough that we use the vision bounds since certain cases may not guarantee that the vision shape include the vision origin. So we now make sure to explicitly expand the sweep bounds to include the origin.

Also some separation of concerns: EndpointSet has no reason to know anything about vision, not even just to provide initial bounds. So now it only tracks the bounding box of its contents and nothing else.

Possible Drawbacks

None

Documentation Notes

N/A

Release Notes

  • Fixed a bug where non-STG tokens with small rid vision or lights could generate errors.

This change is Reviewable

The vision sweep is only well-behaved if it has bounds surrounding the origin. It is not enough that we use the vision
bounds since certain cases may not guarantee that the vision shape include the vision origin. So we now make sure to
explicitly expands the sweep bounds to include the origin.

Also some separation of concerns: `EndpointSet` has no reason to know anything about vision, not even just to provide
initial bounds. So now it only tracks the bounding box of its contents and nothing else.
@cwisniew cwisniew added this pull request to the merge queue Jan 21, 2024
Merged via the queue into RPTools:develop with commit dbb53bf Jan 21, 2024
4 checks passed
@cwisniew cwisniew added the bug label Jan 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Development

Successfully merging this pull request may close these issues.

[Bug]: Null Pointer Exception errors with non-snapped to grid tokens using grid sights
2 participants