Use Object for EventFilter#ALL

This commit is contained in:
TheMode 2021-06-02 22:51:11 +02:00
parent d58cd3b578
commit b1714641e8

View File

@ -2,7 +2,6 @@ package net.minestom.server.event;
import net.minestom.server.entity.Entity;
import net.minestom.server.entity.Player;
import net.minestom.server.event.handler.EventHandler;
import net.minestom.server.event.trait.*;
import net.minestom.server.instance.Instance;
import net.minestom.server.inventory.Inventory;
@ -14,7 +13,7 @@ import java.util.function.Function;
public interface EventFilter<E extends Event, H> {
EventFilter<Event, EventHandler> ALL = from(Event.class);
EventFilter<Event, Object> ALL = from(Event.class);
EventFilter<EntityEvent, Entity> ENTITY = from(EntityEvent.class, Entity.class, EntityEvent::getEntity);
EventFilter<PlayerEvent, Player> PLAYER = from(PlayerEvent.class, Player.class, PlayerEvent::getPlayer);
EventFilter<ItemEvent, ItemStack> ITEM = from(ItemEvent.class, ItemStack.class, ItemEvent::getItemStack);