Check if Chest BlockState is part of Double Chest?

Discussion in 'Plugin Development' started by InfiniteMinecraft, Jul 5, 2013.

Thread Status:
Not open for further replies.
  1. If I am looking through the BlockStates in a loaded chunk, how can I tell if one chest blockstate is a part of a double chest? and if it is, get the doublechestinventory?
  2. Offline


    I guess you could do chest.getContents() on it and then check the size of the list. If it's 54, it's a double. Or would BlockState not capture the chest contents? I'm not really familiar with it, but it captures metadata according to the documentation so you should be good.
  3. Offline


    if(someState instanceof DoubleChest){ // double chest }
  4. Offline


    Do DoubleChest states exist as a member of the BLOCK though? I thought they only existed temporarily while a player has opened the chest.
Thread Status:
Not open for further replies.

Share This Page