summaryrefslogtreecommitdiffstats
path: root/src/main/java/org/bukkit/event/player/PlayerInteractAtEntityEvent.java
blob: db5678eec65e47cb468ab13c7059ecd2fc44517a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package org.bukkit.event.player;

import org.bukkit.entity.Entity;
import org.bukkit.entity.Player;
import org.bukkit.util.Vector;

/**
 * Represents an event that is called when a player right clicks an entity
 * with a location on the entity the was clicked.
 */
public class PlayerInteractAtEntityEvent extends PlayerInteractEntityEvent {
    private final Vector position;

    public PlayerInteractAtEntityEvent(Player who, Entity clickedEntity, Vector position) {
        super(who, clickedEntity);
        this.position = position;
    }
    
    public Vector getClickedPosition() {
        return position.clone();
    }
}