Item Attributes

onUseOnEntity

This attribute defines the script that is executed when the player right clicks an entity with the item.

Examples

onUseOnEntity = "player.sendMessage('Right clicked an entity!');";