Last Interaction Player (Expression) — Skript

Addon: Skript · Category: Expression · Since: 2.14

Syntax

[the] last player[s] to (attack|interact with|click [on]) %entities%

Description

Returns the last player to attack (left click), or interact (right click) with an interaction entity. If 'click on' or 'clicked on' are used, this will return the last player to either attack or interact with the entity whichever was most recent.

Examples

kill the last player that attacked the last spawned interaction
feed the last player who interacted with {_i}

View source