Bukkit-API  1.7.9-R0.2
The inofficial Bukkit-API
EntityBlockFormEvent.java
1 package org.bukkit.event.block;
2 
3 import org.bukkit.block.Block;
5 import org.bukkit.entity.Entity;
6 
7 /**
8  * Called when a block is formed by entities.
9  * <p>
10  * Examples:
11  * <ul>
12  * <li>Snow formed by a {@link org.bukkit.entity.Snowman}.
13  * </ul>
14  */
15 public class EntityBlockFormEvent extends BlockFormEvent {
16  private final Entity entity;
17 
18  public EntityBlockFormEvent(final Entity entity, final Block block, final BlockState blockstate) {
19  super(block, blockstate);
20 
21  this.entity = entity;
22  }
23 
24  /**
25  * Get the entity that formed the block.
26  *
27  * @return Entity involved in event
28  */
29  public Entity getEntity() {
30  return entity;
31  }
32 }