mirror of
https://github.com/EngineHub/WorldGuard.git
synced 2025-01-12 03:13:40 +01:00
updated imports and comments
This commit is contained in:
parent
23970a4e36
commit
a091a32c26
@ -23,7 +23,6 @@
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import org.bukkit.block.Block;
|
||||
import org.bukkit.block.BlockDamageLevel;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.entity.LivingEntity;
|
||||
|
@ -29,7 +29,6 @@
|
||||
import org.bukkit.event.player.*;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import com.sk89q.worldedit.Vector;
|
||||
import com.sk89q.worldguard.*;
|
||||
import com.sk89q.worldguard.blacklist.events.ItemUseBlacklistEvent;
|
||||
import com.sk89q.worldguard.protection.regions.AreaFlags;
|
||||
import static com.sk89q.worldguard.bukkit.BukkitUtil.*;
|
||||
|
@ -22,7 +22,6 @@
|
||||
import com.sk89q.worldguard.protection.regions.ProtectedRegion;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
import com.sk89q.worldedit.Vector;
|
||||
import com.sk89q.worldguard.LocalPlayer;
|
||||
|
@ -19,22 +19,14 @@
|
||||
|
||||
package com.sk89q.worldguard.protection.dbs;
|
||||
|
||||
import com.sk89q.worldguard.protection.dbs.ProtectionDatabase;
|
||||
import com.sk89q.worldguard.protection.dbs.JSONContainer;
|
||||
import com.sk89q.worldguard.protection.regionmanager.RegionManager;
|
||||
import com.google.gson.Gson;
|
||||
import com.google.gson.reflect.TypeToken;
|
||||
import com.sk89q.worldedit.BlockVector;
|
||||
import com.sk89q.worldguard.protection.regions.ProtectedRegion;
|
||||
import java.io.BufferedInputStream;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.FileReader;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.lang.String;
|
||||
import java.lang.reflect.Type;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
|
@ -23,7 +23,6 @@
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.SortedMap;
|
||||
import java.util.TreeMap;
|
||||
import com.sk89q.worldedit.Vector;
|
||||
import com.sk89q.worldguard.LocalPlayer;
|
||||
@ -32,9 +31,7 @@
|
||||
import com.sk89q.worldguard.protection.regions.ProtectedRegion;
|
||||
import com.sk89q.worldguard.protection.UnsupportedIntersectionException;
|
||||
import com.sk89q.worldguard.protection.dbs.ProtectionDatabase;
|
||||
import java.io.FileNotFoundException;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
|
||||
/**
|
||||
* A very simple implementation of the region manager that uses a flat list
|
||||
|
@ -20,7 +20,6 @@
|
||||
package com.sk89q.worldguard.protection.regionmanager;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.TreeMap;
|
||||
@ -35,7 +34,6 @@
|
||||
import com.sk89q.worldguard.protection.UnsupportedIntersectionException;
|
||||
import com.sk89q.worldguard.protection.dbs.ProtectionDatabase;
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
|
||||
public class PRTreeRegionManager extends RegionManager {
|
||||
private static final int BRANCH_FACTOR = 30;
|
||||
|
@ -29,7 +29,6 @@
|
||||
import com.sk89q.worldguard.protection.regions.ProtectedRegion;
|
||||
import java.io.FileNotFoundException;
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
/**
|
||||
|
@ -126,6 +126,12 @@ private Map<String, String> getFlagData(String name)
|
||||
return ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the State value of a state flag
|
||||
*
|
||||
* @param flag
|
||||
* @return State
|
||||
*/
|
||||
public State get(String flag) {
|
||||
State state = State.valueOf(getFlagData("states").get(flag));
|
||||
if (state == null) {
|
||||
@ -133,7 +139,13 @@ public State get(String flag) {
|
||||
}
|
||||
return state;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Sets the State value of a state flag
|
||||
*
|
||||
* @param flag
|
||||
* @param state
|
||||
*/
|
||||
public void set(String flag, State state) {
|
||||
if (state == State.NONE) {
|
||||
getFlagData("states").remove(flag);
|
||||
|
@ -23,7 +23,7 @@
|
||||
import com.sk89q.worldedit.BlockVector;
|
||||
import com.sk89q.worldedit.BlockVector2D;
|
||||
import com.sk89q.worldedit.Vector;
|
||||
import com.sk89q.worldedit.Vector2D;
|
||||
|
||||
|
||||
public class ProtectedPolygonalRegion extends ProtectedRegion {
|
||||
protected List<BlockVector2D> points;
|
||||
|
@ -19,7 +19,6 @@
|
||||
|
||||
package com.sk89q.worldguard.protection.regions;
|
||||
|
||||
import com.sk89q.worldguard.protection.regions.ProtectedRegion;
|
||||
import org.khelekore.prtree.MBRConverter;
|
||||
|
||||
public class ProtectedRegionMBRConverter implements MBRConverter<ProtectedRegion> {
|
||||
|
Loading…
Reference in New Issue
Block a user