Solved How to set certain colors of blocks

Discussion in 'Plugin Development' started by jstN0body, Mar 30, 2020.

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

    jstN0body

    Right now I'm coding a plugin that doing certain things will change blocks to certain colors of blocks, I know how to set a block, I just don't know how to set a certain color of a block. Right now I'm using this to change the block:
    Code:
    Block.setType(Material.STAINED_CLAY);
    so basically I want to be able to set it to different colors of clay.
     
  2. Offline

    NukerFall

    use Colorable
     
  3. Offline

    jstN0body

    @NukerFall I used
    Code:
    Block.setType(Material.STAINED_CLAY).setData((byte) x)
    (x being a number for selecting the color of the clay)
     
Thread Status:
Not open for further replies.

Share This Page