Solved Make a player open his inventory

Discussion in 'Plugin Development' started by libraryaddict, Oct 19, 2012.

Thread Status:
Not open for further replies.
  1. Offline

    libraryaddict

  2. Offline

    TwistedMexi

    If you expect help, you need to share the code that's not functioning.
     
  3. Offline

    libraryaddict

    Its a lack of code.
    I've no idea how to make the player open his inventory.
    Thats it.
     
  4. Offline

    TwistedMexi

    Player.OpenInventory
     
  5. Offline

    libraryaddict

    Ok. That opens A inventory.
    How do I open HIS inventory.
    I want to open it as if I pressed 'e'
     
  6. Offline

    TwistedMexi

    :|

    player.openInventory(player.getInventory());
     
  7. Offline

    libraryaddict

    No.
    That opens his own inventory in a chest view.
     
  8. Offline

    TwistedMexi

    You can make your own inventory view, just make one that mimics a players.
     
  9. Offline

    libraryaddict

    ....

    You know what it looks like when you press 'e' right?
    I assume you have played minecraft before.

    You will see yourself and armor slots.
    A 2x2 crafting grid.
    A hotbar at the bottom.
    Space for inventory.
     
  10. Offline

    TwistedMexi


    Ok, you won't ever get any help if you don't cut the sarcastic attitude. I'm telling you it's possible to make a custom inventory view (including the crafting grid, armor slots and hotbar) so I suggest instead of trying to be funny, you go look up the Inventory and InventoryView.
     
    ZeusAllMighty11 and kroltan like this.
  11. Offline

    libraryaddict

    Sorry but you were rather forthcoming about the information.
    Infact the first 3 replies were ones which anyone could of known easily.

    I didn't realize about the 4th reply however.
    5th reply finally explained all.
     
  12. Offline

    TwistedMexi

    It's hard to know exactly what you need without seeing what the code is trying to accomplish. Even so, it's not my preference to spoon-feed. I'd prefer to step people in the right direction and let them find the working code. I do so not to be rude, but so that they learn and understand what it is the code is doing. Glad you got it sorted out.
     
    kroltan likes this.
Thread Status:
Not open for further replies.

Share This Page