User avatar
MarioBarbero
Topic Author
Posts: 30
Joined: 10 Dec 2024, 20:04

How can I add references of projects in Unity

03 Jan 2025, 15:42

I have 2 solutions in Visual Sudio, one is a Unity project and the it is a solution with common controls and common resources and styles, all in only one project inside solution. Then, that solution added in Unity by package manager. Well, In that solution of components, I have added 2 more projects in Visual studio.
One of those projects is referenced in another and if I compile and execute this solution by Visual Studio,its ok. This is work.
The problem is when execute this in Unity. Unity throws many errors about it cant find these projects refences
How can I add theses references in Unity?

PD.: If I have all file in one project, everything is Ok and Unity works but I dont like to have all file in only one project
 
User avatar
jsantos
Site Admin
Posts: 4823
Joined: 20 Jan 2012, 17:18
Contact:

Re: How can I add references of projects in Unity

03 Jan 2025, 19:30

Hello! How are these projects configured in Unity? Are they different assemblies, packages...
 
User avatar
MarioBarbero
Topic Author
Posts: 30
Joined: 10 Dec 2024, 20:04

Re: How can I add references of projects in Unity

03 Jan 2025, 20:22

Right now, I have 2 solutions, one is a Unity project with many projects inside solution, this is work. And the other solution is a Visual Studio project with common control and other common views and I have only one project in solution (called NoesisProject-blend) and it works fine but now, I have added 2 New projects in this solution and when I update package by package manage in Unity, Unity crashes because doesnt find references these 2 new projects.

The error in Unity is: The type or namespace name `XXXXX’ could not be found. Are you missing a using directive or an assembly reference?

And my question is how can I reference in Unity these new projects? By assemblies or something?

I have attached the images

PD.: Each project in the solution it is a different assembly (different dll file)
Attachments
Projects.png
Projects.png (13.13 KiB) Viewed 2382 times
Error_Image.png
Enum_Project_Utils.png
 
User avatar
jsantos
Site Admin
Posts: 4823
Joined: 20 Jan 2012, 17:18
Contact:

Re: How can I add references of projects in Unity

08 Jan 2025, 18:39

So, let me understand this a bit more, this is not a Noesis question but more a Unity one right?

Are you using Assembly definition assets for your projects?
 
User avatar
MarioBarbero
Topic Author
Posts: 30
Joined: 10 Dec 2024, 20:04

Re: How can I add references of projects in Unity

13 Jan 2025, 14:04

Yes, that was my problem. I did not define the assembly definitions in Unity.
Thank you

Who is online

Users browsing this forum: No registered users and 2 guests