• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Magicolo_Land · Dec 19, 2018 at 07:35 PM · dlllicensedependenciesgithubdistribution

Can I distribute Unity's DLL with an open source project?

I am developing a soon-to-be non-commercial open source project that has some dependencies on some Unity dlls (UnityEngine.CoreModule.dll, UnityEditor.dll, etc.). The project is developed outside of a Unity project and so, in order to resolve the Unity dependencies, I make local copies of the Unity dlls next to the project and reference them relatively (referencing the dlls directly in "Program Files/Unity/Hub/Unity2018.x.x/etc." is not a viable option).

This means that when the project goes open source, the dlls would be included on GitHub in order to allow contributors to easily setup their development environment. I was wondering if there were license issues associated with this practice and if so, how do I mitigate those issues?

Note that the project is looking to be MIT licensed.

Thanks.

Comment
Add comment · Show 3
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image dan_wipf · Dec 19, 2018 at 07:43 PM 0
Share

maybe if peoples still have a copy of unity engine on their pc and you’re only referencing the dlls, i guess your good to go. https://blogs.unity3d.com/2018/03/26/releasing-the-unity-c-source-code/

but i would say if you attach the dlls, it’s against the unity idea of open source..

avatar image Magicolo_Land dan_wipf · Dec 19, 2018 at 08:16 PM 0
Share

Thanks for the link. It sure gives me hints on what the Unity policy is on the subject.

I don't mind requiring users to have a version of Unity installed on their machine since this project doesn't make any sense without Unity but I don't want to be referencing dlls directly in the Unity installation folder since this path is not reliable between different environments.

I guess that if I have a reliable way to resolve Unity's installation folder (without using Unity's API) I could copy the required dlls to the project local folder.

avatar image dan_wipf Magicolo_Land · Dec 20, 2018 at 08:53 PM 0
Share

have you tried to ask unity personaly over mail?

2 Replies

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by Bunny83 · Dec 20, 2018 at 09:05 PM

No, you can not. The UnityEngine.dll and other modules are part of the Unity engine. They can be distributed with a game build with the Unity engine. You are no allowed to use of distribute parts of the engine outside a Unity project.


Apart from that most things you find inside the UnityEngine.dll requires the native core of the Unity engine as many parts of the UnityEngine.dll are just wrapper classes which refer to externally defined methods. This is not only true for the various component classes but also parts of the strucs (like Vector2/3/4, Matrix4x4, Quaternion, ...).


I don't think there's anything inside the UnityEngine.dll that would be worth using outside of Unity. If it's something simple it's probably easier to implement the functionality yourself. If it's more complex it most likely depends on the engine core anyways. What exatly are you using from those assemblies?

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image disuperguy · Aug 25, 2020 at 04:01 AM 0
Share

I wanted to use its JsonUtility class, but sadly the dll's dont work outside of Unity, also your not aloud to do it.

avatar image
0

Answer by Magicolo_Land · Dec 21, 2018 at 04:38 PM

Thank you for the precision. Your first point makes it very clear.

As for the second point, I am very well aware that Unity dlls require the underlying engine to be running and since the project I am developing is meant to be used with a running instance of Unity, this should not be an issue. I mainly need to reference the dlls to get the project to compile and so in the compiled project, Unity's dlls are not required. Sorry if was not clear enough, but I need the dlls only when developing the project but since the project is soon-to-be open sourced, I want the whole development setup to be publicly available, including project-local copies of Unity's dlls (to get the project compiling).

Since distributing the copies of Unity's dlls is not possible, what would be the preferred way (that would work cross-platform) of retrieving them from an existing Unity installation? Note that I'd rather have a solution that doesn't require Unity to be running such that one can open the project in 'Visual Studio', hit compile and all dlls should be resolved. If nothing else works, I will require users to lauch Unity and I will use 'EditorApplication.applicationPath' to retrieve the dlls.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.



Follow this Question

Answers Answers and Comments

100 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Prefabs not finding MonoBehaviours moved into a plugin DLL 1 Answer

Findout Dll Dependency, System.dll and Mono.Security.dll 1 Answer

How to implement DLL licensing? 0 Answers

Unable to remove old dll dependencies 1 Answer

How to work around github with paid asset store assets? 0 Answers

  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges