Newer
Older
ultramine_bukkit / src / main / java / org / bukkit / event / vehicle / VehicleBlockCollisionEvent.java
@vlad20012 vlad20012 on 24 Feb 2017 779 bytes initial
package org.bukkit.event.vehicle;

import org.bukkit.block.Block;
import org.bukkit.entity.Vehicle;
import org.bukkit.event.HandlerList;

/**
 * Raised when a vehicle collides with a block.
 */
public class VehicleBlockCollisionEvent extends VehicleCollisionEvent
{
	private static final HandlerList handlers = new HandlerList();
	private final Block block;

	public VehicleBlockCollisionEvent(final Vehicle vehicle, final Block block)
	{
		super(vehicle);
		this.block = block;
	}

	/**
	 * Gets the block the vehicle collided with
	 *
	 * @return the block the vehicle collided with
	 */
	public Block getBlock()
	{
		return block;
	}

	@Override
	public HandlerList getHandlers()
	{
		return handlers;
	}

	public static HandlerList getHandlerList()
	{
		return handlers;
	}
}