WoW API < DropItemOnUnit

Drops an item from the cursor onto the specified target. Can be used to initiate a trade session (though see Trade functions) or feeding pets.

DropItemOnUnit(unit);

Parameters[edit | edit source]

Arguments[edit | edit source]

unit 
UnitId - Unit to which you want to give the item on the cursor.

Example[edit | edit source]

if ( CursorHasItem() ) then
  DropItemOnUnit("pet");
end;

Result[edit | edit source]

Item is dropped from cursor and given to the player's pet.

Community content is available under CC-BY-SA unless otherwise noted.