Skip to content
New issue

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

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

Already on GitHub? # to your account

fix: solid circles and polygons intersection #2067

Merged
merged 5 commits into from
Oct 12, 2022

Conversation

mattmyne
Copy link
Contributor

Description

This PR fixes polygons inside a solid circle and circles inside a solid polygon not being correctly detected.
(This relates to Flame's collision detection, not Forge2D)

Checklist

  • The title of my PR starts with a Conventional Commit prefix (fix:, feat:, docs: etc).
  • I have followed the Contributor Guide when preparing my PR.
  • I have updated/added tests for ALL new/updated/fixed functionality.
  • I have updated/added relevant documentation in docs and added dartdoc comments with ///.
  • I have updated/added relevant examples in examples or docs.

Breaking Change?

  • Yes, this PR is a breaking change.
  • No, this PR is not a breaking change.

Related Issues

Polygons inside a solid circle and circles inside a solid polygon were not being correctly detected.
@spydon
Copy link
Member

spydon commented Oct 11, 2022

Could you add a test that verifies that it works too?

@mattmyne
Copy link
Contributor Author

Yes working on that now. I figured the tests would be a separate PR rather than rolling it into this bug fix?

Copy link
Member

@spydon spydon left a comment

Choose a reason for hiding this comment

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

Looks good! Only nit is that the tests should be moved

@spydon spydon merged commit 62c5c2e into flame-engine:main Oct 12, 2022
@mattmyne mattmyne deleted the circlepolygon-intersection-fix branch October 12, 2022 08:20
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants