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: Isometric tile map component uses scale when getting block from position #1569

Merged
merged 5 commits into from
Apr 27, 2022

Conversation

RFager
Copy link
Contributor

@RFager RFager commented Apr 24, 2022

Description

Taking scale in consideration when getting a block from IsometricTileMapComponent. This will allow for scaled maps to return the correct block.

Checklist

  • The title of my PR starts with a Conventional Commit prefix (fix:, feat:, docs: etc).
  • I have read the Contributor Guide and followed the process outlined for submitting PRs.
  • 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.

Breaking Change

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

Related Issues

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.

Lgtm! Would be great with a small test that verifies that it fixes the bug (and to make sure that no regression is done later).

https://github.com/flame-engine/flame/blob/main/packages/flame/test/components/isometric_tile_map_component_test.dart

@RFager
Copy link
Contributor Author

RFager commented Apr 25, 2022

The functions for getting blocks and positions related to the blocks. I've also modified the blocks test to use scale.

@RFager RFager requested a review from spydon April 25, 2022 18:51
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.

Lgtm! You just need to run melos format or flutter format . and it should fix the analyze and formatting issues.

@spydon spydon enabled auto-merge (squash) April 27, 2022 16:08
@spydon spydon merged commit 0c43078 into flame-engine:main Apr 27, 2022
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.

3 participants