1
0
mirror of https://github.com/EssentialsX/Essentials.git synced 2025-01-02 14:37:46 +01:00

[API] fix other modules to use new packages

This commit is contained in:
Iaccidentally 2013-07-13 12:40:50 -04:00
parent adb5189d42
commit ecd2484cb9
16 changed files with 28 additions and 34 deletions

View File

@ -1,8 +1,8 @@
package com.earth2me.essentials.antibuild;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.User;
import net.ess3.api.IEssentials;
import java.util.logging.Level;
import org.bukkit.Material;
import org.bukkit.block.Block;
@ -313,14 +313,14 @@ public class EssentialsAntiBuildListener implements Listener
}
}
}
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onBlockDispense(final BlockDispenseEvent event)
{
final ItemStack item = event.getItem();
if (prot.checkProtectionItems(AntiBuildConfig.blacklist_dispenser, item.getTypeId()))
{
event.setCancelled(true);
event.setCancelled(true);
}
}
}

View File

@ -1,9 +1,9 @@
package com.earth2me.essentials.antibuild;
import com.earth2me.essentials.IConf;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.User;
import static com.earth2me.essentials.I18n._;
import net.ess3.api.IEssentials;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.bukkit.Location;

View File

@ -1,8 +1,8 @@
package com.earth2me.essentials.chat;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.Trade;
import com.earth2me.essentials.User;
import net.ess3.api.IEssentials;
public class ChatStore

View File

@ -1,7 +1,7 @@
package com.earth2me.essentials.chat;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
import net.ess3.api.IEssentials;
import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
@ -43,5 +43,5 @@ public class EssentialsChat extends JavaPlugin
pluginManager.registerEvents(playerListenerHighest, this);
}
}

View File

@ -1,17 +1,12 @@
package com.earth2me.essentials.chat;
import com.earth2me.essentials.ChargeException;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.Trade;
import com.earth2me.essentials.User;
import net.ess3.api.IEssentials;
import java.util.Map;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.bukkit.Location;
import org.bukkit.Server;
import org.bukkit.World;
import org.bukkit.entity.Player;
import org.bukkit.event.Listener;
import org.bukkit.event.player.AsyncPlayerChatEvent;
@ -23,7 +18,7 @@ public abstract class EssentialsChatPlayer implements Listener
protected final transient Map<AsyncPlayerChatEvent, ChatStore> chatStorage;
public EssentialsChatPlayer(final Server server,
final IEssentials ess,
final IEssentials ess,
final Map<AsyncPlayerChatEvent, ChatStore> chatStorage)
{
this.ess = ess;
@ -40,7 +35,7 @@ public abstract class EssentialsChatPlayer implements Listener
if (event.isCancelled())
{
return true;
}
}
return false;
}

View File

@ -1,6 +1,6 @@
package com.earth2me.essentials.chat;
import com.earth2me.essentials.IEssentials;
import net.ess3.api.IEssentials;
import java.util.Map;
import org.bukkit.Server;
import org.bukkit.event.EventHandler;

View File

@ -1,8 +1,8 @@
package com.earth2me.essentials.chat;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.User;
import com.earth2me.essentials.utils.FormatUtil;
import net.ess3.api.IEssentials;
import java.util.Locale;
import java.util.Map;
import org.bukkit.Server;

View File

@ -1,9 +1,9 @@
package com.earth2me.essentials.chat;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.User;
import static com.earth2me.essentials.chat.EssentialsChatPlayer.logger;
import net.ess3.api.IEssentials;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Locale;
@ -134,7 +134,7 @@ public class EssentialsChatPlayerListenerNormal extends EssentialsChatPlayer
}
}
}
if (outList.size() < 2) {
event.getPlayer().sendMessage(_("localNoOne"));
}

View File

@ -1,7 +1,7 @@
package com.earth2me.essentials.geoip;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
import net.ess3.api.IEssentials;
import java.util.logging.Level;
import org.bukkit.plugin.PluginManager;
import org.bukkit.plugin.java.JavaPlugin;

View File

@ -3,8 +3,8 @@ package com.earth2me.essentials.geoip;
import com.earth2me.essentials.EssentialsConf;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IConf;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.User;
import net.ess3.api.IEssentials;
import com.maxmind.geoip.Location;
import com.maxmind.geoip.LookupService;
import com.maxmind.geoip.regionName;

View File

@ -2,7 +2,7 @@ package com.earth2me.essentials.protect;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IConf;
import com.earth2me.essentials.IEssentials;
import net.ess3.api.IEssentials;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.bukkit.plugin.Plugin;

View File

@ -1,6 +1,6 @@
package com.earth2me.essentials.protect;
import com.earth2me.essentials.IEssentials;
import net.ess3.api.IEssentials;
import org.bukkit.Material;
import org.bukkit.block.Block;
import org.bukkit.block.BlockFace;
@ -20,7 +20,7 @@ public class EssentialsProtectBlockListener implements Listener
this.prot = parent;
this.ess = prot.getEssentialsConnect().getEssentials();
}
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onBlockIgnite(BlockIgniteEvent event)
{
@ -58,7 +58,7 @@ public class EssentialsProtectBlockListener implements Listener
public void onBlockFromTo(final BlockFromToEvent event)
{
final Block block = event.getBlock();
if (block.getType() == Material.WATER || block.getType() == Material.STATIONARY_WATER)
{
event.setCancelled(prot.getSettingBool(ProtectConfig.prevent_water_flow));
@ -79,11 +79,10 @@ public class EssentialsProtectBlockListener implements Listener
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onBlockBurn(final BlockBurnEvent event)
{
{
if (prot.getSettingBool(ProtectConfig.prevent_fire_spread))
{
event.setCancelled(true);
}
}
}

View File

@ -1,7 +1,7 @@
package com.earth2me.essentials.protect;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.User;
import net.ess3.api.IEssentials;
import java.util.Locale;
import org.bukkit.entity.*;
import org.bukkit.entity.minecart.ExplosiveMinecart;

View File

@ -1,7 +1,7 @@
package com.earth2me.essentials.spawn;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
import net.ess3.api.IEssentials;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.bukkit.Bukkit;

View File

@ -1,13 +1,13 @@
package com.earth2me.essentials.spawn;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.Kit;
import com.earth2me.essentials.OfflinePlayer;
import com.earth2me.essentials.User;
import com.earth2me.essentials.textreader.IText;
import com.earth2me.essentials.textreader.KeywordReplacer;
import com.earth2me.essentials.textreader.SimpleTextPager;
import net.ess3.api.IEssentials;
import java.util.List;
import java.util.Locale;
import java.util.Map;
@ -104,7 +104,7 @@ public class EssentialsSpawnPlayerListener implements Listener
if (!user.isOnline()) {
return;
}
//This method allows for multiple line player announce messages using multiline yaml syntax #EasterEgg
if (ess.getSettings().getAnnounceNewPlayers())
{

View File

@ -1,9 +1,9 @@
package com.earth2me.essentials.spawn;
import com.earth2me.essentials.IEssentials;
import com.earth2me.essentials.IEssentialsModule;
import com.earth2me.essentials.settings.Spawns;
import com.earth2me.essentials.storage.AsyncStorageObjectHolder;
import net.ess3.api.IEssentials;
import java.io.File;
import java.util.HashMap;
import java.util.Locale;
@ -25,12 +25,12 @@ public class SpawnStorage extends AsyncStorageObjectHolder<Spawns> implements IE
{
return new File(ess.getDataFolder(), "spawn.yml");
}
@Override
public void finishRead()
{
}
@Override
public void finishWrite()
{