Help for place a pressure plate

Discussion in 'Plugin Development' started by lecreep, Nov 28, 2019.

  1. Offline

    lecreep

    If i try this code all work fine
    Code:
    Block c = loc2.getBlock();
    c.setType(Material.TORCH);
    
    with these nothing happens
    Code:
    Block c = loc2.getBlock();
    c.setType(Material.LIGHT_WEIGHTED_PRESSURE_PLATE);
    
    Code:
    Block c = loc2.getBlock();
    c.setType(Material.TORCH);
    c.setType(Material.LIGHT_WEIGHTED_PRESSURE_PLATE);
    
    Any help?
     
    Last edited: Nov 28, 2019
  2. Offline

    yPedx

    @lecreep
    Update the the block's BlockState
     
  3. Offline

    lecreep

Share This Page