Advertisement
Guest User

Untitled

a guest
Jun 5th, 2013
57
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. @EventHandler
  2. public void onPlayerInteractBlock(PlayerInteractEvent evt){
  3. if(evt.getPlayer().getItemInHand().getTypeId() == Material.FISHING_ROD.getId()){
  4. //maximal distance between player and thunder is 200 blocks
  5. evt.getPlayer().getWorld().strikeLightning(evt.getPlayer().getTargetBlock(null, 200).getLocation());
  6. }
  7. }
Advertisement
RAW Paste Data Copied
Advertisement