Force set a block to a flower

Discussion in 'Plugin Development' started by HeavyMine13, Jan 22, 2016.

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

    HeavyMine13

    Hey! I am trying to set a block to a Red_Rose, but if the block under it isn't dirt/grass it will break :/, any idea how to force the flower to stay there? Thanks!
     
  2. BlockPhysicsEvent or BlockUpdateEvent can be cancelled for that block
     
  3. Offline

    HeavyMine13

    Doesn't seem to work. Other ideas?
     
  4. Offline

    mythbusterma

    @HeavyMine13

    Change the block by using BlockState#update(...) and pass a single parameter of false to it.
     
  5. Offline

    HeavyMine13

    Wait.. BlockState?

    Doesn't work!

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jan 24, 2016
  6. Offline

    mythbusterma

Thread Status:
Not open for further replies.

Share This Page