getCursor

public final ItemStack getCursor()

Get the item on the cursor of one of the viewing players.

Return

The item on the player's cursor, or null if they aren't holding one.