Open eterlan opened 1 year ago
Hi, I'm new to Entitas, the documents doesn't match the current version. I'm a little confused.
After doing all above it generates 0 files. The generator just create an empty "Generated" folder.
@emadgh Hi, yes it's quite confused.. Did you download the sample project metioned in step 2? Can you generate file with command in that project? If that's fine (should be fine), it should be no problem if you has exactly same folder structure as that sample project has. Also, Don't use the generate button in Jenny, it's broken at this time.
I will add a few comments:
It is all work in win11.
UPD: The problem with the rider's terminal was at my side (rider took local, not global PATH, where dotnet was registered)
@Vikta5 Hi there, the sample project is working and generating code via Terminal is possible, I removed everything and start using it for learning Entitas. Thanks.
I really trying this guide, but in the end just intall the v1.13 :/
the documents doesn't match the current version .it takes me half day to start entitas .here 's my steps.
use "dotnet --info" in cmd to make sure u install the dotnet sdks 6.
download the entitas.zip and jenny.zip in the lastest releases version (like 1.14.1)
unzip them in seprate folder
create a new unity3d project.(for ex: 2021.3.18f)
after this step, the structure like project Sample!
open C# Project once inside unity ,or create a empty C# script after compiled success。
copy the Jenny.properties and Entitas.properties from Sample to project root.
excute cmd :
cd My/Project #which is project root,jeny is here .
dotnet Jenny/Jenny.Generator.Cli.dll gen
u will see the generated code in unity from cmd。
Hi. I have this issue - Specify the project file to use, as this "project path" contains several of these files. What i need to do? Help pls.
where is Jenny.properties and Entitas.properties? please tell me ,brother thankyou
Sorry for the confusion! The setup with Entitas 1.14 changed a little but because I migrated to dotnet 6.0 (instead of mono).
As always, if you have any issues or trouble getting Entitas or Jenny to work, I strongly recommend having a look at the sample game:
Even when the docs are not updated yet, this sample game is always up to date and uses the latest Entitas version. It's always worth checking it.
@huyinings already shared the correct steps to do, I'll summarize them again and try to answer all questions:
Entitas.zip
into your Assets folderJenny.zip
into the root of your project folder, outside of the Assets folderJenny.zip
differently and end up with multiple Jenny subfolders like Jenny/Jenny/Jenny.Generator.Cli.dll
. To avoid confusion please have it the same way as in Match-One
# Example jenny server
dotnet Jenny/Jenny.Generator.Cli.dll server
dotnet Jenny/Jenny.Generator.Cli.dll gen
- you need dotnet 6.0 installed. Latest version is dotnet 7.0 now, but you also need dotnet 6 in order to run Jenny. That's not a problem, you can have multiple dotnet runtimes installed, e.g. dotnet `6.0`, `7.0`, `8.0-preview`. Get dotnet 6.0 here: https://dotnet.microsoft.com/en-us/download/dotnet/6.0
- if you're not quite sure what jenny auto-update does or how it works, don't worry, just copy the [Jenny.properties](https://github.com/sschmid/Match-One/blob/main/Jenny.properties) file from Match-One into you project folder and everything should work. Don't do jenny auto-update after you copied that file. Or at least commit it first to see the changes.
- use the terminal and `dotnet Jenny/Jenny.Generator.Cli.dll server` or `dotnet Jenny/Jenny.Generator.Cli.dll gen` to generate. Jenny uses dotnet 6.0 and roslyn which doesn't work in Unity for now. Generating in Unity while using the roslyn data providers will fail. Generating in the terminal using jenny server is the fastest way to generate, so I think it's fine for now that it does not work in Unity. Btw, I'm currently working on replacing Jenny with C# source generators which will simplify the whole Entitas setup drastically. It will also enable namespaces for contexts and components + will support multiple projects, e.g. when using multiple Unity asmdef. See #1005
If you have further issue let me know, and I'll update my post!
it's pity that such cool project became so absurdly overcomplicated to install/update that it became absolutely unusable. I just spent whole morning trying to figure out the migration process, and still end up with Specify which project file to use because this '/MyPath/To/Project' contains more than one project file.
, this is way too retarded
@thenitro sorry for the inconvenience. The initial setup caused trouble for many, but is essentially the same as previously, only using dotnet 6. I'm to blame for the lack of documentation for Jenny, I'll do better in Entitas 2.0 (by removing Jenny 😅)
For now Match One's Jenny.properties is your best friend
nice! can't wait for Entitas 2.0. I'm currently using 0.13 for my pet city builder project and it works nicely, just wanter to give it a little bump up, anyway good job with Entitas, just don't forget about migration from older versions ))
I've completed all the steps but still have an issue (screenshot attached)
I've completed all the steps but still have an issue (screenshot attached)
The first line causes an exception. But without this line the generation doesn't work properly.
@synthetic-w the exception can happen when the Jenny.properties file is invalid due to wrong syntax. If you can post it we see where the problem is
Downloaded the project Match One on mac Unity 2022.3.13.f1 and 2021 I get an error when generating:
Unable to load shared library 'hostfxr' or one of its dependencies. In order to help diagnose loading problems, consider setting the DYLD_PRINT_LIBRARIES environment variable: dlopen(libhostfxr, 1): image not found
If you have further issue let me know, and I'll update my post!
I've just tried to import your project through your suggestion in this thread and it's still a pain to try and get this working using the Jenny generate.
Are there any real resources on this new update we can actually use?
I'm currently having to run the jenny server and do a 'Generate with server', is that what I'm supposed to do? And should it take this long? Generated 23 files in 192.2 seconds
1) Отсутствует библиотека 'hostfxr' (dotnet fatal error hostfxr.dll) Необходимо перейти в папке /usr (на MacOS через Переход-Переход в папке) и скопировать содержимое папки /local/share/dotnet/"нужная версия dotnet" в папку /local/lib 2) Не может загрузить из библиотеки 'hostfxr' (Unable to load shared library 'hostfxr') Переместить файл libhostfxr.dylib из /usr/local/share/dotnet/host/fxr/"нужная версия" в /usr/local/share/dotnet/shared/Microsoft.NETCore.App/"нужная версия" командой
sudo cp /usr/local/share/dotnet/host/fxr/"нужная версия"/libhostfxr.dylib /usr/local/share/dotnet/shared/Microsoft.NETCore.App/"нужная версия"
Result in my Terminal:
Marat@Marat-iMac ~ % sudo cp /usr/local/share/dotnet/host/fxr/6.0.25/libhostfxr.dylib /usr/local/share/dotnet/shared/Microsoft.NETCore.App/6.0.25
Link: https://github.com/microsoft/vscode-dotnettools/issues/120#issuecomment-1640892593
It's quite struggling for me to grasp all the infomation from issue to setup the project, maybe it's just me not smart enough but anyway. For someone who watch video and want to try this wonderful framework. Tutorial or installing guide is temproraly broken, so follow these steps instead.
Tips: