This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Listener | |
public void onEntitySpawn(SpawnEntityEvent event, @Root Player player) { | |
if (event.getEntities().stream().noneMatch(entity -> entity instanceof Player)) { | |
event.getEntities().forEach(entity -> { | |
//Get your logger here | |
logger.info(entity.getType().toString()); | |
}); | |
} | |
} |