From e7d4bff770b0152814c0522343eebc20e13e1ce8 Mon Sep 17 00:00:00 2001 From: Bukkit/Spigot Date: Fri, 6 May 2011 19:25:43 -0700 Subject: [PATCH] Added World.strikeLightningEffect() that does no damage. By: sk89q --- paper-api/src/main/java/org/bukkit/World.java | 8 ++++++++ .../java/org/bukkit/entity/LightningStrike.java | 13 +++++++++++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/paper-api/src/main/java/org/bukkit/World.java b/paper-api/src/main/java/org/bukkit/World.java index 6f72573991..ba262a5d22 100644 --- a/paper-api/src/main/java/org/bukkit/World.java +++ b/paper-api/src/main/java/org/bukkit/World.java @@ -314,6 +314,14 @@ public interface World { * @return */ public LightningStrike strikeLightning(Location loc); + + /** + * Strikes lightning at the given {@link Location} without doing damage + * + * @param loc The location to strike lightning + * @return + */ + public LightningStrike strikeLightningEffect(Location loc); /** * Get a list of all entities in this World diff --git a/paper-api/src/main/java/org/bukkit/entity/LightningStrike.java b/paper-api/src/main/java/org/bukkit/entity/LightningStrike.java index 5ffd137fca..ea8d7d0f66 100644 --- a/paper-api/src/main/java/org/bukkit/entity/LightningStrike.java +++ b/paper-api/src/main/java/org/bukkit/entity/LightningStrike.java @@ -2,8 +2,17 @@ package org.bukkit.entity; /** - * Represents an instance of a lightning strike entity + * Represents an instance of a lightning strike. May or may not do damage. + * + * @author sk89q */ public interface LightningStrike extends Weather { - + + /** + * Returns whether the strike is an effect that does no damage. + * + * @return whether the strike is an effect + */ + public boolean isEffect(); + }