Bow.

Discussion in 'Plugin Development' started by Roan1, Mar 23, 2012.

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

    Roan1

    Which event and event function i must use, when player use bow?
     
  2. Offline

    zwap1233

  3. Offline

    Darkman2412

  4. Offline

    Technius

    EntityShootBowEvent

    Checking if it is a player:
    Code:java
    1. @EventHandler
    2. public void onEntityShootBow(EntityShootBowEvent event)
    3. {
    4. if(event.getEntity() instanceof Player)
    5. {
    6. Player player = (Player)event.getEntity();
    7. //your other code
    8. }
    9. }[/syntax=java]
     
    Roan1 likes this.
  5. Offline

    Roan1

    thank.
     
  6. Offline

    zwap1233

    Darkman2412
    so he knows when the player is getting a bow in his hand.
    i didn't saw a bow shoot event so mabey he can do something whit this. and that is a list whit all classes and event of bukkit.
     
Thread Status:
Not open for further replies.

Share This Page