Multiple Projects require Module class if they reference eachother.
Release Type: official
Version: 4.2.0.2122
Platform(s): Windows
Describe the bug When you hae a multiproject structure and the projects reference eachother, they wont show components in the GameStudio.
To Reproduce Steps to reproduce the behavior:
- create base project
- add another project through VS
- add a StatupScript to the external project
- Now you should see the Script in GameStudio after a restart
- create a reference between the external project and the main
- after retarting GameStudio you will not see the components in that external project anymore
Expected behavior The components should still show in the drop down since it will be very likely the references will exist.
Additional context There is a work around, in each of the external projects you can add a Module class and the components should show up normally.
Repro: https://github.com/Doprez/MultiProjectIssue/tree/main
https://github.com/stride3d/stride/commit/26c36962fbd02868369a89da1c893278f4f14f88
Should be related to the commit above once this gets looked into.
Module shouldn't be required. But you should need to reference the asset compiler package, which I think was always the case. Not sure if a package file is necessary. I think it does if there are assets other than code.
Also it's unclear which project references which one in your case, as two projects cannot each reference each other. That's not allowed in .NET.
the sdpkg file is ( should ) only be needed when you have assets in your sub project
the module is the current workaround around that bug
Also it's unclear which project references which one in your case, as two projects cannot each reference each other. That's not allowed in .NET.
My mistake, the amount of projects dont matter in this case I was just testing 2 scenarios.
- if the project exists in the solution but doesnt reference the main project then components show up in editor
- if the project exists in the solution but does reference the main project then components do not show up in editor
I think I may have messed up my repro if the project does not show those 2 scenarios and I will fix it when I can.
I will also see if the same issue applies if the Asset Compiler is referenced, I did not try with that.
for more context, there was a discussion Joreyk, Vaso and I had in Discrod here
the problem is in the projectwatcher afaik
1. change the Class2
2. projectwatcher sends a broadcast with the change list of OddBehaviour ( only that project, because csproj changed??? )
3. triggers reload screen
4. projectwatcher sends broadcasts with the changes oddbehaviour.test2.dll
5. dll changes arent included in the reload as binary changes will get ignroed for the relaod screen :(
in addition to that.. why are these binary changes? its a project change... it shouldnt even happen