Skip to content

Package manager integration #3

@colinbellino

Description

@colinbellino

Hello there.

I like this project a lot and recently tried to install it on a new project and realised there was no way to install it with Unity Package Manager (UPM).

So i was wondering if you would be open to a discussion and/or pull request about integrating this asset with the new package manager?

I've been playing around with it on a local fork and managed to get it working (see screenshot below). But that would mean changing the folder structure of the project (no code change though), because currently UPM includes all files in a repository (it's on the roadmap).

I've created a really quick and dirty fork here to show what the folders structure might look like.
I think we could make it a lot cleaner but here is a quick list of things i came across to get to this result:

  • UPM includes all folders/files in the project. This is problematic because we don't want the ProjectSettings and Packages folders to be included.
  • UPM will ignore folders with a ~ suffix. So i've moved the Editor and Examples folder to the root and rename Aseprite2Unity to Aseprite2Unity~ as a quick way to exclude it.
  • UPM has a way to link/import sample code. So we can point to the MegaDad example (see package.json). I've taken the liberty to rename it to Samples~ since it's the convention the unity packages use, but that's totally optional.

To use it, you would just have to add this line to your manifest.json for unity to install it.

"aseprite2unity": "git@github.com:Seanba/Aseprite2Unity.git",
// or git@github.com:cbellino/Aseprite2Unity.git for the proof of concept

Okay reading back on what i wrote, that's a bigger comment than i thought it would be (sorry about that). So i would totally understand if you don't have the time or don't want to go this way, no worries :)

Cheers.

What it looks like in the editor:
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions