Skip to content

function useItem (client-side)

Available since version: 0.1.9

This function will try to use, interact, open item by hero/npc.

Declaration

void useItem(int id, int itemId, int state = 0)

Parameters

  • int id: the player id.
  • int itemId: the item id that you want to interact with.
  • int state: the state that you'll start from interacting with item, default is 0.