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: TexturePacker fixes the wrong path for the atlas file. #3124

Merged
merged 2 commits into from
Apr 18, 2024

Conversation

Yayo-Arellano
Copy link
Contributor

@Yayo-Arellano Yayo-Arellano commented Apr 16, 2024

Description

In this PR we updated the code to use Flame.images because of this change now the atlas file and the sprite sheet both must be under the assets/images/ directory.

Trying to run the example project will crash because the atlas find cannot be found.

This MR fixes the problem by loading the .atlas file correctly from the images directory.

Checklist

  • 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

Now the atlas files should be added under the images folder too.
@Yayo-Arellano
Copy link
Contributor Author

Yayo-Arellano commented Apr 16, 2024

@ABausG Can you take a look this MR. It related to another MR you created here.

I think it was not breaking for you because you were overriding the images cache. One simple way to reproduce it is if you try to run the example folder, it will crash because cannot find the atlas_map.atlas under assets/

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

@Yayo-Arellano
Copy link
Contributor Author

Thanks @spydon let's wait a while for @ABausG answer to the comment above, if my suspicions are right then we can merge, but if not then we need to find why it was not breaking for him when doing the implementation,

@spydon
Copy link
Member

spydon commented Apr 18, 2024

@Yayo-Arellano I think we can merge this, it's quite clear that the example can not have been working before. 😄

@spydon spydon enabled auto-merge (squash) April 18, 2024 20:02
@spydon spydon merged commit 69f5c38 into flame-engine:main Apr 18, 2024
8 checks passed
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