"Arch" entity component system - New API and code generation update. Check it out ! :)

A few weeks ago I developed a C# high performance ECS designed for game development and data oriented programming : Arch.

Recently there was a new update which added an additional non-generic API, manual memory management and improved code generation using the custom source generator :slight_smile:

As an alternative to generics, you can now access an entity in this way, which has some advantages in some dynamic cases. :

entity.Set(new object[]{ ... });
entity.Has(typeof(...), typeof(...),..);
entity.Get(typeof(...), typeof(...),..);

In addition, you can now influence memory usage and manually free memory when it suits you best.

using var world = World.Create();
// Fill World with entities, delete some
world.TrimExcess(); // Manually free

The source generator of Arch.Extended also had an update and can now generate queries everywhere, is compatible with Unity and Godot and you can mark parameters to pass them through.

public static partial class MyQueries{

    [Any<...>, All<...>, None<...>]
    public static void MoveEntity([Data] in float time, ref Position pos, in Velocity vel){
   .. more query methods

MyQueries.MoveEntityQuery(in deltaTime); // Call generated method. 

Feel free to check it out, leave some comment, feedback or even a star ! :slight_smile: