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

Add compatibility with FNA #106

Merged
merged 3 commits into from
Apr 3, 2024

Conversation

nobledemon
Copy link
Contributor

@nobledemon nobledemon commented Apr 3, 2024

Prerequisites

  • I have verified that there are no existing pull requests that would overlap with this pull request.
  • I have verified that I am following the guidelines as outlined in this project's contribution policy
  • I Have verified that this pull request adheres to this project's code of conduct.
  • I have written a descriptive title for this pull request.
  • I have provided appropriate test coverage were applicable.

Description

I did a single line change on TextureAtlas.cs. This is due to the fact that FNA doesn't support as many Rectangle constructors as Monogame does.

I also consulted very briefly on the FNA discord with some people to check what would be the least surprising way to provide support for FNA. As a result, I am proposing the addition of a new project file that expects the library folder to stay next to the FNA and AsepriteDotNet dependencies.

I also manually tested the examples in the regular monogame solution, to check that nothing was broken with this change.

…ureAtlas.cs changed to use the Rectangle constructor with four parameters.
…st surprising way of adding Monogame.Aseprite to a FNA project
Copy link
Owner

@AristurtleDev AristurtleDev left a comment

Choose a reason for hiding this comment

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

Remove the sections addressed in the review

<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
</PropertyGroup>

<!-- Project level package properties -->
Copy link
Owner

Choose a reason for hiding this comment

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

Since FNA isn't distributed via NuGet and this csproj wouldn't be included in the package building done by the cake script, this entire PropertyGroup can be removed.

</PropertyGroup>

<!-- Includes for NuGets -->
<ItemGroup>
Copy link
Owner

Choose a reason for hiding this comment

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

Same as above, this Item group can be removed since this csproj wouldn't be packed for NuGet

Copy link
Contributor Author

Choose a reason for hiding this comment

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

removed the stuff in the next commit

@nobledemon nobledemon requested a review from AristurtleDev April 3, 2024 19:25
@AristurtleDev AristurtleDev merged commit cd33df6 into AristurtleDev:main Apr 3, 2024
3 checks passed
@AristurtleDev
Copy link
Owner

Thansk @nobledemon

gameoflord012 added a commit to gameoflord012/monogame-aseprite that referenced this pull request Apr 20, 2024
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