Currently, when World:getEntities() is called after creating some entities but before a World:emit, the returned list in World:getEntities() does not actually reflect the current world state. I feel like this might be a bug. Inserting a flush call in World:getEntities() fixes this.
too lazy to fork this to make a PR, sorry. I'm busy in a game jam :p. also i feel like having to fork the repo just to make one code change is a little overkill.