Added World.strikeLightning(). Also renamed WeatherStorm -> LightningStrike.

By: sk89q <the.sk89q@gmail.com>
This commit is contained in:
CraftBukkit/Spigot
2011-04-22 01:25:55 -07:00
parent adf7ef5ccd
commit fbd280daa2
3 changed files with 11 additions and 4 deletions

View File

@@ -78,7 +78,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
else if (entity instanceof EntityItem) { return new CraftItem( server, (EntityItem) entity); }
else if (entity instanceof EntityWeather) {
if (entity instanceof EntityWeatherStorm) {
return new CraftWeatherStorm(server, (EntityWeatherStorm)entity);
return new CraftLightningStrike(server, (EntityWeatherStorm)entity);
} else {
return new CraftWeather(server, (EntityWeather)entity);
}

View File

@@ -3,10 +3,10 @@ package org.bukkit.craftbukkit.entity;
import net.minecraft.server.EntityWeatherStorm;
import org.bukkit.craftbukkit.CraftServer;
import org.bukkit.entity.WeatherStorm;
import org.bukkit.entity.LightningStrike;
public class CraftWeatherStorm extends CraftEntity implements WeatherStorm {
public CraftWeatherStorm(final CraftServer server, final EntityWeatherStorm entity) {
public class CraftLightningStrike extends CraftEntity implements LightningStrike {
public CraftLightningStrike(final CraftServer server, final EntityWeatherStorm entity) {
super(server, entity);
}