Ejemplo n.º 1
0
	public void setGeoLocation(String geolocation)
	{
		if (geolocation == null || geolocation.isEmpty())
		{
			this.geolocation = null;
			config.removeProperty("geolocation");
		}
		else
		{
			this.geolocation = geolocation;
			config.setProperty("geolocation", geolocation);
		}
		config.save();
	}
Ejemplo n.º 2
0
	public void setIgnoredPlayers(List<String> players)
	{
		if (players == null || players.isEmpty())
		{
			ignoredPlayers = Collections.synchronizedList(new ArrayList<String>());
			config.removeProperty("ignore");
		}
		else
		{
			ignoredPlayers = players;
			config.setProperty("ignore", players);
		}
		config.save();
	}
Ejemplo n.º 3
0
	public void setJail(String jail)
	{
		if (jail == null || jail.isEmpty())
		{
			this.jail = null;
			config.removeProperty("jail");
		}
		else
		{
			this.jail = jail;
			config.setProperty("jail", jail);
		}
		config.save();
	}
Ejemplo n.º 4
0
	public void setMails(List<String> mails)
	{
		if (mails == null)
		{
			config.removeProperty("mail");
			mails = _getMails();
		}
		else
		{
			config.setProperty("mail", mails);
		}
		this.mails = mails;
		config.save();
	}
Ejemplo n.º 5
0
	public void delHome(String name) throws Exception
	{
		String search = getHomeName(name);
		if (!homes.containsKey(search))
		{
			search = StringUtil.safeString(search);
		}
		if (homes.containsKey(search))
		{
			homes.remove(search);
			config.removeProperty("homes." + search);
			config.save();
		}
		else
		{
			throw new Exception(_("invalidHome", search));
		}
	}