Hello, when I use $level->getEntities() at onEnable() it's return an empty array but there are entities in this world.It's normal ?Sorry for my bad english. Thank's you in advance
Yes it is. Level->getEntities() returns an array with only the entities in the loaded chunks, which means it will return [] because there are no chunks loaded yet.