The .generateTree() method: How do you properly use it?

Discussion in 'Plugin Development' started by T145, Jan 6, 2012.

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

    T145

    Hello! I've been trying to make the .generateTree() method to work under the onBlockPlace event (you can probably see what I'm trying to use it for! :)) but can't seem to figure out the proper augmentations. If anyone can help, it is greatly appreciated!
     
  2. Offline

    Chiller

    Code:
    event.getPlayer().getWorld().generateTree(event.getBlock().getLocation(), TreeType.TREE);
     
  3. Offline

    T145

    Thanks man! Really helps!
     
  4. Offline

    Simon Welker

    Can it be that it does not work in the #1597 stable 1.0.1 build? I'm trying, but nothing happens.
     
  5. Simon Welker
    Make sure the block you're pointing it on is air.
     
  6. Offline

    Simon Welker

    Thanks mate, I checked again and saw that I wrongly added vectors so it pointed to a block actually two blocks above ground, which won't work either :)
     
Thread Status:
Not open for further replies.

Share This Page