@page usage-of-all-events Usage of all Events This will go over how to utilize each event that FourKit provides. @section entitydamageevent EntityDamageEvent and EntityDamageByEntityEvent \ref Minecraft.Server.FourKit.Event.Entity.EntityDamageEvent "EntityDamageEvent" and \ref Minecraft.Server.FourKit.Event.Entity.EntityDamageByEntityEvent "EntityDamageByEntityEvent" are fired when any entity is damaged. When one of these events are fired, it passes an entity. It can be a Player, or any LivingEntity You can check what type of entity it is with `getEntityType()`. This will return a \ref Minecraft.Server.FourKit.Entity.EntityType "EntityType" enum. From there, you can cast the entity to the actual type (in this case \ref Minecraft.Server.FourKit.Entity.LivingEntity "LivingEntity"): ```csharp [EventHandler] public void entityDamage(EntityDamageEvent e) { LivingEntity entity = (LivingEntity)e.getEntity(); } ``` Or if its a player, you can even cast it to \ref Minecraft.Server.FourKit.Entity.Player "Player": ```csharp [EventHandler] public void entityDamage(EntityDamageEvent e) { if (e.getEntityType() == EntityType.PLAYER) { Player player = (Player)e.getEntity(); } } ``` As of right now, this event is only fired for \ref Minecraft.Server.FourKit.Entity.LivingEntity "LivingEntity" and \ref Minecraft.Server.FourKit.Entity.Player "Player"s.