Class EntityItemPickupEvent
- java.lang.Object
-
- net.minecraftforge.eventbus.api.Event
-
- net.minecraftforge.event.entity.EntityEvent
-
- net.minecraftforge.event.entity.living.LivingEvent
-
- net.minecraftforge.event.entity.player.PlayerEvent
-
- net.minecraftforge.event.entity.player.EntityItemPickupEvent
-
public class EntityItemPickupEvent extends PlayerEvent
This event is called when a player collides with a EntityItem on the ground. The event can be canceled, and no further processing will be done. You can set the result of this event to ALLOW which will trigger the processing of achievements, FML's event, play the sound, and kill the entity if all the items are picked up. setResult(ALLOW) is the same as the old setHandled()
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class net.minecraftforge.event.entity.player.PlayerEvent
PlayerEvent.BreakSpeed, PlayerEvent.Clone, PlayerEvent.HarvestCheck, PlayerEvent.ItemCraftedEvent, PlayerEvent.ItemPickupEvent, PlayerEvent.ItemSmeltedEvent, PlayerEvent.LoadFromFile, PlayerEvent.NameFormat, PlayerEvent.PlayerChangedDimensionEvent, PlayerEvent.PlayerChangeGameModeEvent, PlayerEvent.PlayerLoggedInEvent, PlayerEvent.PlayerLoggedOutEvent, PlayerEvent.PlayerRespawnEvent, PlayerEvent.SaveToFile, PlayerEvent.StartTracking, PlayerEvent.StopTracking, PlayerEvent.TabListNameFormat, PlayerEvent.Visibility
-
Nested classes/interfaces inherited from class net.minecraftforge.event.entity.living.LivingEvent
LivingEvent.LivingJumpEvent, LivingEvent.LivingUpdateEvent, LivingEvent.LivingVisibilityEvent
-
Nested classes/interfaces inherited from class net.minecraftforge.event.entity.EntityEvent
EntityEvent.CanUpdate, EntityEvent.EnteringChunk, EntityEvent.EntityConstructing, EntityEvent.Size
-
-
Field Summary
Fields Modifier and Type Field Description private ItemEntity
item
-
Constructor Summary
Constructors Constructor Description EntityItemPickupEvent(PlayerEntity player, ItemEntity item)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ItemEntity
getItem()
-
Methods inherited from class net.minecraftforge.event.entity.player.PlayerEvent
getPlayer
-
Methods inherited from class net.minecraftforge.event.entity.living.LivingEvent
getEntityLiving
-
Methods inherited from class net.minecraftforge.event.entity.EntityEvent
getEntity
-
-
-
-
Field Detail
-
item
private final ItemEntity item
-
-
Constructor Detail
-
EntityItemPickupEvent
public EntityItemPickupEvent(PlayerEntity player, ItemEntity item)
-
-
Method Detail
-
getItem
public ItemEntity getItem()
-
-