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

Using the Unity Package Format #10

Open
RichardWepnerPD opened this issue Jan 22, 2025 · 0 comments
Open

Using the Unity Package Format #10

RichardWepnerPD opened this issue Jan 22, 2025 · 0 comments

Comments

@RichardWepnerPD
Copy link

In order to be easier to include this tool into a Unity project, it would be good if the Unity package format would be utilized. Since the Git URLs supported by Unity can specify a path, not the entire repository needs to be adjusted, but at least one directory needs to conform. (I would suggest to use the Assets/MightyTerrainMesh/ directory for this.)

The changes that would need to be done:

  • Must have: add a package.json package manifest (i.e. Assets/MightyTerrainMesh/package.json)
  • Create *.asmdef (Assembly Definition) files in the subdirectories (i.e. Assets/MightyTerrainMesh/Editor/MightyTerrainMesh.Editor.asmdef, Assets/MightyTerrainMesh/Scripts/MightyTerrainMesh.asmdef, Assets/MightyTerrainMesh/Triangle/MightyTerrainMesh.Triangle.asmdef)
    • This will require that there are no circular dependencies between the directories
    • Editor-only directories need to be set to "editor only"
    • Consider following the package layout, even though it doesn't need to be strictly followed
  • Should have: create a README.md within the directory (Assets/MightyTerrainMesh/README.md)
    • it would probably be fine if it just links to the GitHub repository
  • Should have: add a LICENSE.md (Assets/MightyTerrainMesh/LICENSE.md)
    • can be a copy of your LICENSE file

For general information about custom packages, take a look at the Unity manual about custom packages.

The long term advantage (depending on how this project ocntinues) would be that it would be much easier afterwards to get it onto OpenUPM, i.e. simplifying the installation and proper version handling.

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

No branches or pull requests

1 participant