- Unity 6 or higher
- Go to Window->Package Manager
- In top left corner click + button, choose Install Package from git URL
- Enter
https://github.com/todi1856/com.unity.android.dependency-resolver.git?path=/Package
- That's it, check Edit->Project Settings->Android->Dependency Resolver
Dependency Resolver (UADR) provides the same functionality as Google's External Dependency Manager (EDM4U), but does that through Configuration Manager.
How gradle dependencies are resolved:
EDM4U | UADR |
---|---|
Resolves dependencies: * If templates are disabled - downloads dependencies to Assets/Plugins/Android. * If templates are enabled - injects dependencies into template scripts. If there are local repository specified, creates Assets/GeneratedLocalRepo folder. |
Injects dependencies into gradle files using Configuration Manager. If there are local repositories, those are created directly in gradle project. |
Starting Unity 6, it's recommended to use Configuration Manager for gradle project manipulation, but Configuration Manager cannot patch gradle files if they're patched via templates.
Also, downloading dependencies into Assets/Plugins/Android folder creates dependency conflicts if GameActivity is enabled as application entry point.
Due reasons above, EDM4U might not work for your case, especially if you're targeting GameActivity..
The settings can be located in Project Settings->Android->Dependency Resolver.
Name | Description |
---|---|
Enable Dependency Resolver | When enabled the gradle files will populated with dependency information. |
Refresh Dependencies | You can inspect in advance what dependencies will be added to gradle project and can see the location from where they originate. |