Entitas-csharp: Q: Use Entitas on server-side

Created on 11 May 2018  路  4Comments  路  Source: sschmid/Entitas-CSharp

Hi,

I've asset store version of Entitas, how to use them on my server-side code(C# project)? EntitasPure seems out of date, shall I use it as a template and replace some file?

Can I use Roslyn plugin with the C# project?

Cheers

question

All 4 comments

I also was wondering If it was possible to manually update EntitasPure

OK, here's how I made it.

  1. Import from Asset Store, so now we have Jenny.zip and a few other files.

  2. Create a new Class Library project in VisualStudio/Rider, for example, name it MyEcs.

  3. Unzip Jenny.zip, copy everything into the MyEcs root folder.

  4. Open PowerShell in the root folder (Hold Shift and right-click on any blank area).

  5. Run .\Jenny\Jenny.exe new prefernces.properties, this will give you a new prefernces file.

  6. Edit prefernces.properties, change DesperateDevs.CodeGeneration.Plugins.ProjectPath value to match up your project name, say MyEcs.csproj, then save and exit.

  7. Run .\Jenny\Jenny.exe auto-import -s and select the Roysln generator.

  8. Run .\Jenny\Jenny.exe doctor to see if everything is OK, then run .\Jenny\Jenny.exe gen. If nothing bad happens, you should able to see the same folder structure has been generated just like you saw in Unity.

  9. Create a folder and name it Libs in the root folder, copy DesperateDevs.Utils.dll, Entitas.CodeGeneration.Attributes.dll, Entitas.dll from YourUnityProjectPath\Assets\Entitas\ into the Libs folder.

  10. Open MyEcs in your IDE, add reference to dlls you just copied. You're good to go now.

However, I'm NOT sure if there's any dll file is needed/unneeded. Would be appreciated if anyone can confirm that.

Cheers

A while ago you needed a separate project for the code generation part. This is why I create EntitasPure, so people have a starting point with the generator project already set up.

With the newer versions of Entitas, we don't need that anymore.

  • Unzip Jenny.zip to your project root
  • run .\Jenny\Jenny.exe new Entitas.properties (don't navigate into the Jenny folder, but the project root)
  • open and update all values in Entitas.properties
  • run .\Jenny\Jenny.exe auto-import -s

from then on you can run .\Jenny\Jenny.exe gen or the more convenient way .\Jenny\Jenny.exe server

Your c# only project needs to reference all dll that are not in the Editor folder

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sschmid picture sschmid  路  4Comments

xkyii picture xkyii  路  3Comments

fayte0618 picture fayte0618  路  5Comments

vaudevillian picture vaudevillian  路  3Comments

Stals picture Stals  路  4Comments