Skip to content
This repository has been archived by the owner on Apr 9, 2021. It is now read-only.
/ entitas-vs Public archive

An extension for Visual Studio that makes the workflow with Entitas-CSharp alot smoother.

License

Notifications You must be signed in to change notification settings

nbreum15/entitas-vs

Repository files navigation

Recent update to Visual Studio Tools for Unity

Thanks to everyone trying out the extension. After a new update Unity the Visual Studio Tools for Unity automatically add new items to Visual Studio that is added inside the Assets directory without showing the "Reload Solution" dialog (The Unity Tools also adds the items significantly faster than Entitas-vs).

Therefore I recommend updating to the latest Visual Studio Tools for Unity and bind the code generation inside Visual Studio as described here and not use Entitas-vs as it will not be maintained anymore.

What it is

Download link.

An extension for Visual Studio that makes the workflow with Entitas-CSharp alot smoother.

Motivation

The current workflow with Visual Studio and Entitas is:

  1. Write component(s); save file(s).
  2. Generate files with Entitas CLI (either through CMD or keybind in Visual Studio).
  3. Stay or go back to Visual Studio; Press "Reload Solution" (this is the annoying part).

This extension removes the last two steps, leaving only:

  1. Write component(s); save file(s); stay in Visual Studio.

Nice right?

Important: Requirements

The paid Roslyn Generator is strongly recommand when using this extension because it is able to generate with compiler errors. The Normal Generator from Entitas will also work, but because the Normal Generator is reflection-based, compiler errors will block it from generating (which makes it very cumbersome to work with).

Installation Guide

To use Entitas VS you need to:

  1. Setup Entitas as you normally would (follow one of these guides by the author of Entitas: video guide, text guide)

  2. Make sure that the commandline generator works correctly. Try generating some files before using Entitas VS.

  3. Download the extension here: https://marketplace.visualstudio.com/items?itemName=nbreum.entitas-vs

  4. Fill out the generator path and the trigger paths.

    1. Open Tools -> Entitas VS

    1. Set the generator path.

    Select the Generator folder by pressing the "..." button. If the Generator folder is in the solution directory the path will automatically be converted to a relative path (which is recommended).

    1. Click the drop down-menu to add a project.

    Note: For each project you want to generate files for, the Entitas.properties and User.properties has to be placed in the project directory (beside the .csproj file). This allows for multiple project generation (though only one generator is supported for now).

    1. Add the folders that trigger the code generation when files in the folder are saved. Here the code generator is triggered when changes occur in the Sources\Assets\Components folder. Like the Generator folder, if the Trigger folder is in the project directory, the path will be converted to a relative path.

    1. That is all. Create a new component, save the file, and the generation will run automatically. All these settings are saved in entitas-vs.cfg, in the solution directory.

About

An extension for Visual Studio that makes the workflow with Entitas-CSharp alot smoother.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages