Plugin Devolpment help (Timber)

Discussion in 'Plugin Development' started by grahamegarrison, Jul 21, 2014.

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

    grahamegarrison

    Please help im trying to make a timber plugin for minecraft and it is not going to well so here is the coding and yeah

    1. package me.grahamegarrison.ICraftTimber;
    2. import org.bukkit.plugin.java.JavaPlugin;
    3. import org.bukkit.entity.Player;
    4. public class Icrafttimber extends JavaPlugin
    5. {
    6. @Override
    7. public void onEnabled() {
    8. getlogger.info("Icrafttimber has been enabled")
    9. }
    10. @Override
    11. public void onDisabled() {
    12. getlogger.info("Icrafttimber has been disabled")
    13. }
    14. if (player) = (player.break.17:3)
    15. return ("true")
    16. if (player) = (player.break.17:2)
    17. return ("true")
    18. if (player) = (player.break.17:1)
    19. return ("true")
    20. if (player) = (player.break.17)
    21. return ("false")
     
  2. Offline

    AXCoding

    Oh my... That's so hard to read I just have to do this...
    Code:java
    1. package me.grahamegarrison.ICraftTimber;
    2.  
    3. import org.bukkit.plugin.java.JavaPlugin;
    4. import org.bukkit.entity.Player;
    5.  
    6.  
    7. public class Icrafttimber extends JavaPlugin
    8. {
    9.  
    10. @Override
    11. public void onEnabled() {
    12. getlogger.info("Icrafttimber has been enabled")
    13. }
    14. @Override
    15. public void onDisabled() {
    16. getlogger.info("Icrafttimber has been disabled")
    17.  
    18. }
    19. if (player) = (player.break.17:3)
    20. return ("true")
    21. if (player) = (player.break.17:2)
    22. return ("true")
    23. if (player) = (player.break.17:1)
    24. return ("true")
    25. if (player) = (player.break.17)
    26. return ("false")


    @grahamgarrison What exactly is timber supposed to do? The statements
    Code:java
    1. if (player) = (player.break.17:3)
    2. return ("true")
    3. if (player) = (player.break.17:2)
    4. return ("true")
    5. if (player) = (player.break.17:1)
    6. return ("true")
    7. if (player) = (player.break.17)
    8. return ("false")

    Do not make any sense use a BlockBreakEvent + (player is not defined) http://jd.bukkit.org/rb/apidocs/org/bukkit/event/block/BlockBreakEvent.html
    You might want to check out how to code a bukkit plugin, listeners and such...

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 9, 2016
  3. Offline

    Garris0n

  4. Offline

    ChipDev

    Use better grammar in bukkit ^^
     
  5. Offline

    grahamegarrison

    Help me plz that page didnt show me how i make the tree actully fall

    So eny 1 know how to do this

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

    ZodiacTheories

  7. Offline

    grahamegarrison

    Ok so i tried making a block break event but my plugin still isnt working
    Code:java
    1. package me.grahamegarrison.ICraftTimber;
    2.  
    3. import org.bukkit.plugin.java.JavaPlugin;
    4. import java.lang.Object;
    5. import org.bukkit.event.block.BlockEvent;
    6. public class Icrafttimber extends JavaPlugin
    7. {
    8.  
    9. @Override
    10. public void onEnabled() {
    11. getlogger.info("Icrafttimber has been enabled")
    12. }
    13. @Override
    14. public void onDisabled() {
    15. getlogger.info("Icrafttimber has been disabled")
    16.  
    17. }
    18. public BlockBreakEvent(Block 17,Player player)
    19. public Player getplayer
    20. public boolean isCancelled()
    21. public void setCancelled(boolean cancel)
     
  8. Offline

    AoH_Ruthless

  9. Offline

    grahamegarrison

  10. Offline

    Paradrakor

    grahamegarrison
    By the way, it's onEnable and onDisable. You misspelled that.
     
  11. Offline

    Necrodoom

    grahamegarrison Basically, you are not going to code a plugin just like that, you will need some knowledge of java, and then bukkit API to start off. You should look into some basic java tutorials to gain a basic understanding of what you do.
     
Thread Status:
Not open for further replies.

Share This Page