diff --git a/Svelto.ECS/EGID.cs b/Svelto.ECS/EGID.cs index a7e4197..7f1e385 100644 --- a/Svelto.ECS/EGID.cs +++ b/Svelto.ECS/EGID.cs @@ -33,7 +33,7 @@ namespace Svelto.ECS static long MAKE_GLOBAL_ID(int entityId, int groupId) { - return (long)groupId << 32 | (uint)entityId; + return (long)groupId << 32 | (((long)(uint)entityId) & 0xFFFFFFFF); } } } \ No newline at end of file