Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Make items don't appear in hotbar

Comments in 'Plugin Development' started by Flabe, Apr 30, 2016.

  1. Flabe
    Offline

    Flabe Active Member

    Joined:
    Nov 17, 2015
    Posts:
    147
    Minecraft User:
    Flabe231
    Hey guys, i am adding items in player inventory by : $player->getInventory()->addItem(Item::get($id));
    I want to add item that won't be shown in players hotbar but it will be shown into inventory.
    Thank you for attention. I need your help, please^-^
  2. Flabe
    Offline

    Flabe Active Member

    Joined:
    Nov 17, 2015
    Posts:
    147
    Minecraft User:
    Flabe231
    nobody know?
  3. Irish
    Offline

    Irish Active Member

    Joined:
    Apr 24, 2016
    Posts:
    96
    Minecraft User:
    _Irish_
    Have you tried $player->getInventory()->sendSlot($index, $target); I'm not sure about the parameters, they could be different.
  4. Irish
    Offline

    Irish Active Member

    Joined:
    Apr 24, 2016
    Posts:
    96
    Minecraft User:
    _Irish_
    Use it after adding the item?
  5. Flabe
    Offline

    Flabe Active Member

    Joined:
    Nov 17, 2015
    Posts:
    147
    Minecraft User:
    Flabe231
    hmm ^ could you give me an example?
  6. Flabe
    Offline

    Flabe Active Member

    Joined:
    Nov 17, 2015
    Posts:
    147
    Minecraft User:
    Flabe231
    oh it works thank you so much!!!
  7. Irish
    Offline

    Irish Active Member

    Joined:
    Apr 24, 2016
    Posts:
    96
    Minecraft User:
    _Irish_
    Yep :)

Share This Page

Advertisement