diff --git a/src/World.cs b/src/World.cs index f139353..c7c5d6f 100644 --- a/src/World.cs +++ b/src/World.cs @@ -391,6 +391,12 @@ namespace MoonTools.ECS return MessageIndex[typeId].First(); } + public void ClearMessages() where T : unmanaged + { + var typeId = GetMessageTypeId(); + MessageIndex[typeId].Clear(); + } + // TODO: temporary component storage? public void FinishUpdate() {