Creating Furnace GUI

Discussion in 'Plugin Development' started by bartboy8, Jul 12, 2012.

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

    bartboy8

    I am attempting to create a furnace gui without right clicking on the furnace block. I have tried to use.
    Code:
    Inventory inv = Bukkit.createInventory(player, InventoryType.FURNACE);
    player.openInventory(inv);
    
    That opens the inventory, but doesn't allow me to smelt anything within it. I can still place items in the slots but it will not work. I am wondering if anyone can help me on this?
     
  2. Offline

    EnvisionRed

    Is there a furnace block nearby or is it a "virtual" furnace that you are carrying around?

    Taking a look at the javadocs I see that the constructor you're using is
    Code:
    createInventory(InventoryHolder owner, InventoryType type)
    So your code would create a furnace inventory belonging to the player. But the reason that wouldn't work is probably because the Player object can't smelt stuff in its inventory without a furnace.
     
  3. Offline

    bartboy8

    It is a virtual furnace I want the player to carry around. Is there any way that we could recreate the effect of the "actual" furnace.
     
  4. Offline

    d33k40

    im interested on this, ill test
     
  5. Offline

    OstlerDev

    He is trying to make the plugin, not get beta testers...
     
  6. Offline

    EnvisionRed

    Hm, maybe set the block state above the player to furnace (without actually changing the block) and then open an inventory for that block state?
     
  7. Offline

    sayaad

    Don't forget to change back the block state of the above block if your going by that method xD
     
  8. Offline

    bartboy8

    I don't quite understand, how can I get the inventory of a block state?
     
  9. Offline

    d33k40

    im not gonna test as beta tester, im gonna test it literaly as developer.
     
  10. Offline

    OstlerDev

    Oh, lol sorry, I thought that you were just another nooblet that wanted a plugin before it was out. Sorry for mistaking that ;)
     
  11. Offline

    d33k40

    Tha point there is that your post adds nothing to the thread.

    PD: Respect people.
     
  12. Offline

    evilmidget38

Thread Status:
Not open for further replies.

Share This Page