diff options
Diffstat (limited to 'src/main/java/org/bukkit/event/entity/ItemSpawnEvent.java')
-rw-r--r-- | src/main/java/org/bukkit/event/entity/ItemSpawnEvent.java | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/main/java/org/bukkit/event/entity/ItemSpawnEvent.java b/src/main/java/org/bukkit/event/entity/ItemSpawnEvent.java index 0a19c2f1..bafd934a 100644 --- a/src/main/java/org/bukkit/event/entity/ItemSpawnEvent.java +++ b/src/main/java/org/bukkit/event/entity/ItemSpawnEvent.java @@ -1,6 +1,6 @@ package org.bukkit.event.entity; -import org.bukkit.entity.Entity; +import org.bukkit.entity.Item; import org.bukkit.Location; import org.bukkit.event.Cancellable; import org.bukkit.event.HandlerList; @@ -13,7 +13,7 @@ public class ItemSpawnEvent extends EntityEvent implements Cancellable { private final Location location; private boolean canceled; - public ItemSpawnEvent(final Entity spawnee, final Location loc) { + public ItemSpawnEvent(final Item spawnee, final Location loc) { super(spawnee); this.location = loc; } @@ -26,6 +26,11 @@ public class ItemSpawnEvent extends EntityEvent implements Cancellable { canceled = cancel; } + @Override + public Item getEntity() { + return (Item) entity; + } + /** * Gets the location at which the item is spawning. * |