From 26b9ad3a6a5fc60d62b1d68af5d1c83d78f2fb43 Mon Sep 17 00:00:00 2001 From: copygirl Date: Thu, 29 Dec 2022 11:08:48 +0100 Subject: [PATCH] Add IdentifierRef.Count to get count in-use --- src/gaemstone.ECS/IdentifierRef.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gaemstone.ECS/IdentifierRef.cs b/src/gaemstone.ECS/IdentifierRef.cs index adaf549..667ac22 100644 --- a/src/gaemstone.ECS/IdentifierRef.cs +++ b/src/gaemstone.ECS/IdentifierRef.cs @@ -14,7 +14,9 @@ public unsafe class IdentifierRef public bool IsPair => Id.IsPair; public bool IsWildcard => Id.IsWildcard; public bool IsValid => ecs_id_is_valid(World, this); - public bool IsInUse => ecs_id_in_use(World, this); + + public bool IsInUse => ecs_id_in_use(World, this); + public int Count => ecs_count_id(World, this); public IdentifierRef(World world, Identifier id) { World = world; Id = id; }