package core.entities;

import core.Database;

public class ServerSettings extends Settings{
	
	public ServerSettings(long serverId) {
		super(serverId);
		settingsList = Database.getServerSettings(serverId);
	}
	
	@Override
	public void set(String settingName, String value){
		super.set(settingName, value);
		Database.updateServerSetting(serverId, settingName, value);
	}
	
	public int getDCTimeout(){
		return (int)getSetting("DCTimeout").getValue();
	}
	
	public int getAFKTimeout(){
		return (int)getSetting("AFKTimeout").getValue();
	}
	
	public String getPUGChannel(){
		return (String)getSetting("PUGChannel").getValue();
	}
	
	public int getMinNumberOfGamesToCaptain(){
		return (int)getSetting("minNumberOfGamesToCaptain").getValue();
	}
	
	public int getQueueFinishTimer(){
		return (int)getSetting("queueFinishTimer").getValue();
	}
	
	public boolean postTeamsToPugChannel(){
		return (boolean)getSetting("postPickedTeamsToPugChannel").getValue();
	}
	
	public boolean createDiscordVoiceChannels(){
		return (boolean)getSetting("createDiscordVoiceChannels").getValue();
	}
}

@@ -633,123 +633,8 @@
 %7D%0A%09%0A
-%09public int getMinNumberOfGamesToCaptain()%7B%0A%09%09return (int)getSetting(%22minNumberOfGamesToCaptain%22).getValue();%0A%09%7D%0A%09%0A
 %09pub

Remove artifiact of old settings