	public void load(File file) {
		FileConfiguration config = new YamlConfiguration();
		try {
			if (file.exists())
				config.load(file);
		} catch (IOException e) {
			e.printStackTrace();
		} catch (InvalidConfigurationException e) {
			e.printStackTrace();
		}
		config.setDefaults(getDefaults());
		colors = config.getBoolean("Chat.Colors");
		bendToItem = config.getBoolean("Bending.Option.Bend-To-Item");
		airdmg = config.getInt("Bending.Damage.AirSwipe");
		enabled = config.getBoolean("Chat.Enabled");
		compatibility = config.getBoolean("Chat.Compatibility");
		waterdmg = config.getInt("Bending.Damage.WaterManipulation");
		earthdmg = config.getInt("Bending.Damage.EarthBlast");
		prefixes.put("Air", config.getString("Chat.Prefix.Air"));
		prefixes.put("Avatar", config.getString("Chat.Prefix.Avatar"));
		prefixes.put("Fire", config.getString("Chat.Prefix.Fire"));
		prefixes.put("Water", config.getString("Chat.Prefix.Water"));
		prefixes.put("Earth", config.getString("Chat.Prefix.Earth"));
		prefixes.put("ChiBlocker", config.getString("Chat.Prefix.ChiBlocker"));
		color.put("Avatar", config.getString("Chat.Color.Avatar"));
		color.put("Air", config.getString("Chat.Color.Air"));
		color.put("Fire", config.getString("Chat.Color.Fire"));
		color.put("Water", config.getString("Chat.Color.Water"));
		color.put("Earth", config.getString("Chat.Color.Earth"));
		color.put("ChiBlocker", config.getString("Chat.Color.ChiBlocker"));
		earthbendable = config.getStringList("Bending.Option.EarthBendable");
		useWeapon
				.put("Air", config.getBoolean(
						"Bending.Option.Bend-With-Weapon.Air", false));
		useWeapon.put("Earth", config.getBoolean(
				"Bending.Option.Bend-With-Weapon.Earth", false));
		useWeapon.put("Fire", config.getBoolean(
				"Bending.Option.Bend-With-Weapon.Fire", false));
		useWeapon.put("Water", config.getBoolean(
				"Bending.Option.Bend-With-Weapon.Water", false));
		useMySQL = config.getBoolean("MySQL.Use-MySQL", false);
		dbHost = config.getString("MySQL.MySQL-host",
				"jdbc:mysql://localhost:3306");
		dbUser = config.getString("MySQL.User", "root");
		dbPass = config.getString("MySQL.Password", "");
		dbDB = config.getString("MySQL.Database", "minecraft");
		Integer dbPortint = (Integer) config.getInt("MySQL.MySQL-portnumber");
		dbPort = dbPortint.toString();
		useWeapon
				.put("ChiBlocker",
						config.getBoolean("Bending.Option.Bend-With-Weapon.ChiBlocker"));
		reverseearthbending = config
				.getBoolean("Bending.Option.Reverse-Earthbending");
		revertchecktime = config
				.getLong("Bending.Option.Reverse-Earthbending-Check-Time");
		chiblockduration = config
				.getLong("Properties.ChiBlocker.ChiBlock-Duration");
		dodgechance = config.getDouble("Properties.ChiBlocker.Dodge-Chance");
		punchmultiplier = config
				.getDouble("Properties.ChiBlocker.Punch-Multiplier");
		falldamagereduction = config
				.getDouble("Properties.ChiBlocker.Fall-Damage-Reduction");
		dissipateAfter = config
				.getLong("Properties.Option.Firebending-Dissipate-Time");
		globalCooldown = config.getLong("Properties.GlobalCooldown");
		airBlastSpeed = config.getDouble("Properties.Air.AirBlast.Speed");
		airBlastRange = config.getDouble("Properties.Air.AirBlast.Range");
		airBlastRadius = config
				.getDouble("Properties.Air.AirBlast.Affecting-Radius");
		airBlastPush = config.getDouble("Properties.Air.AirBlast.Push-Factor");
		airBubbleRadius = config.getInt("Properties.Air.AirBubble.Radius");
		airPassiveFactor = (float) config
				.getDouble("Properties.Air.Passive.Factor");
		airShieldRadius = config.getDouble("Properties.Air.AirShield.Radius");
		airSuctionSpeed = config.getDouble("Properties.Air.AirSuction.Speed");
		airSuctionRange = config.getDouble("Properties.Air.AirSuction.Range");
		airSuctionRadius = config
				.getDouble("Properties.Air.AirSuction.Affecting-Radius");
		airSuctionPush = config
				.getDouble("Properties.Air.AirSuction.Push-Factor");
		airSwipeRange = config.getDouble("Properties.Air.AirSwipe.Range");
		airSwipeArc = config.getInt("Properties.Air.AirSwipe.Arc");
		airSwipeSpeed = config.getDouble("Properties.Air.AirSwipe.Speed");
		airSwipeRadius = config
				.getDouble("Properties.Air.AirSwipe.Affecting-Radius");
		airSwipePush = config.getDouble("Properties.Air.AirSwipe.Push-Factor");
		airSwipeCooldown = config.getLong("Properties.Air.AirSwipe.Cooldown");
		tornadoRadius = config.getDouble("Properties.Air.Tornado.Radius");
		tornadoHeight = config.getDouble("Properties.Air.Tornado.Height");
		tornadoRange = config.getDouble("Properties.Air.Tornado.Range");
		tornadoMobPush = config
				.getDouble("Properties.Air.Tornado.Mob-Push-Factor");
		tornadoPlayerPush = config
				.getDouble("Properties.Air.Tornado.Player-Push-Factor");
		airScooterSpeed = config.getDouble("Properties.Air.AirScooter.Speed");
		catapultLength = config.getInt("Properties.Earth.Catapult.Length");
		catapultSpeed = config.getDouble("Properties.Earth.Catapult.Speed");
		catapultPush = config.getDouble("Properties.Earth.Catapult.Push");
		compactColumnRange = config
				.getDouble("Properties.Earth.CompactColumn.Range");
		compactColumnSpeed = config
				.getDouble("Properties.Earth.CompactColumn.Speed");
		earthBlastRange = config.getDouble("Properties.Earth.EarthBlast.Range");
		earthBlastSpeed = config.getDouble("Properties.Earth.EarthBlast.Speed");
		earthColumnHeight = config
				.getInt("Properties.Earth.EarthColumn.Height");
		earthGrabRange = config.getDouble("Properties.Earth.EarthGrab.Range");
		earthPassive = config
				.getLong("Properties.Earth.EarthPassive.Wait-Before-Reverse-Changes");
		earthTunnelMaxRadius = config
				.getDouble("Properties.Earth.EarthTunnel.Max-Radius");
		earthTunnelRange = config
				.getDouble("Properties.Earth.EarthTunnel.Range");
		earthTunnelRadius = config
				.getDouble("Properties.Earth.EarthTunnel.Radius");
		earthTunnelInterval = config
				.getLong("Properties.Earth.EarthTunnel.Interval");
		earthWallRange = config.getInt("Properties.Earth.EarthWall.Range");
		earthWallHeight = config.getInt("Properties.Earth.EarthWall.Height");
		earthWallWidth = config.getInt("Properties.Earth.EarthWall.Width");
		collapseRange = config.getInt("Properties.Earth.Collapse.Range");
		collapseRadius = config.getDouble("Properties.Earth.Collapse.Radius");
		tremorsenseCooldown = config
				.getLong("Properties.Earth.Tremorsense.Cooldown");
		tremorsenseMaxDepth = config
				.getInt("Properties.Earth.Tremorsense.Max-Depth");
		tremorsenseRadius = config
				.getInt("Properties.Earth.Tremorsense.Radius");
		tremorsenseLightThreshold = (byte) config
				.getInt("Properties.Earth.Tremorsense.Light-Threshold");
		arcOfFireArc = config.getInt("Properties.Fire.ArcOfFire.Arc");
		arcOfFireRange = config.getInt("Properties.Fire.ArcOfFire.Range");
		ringOfFireRange = config.getInt("Properties.Fire.RingOfFire.Range");
		extinguishRange = config.getDouble("Properties.Fire.Extinguish.Range");
		extinguishRadius = config
				.getDouble("Properties.Fire.Extinguish.Radius");
		fireballCooldown = config.getLong("Properties.Fire.Fireball.Cooldown");
		fireballSpeed = config.getDouble("Properties.Fire.Fireball.Speed");
		fireJetSpeed = config.getDouble("Properties.Fire.FireJet.Speed");
		fireJetDuration = config.getLong("Properties.Fire.FireJet.Duration");
		fireJetCooldown = config.getLong("Properties.Fire.FireJet.CoolDown");
		fireStreamSpeed = config.getDouble("Properties.Fire.FireStream.Speed");
		heatMeltRange = config.getInt("Properties.Fire.HeatMelt.Range");
		heatMeltRadius = config.getInt("Properties.Fire.HeatMelt.Radius");
		illuminationRange = config.getInt("Properties.Fire.Illumination.Range");
		dayFactor = config.getDouble("Properties.Fire.Day-Power-Factor");
		freezeMeltRange = config.getInt("Properties.Water.FreezeMelt.Range");
		freezeMeltRadius = config.getInt("Properties.Water.FreezeMelt.Radius");
		healingWatersRadius = config
				.getDouble("Properties.Water.HealingWaters.Radius");
		healingWatersInterval = config
				.getLong("Properties.Water.HealingWaters.Interval");
		plantbendingRange = config
				.getInt("Properties.Water.Plantbending.Range");
		walkOnWaterRadius = config
				.getDouble("Properties.Water.WalkOnWater.Radius");
		waterManipulationRange = config
				.getDouble("Properties.Water.WaterManipulation.Range");
		waterManipulationSpeed = config
				.getDouble("Properties.Water.WaterManipulation.Speed");
		waterSpoutHeight = config.getInt("Properties.Water.WaterSpout.Height");
		waterWallRange = config.getDouble("Properties.Water.WaterWall.Range");
		waterWallRadius = config.getDouble("Properties.Water.WaterWall.Radius");
		waveRadius = config.getDouble("Properties.Water.Wave.Radius");
		waveHorizontalPush = config
				.getDouble("Properties.Water.Wave.Horizontal-Push-Force");
		waveVerticalPush = config
				.getDouble("Properties.Water.Wave.Vertical-Push-Force");
		fastSwimmingFactor = config
				.getDouble("Properties.Water.FastSwimming.Factor");
		nightFactor = config.getDouble("Properties.Water.Night-Power-Factor");
		try {
			config.options().copyDefaults(true);
			config.save(file);
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	public void load(File file) {
		FileConfiguration config = new YamlConfiguration();
		try {
			if (file.exists())
				config.load(file);
		} catch (IOException e) {
			e.printStackTrace();
		} catch (InvalidConfigurationException e) {
			e.printStackTrace();
		}
		config.setDefaults(getDefaults());
		colors = config.getBoolean("Chat.Colors");
		bendToItem = config.getBoolean("Bending.Option.Bend-To-Item");
		airdmg = config.getInt("Bending.Damage.AirSwipe");
		enabled = config.getBoolean("Chat.Enabled");
		compatibility = config.getBoolean("Chat.Compatibility");
		waterdmg = config.getInt("Bending.Damage.WaterManipulation");
		earthdmg = config.getInt("Bending.Damage.EarthBlast");
		prefixes.put("Air", config.getString("Chat.Prefix.Air"));
		prefixes.put("Avatar", config.getString("Chat.Prefix.Avatar"));
		prefixes.put("Fire", config.getString("Chat.Prefix.Fire"));
		prefixes.put("Water", config.getString("Chat.Prefix.Water"));
		prefixes.put("Earth", config.getString("Chat.Prefix.Earth"));
		prefixes.put("ChiBlocker", config.getString("Chat.Prefix.ChiBlocker"));
		color.put("Avatar", config.getString("Chat.Color.Avatar"));
		color.put("Air", config.getString("Chat.Color.Air"));
		color.put("Fire", config.getString("Chat.Color.Fire"));
		color.put("Water", config.getString("Chat.Color.Water"));
		color.put("Earth", config.getString("Chat.Color.Earth"));
		color.put("ChiBlocker", config.getString("Chat.Color.ChiBlocker"));
		earthbendable = config.getStringList("Bending.Option.EarthBendable");
		useWeapon
				.put("Air", config.getBoolean(
						"Bending.Option.Bend-With-Weapon.Air", false));
		useWeapon.put("Earth", config.getBoolean(
				"Bending.Option.Bend-With-Weapon.Earth", false));
		useWeapon.put("Fire", config.getBoolean(
				"Bending.Option.Bend-With-Weapon.Fire", false));
		useWeapon.put("Water", config.getBoolean(
				"Bending.Option.Bend-With-Weapon.Water", false));
		useMySQL = config.getBoolean("MySQL.Use-MySQL", false);
		dbHost = config.getString("MySQL.MySQL-host",
				"jdbc:mysql://localhost:3306");
		dbUser = config.getString("MySQL.User", "root");
		dbPass = config.getString("MySQL.Password", "");
		dbDB = config.getString("MySQL.Database", "minecraft");
		Integer dbPortint = (Integer) config.getInt("MySQL.MySQL-portnumber");
		dbPort = dbPortint.toString();
		useWeapon
				.put("ChiBlocker",
						config.getBoolean("Bending.Option.Bend-With-Weapon.ChiBlocker"));
		reverseearthbending = config
				.getBoolean("Bending.Option.Reverse-Earthbending");
		revertchecktime = config
				.getLong("Bending.Option.Reverse-Earthbending-Check-Time");
		chiblockduration = config
				.getLong("Properties.ChiBlocker.ChiBlock-Duration");
		dodgechance = config.getDouble("Properties.ChiBlocker.Dodge-Chance");
		punchmultiplier = config
				.getDouble("Properties.ChiBlocker.Punch-Multiplier");
		falldamagereduction = config
				.getDouble("Properties.ChiBlocker.Fall-Damage-Reduction");
		dissipateAfter = config
				.getLong("Bending.Option.Firebending-Dissipate-Time");
		globalCooldown = config.getLong("Properties.GlobalCooldown");
		airBlastSpeed = config.getDouble("Properties.Air.AirBlast.Speed");
		airBlastRange = config.getDouble("Properties.Air.AirBlast.Range");
		airBlastRadius = config
				.getDouble("Properties.Air.AirBlast.Affecting-Radius");
		airBlastPush = config.getDouble("Properties.Air.AirBlast.Push-Factor");
		airBubbleRadius = config.getInt("Properties.Air.AirBubble.Radius");
		airPassiveFactor = (float) config
				.getDouble("Properties.Air.Passive.Factor");
		airShieldRadius = config.getDouble("Properties.Air.AirShield.Radius");
		airSuctionSpeed = config.getDouble("Properties.Air.AirSuction.Speed");
		airSuctionRange = config.getDouble("Properties.Air.AirSuction.Range");
		airSuctionRadius = config
				.getDouble("Properties.Air.AirSuction.Affecting-Radius");
		airSuctionPush = config
				.getDouble("Properties.Air.AirSuction.Push-Factor");
		airSwipeRange = config.getDouble("Properties.Air.AirSwipe.Range");
		airSwipeArc = config.getInt("Properties.Air.AirSwipe.Arc");
		airSwipeSpeed = config.getDouble("Properties.Air.AirSwipe.Speed");
		airSwipeRadius = config
				.getDouble("Properties.Air.AirSwipe.Affecting-Radius");
		airSwipePush = config.getDouble("Properties.Air.AirSwipe.Push-Factor");
		airSwipeCooldown = config.getLong("Properties.Air.AirSwipe.Cooldown");
		tornadoRadius = config.getDouble("Properties.Air.Tornado.Radius");
		tornadoHeight = config.getDouble("Properties.Air.Tornado.Height");
		tornadoRange = config.getDouble("Properties.Air.Tornado.Range");
		tornadoMobPush = config
				.getDouble("Properties.Air.Tornado.Mob-Push-Factor");
		tornadoPlayerPush = config
				.getDouble("Properties.Air.Tornado.Player-Push-Factor");
		airScooterSpeed = config.getDouble("Properties.Air.AirScooter.Speed");
		catapultLength = config.getInt("Properties.Earth.Catapult.Length");
		catapultSpeed = config.getDouble("Properties.Earth.Catapult.Speed");
		catapultPush = config.getDouble("Properties.Earth.Catapult.Push");
		compactColumnRange = config
				.getDouble("Properties.Earth.CompactColumn.Range");
		compactColumnSpeed = config
				.getDouble("Properties.Earth.CompactColumn.Speed");
		earthBlastRange = config.getDouble("Properties.Earth.EarthBlast.Range");
		earthBlastSpeed = config.getDouble("Properties.Earth.EarthBlast.Speed");
		earthColumnHeight = config
				.getInt("Properties.Earth.EarthColumn.Height");
		earthGrabRange = config.getDouble("Properties.Earth.EarthGrab.Range");
		earthPassive = config
				.getLong("Properties.Earth.EarthPassive.Wait-Before-Reverse-Changes");
		earthTunnelMaxRadius = config
				.getDouble("Properties.Earth.EarthTunnel.Max-Radius");
		earthTunnelRange = config
				.getDouble("Properties.Earth.EarthTunnel.Range");
		earthTunnelRadius = config
				.getDouble("Properties.Earth.EarthTunnel.Radius");
		earthTunnelInterval = config
				.getLong("Properties.Earth.EarthTunnel.Interval");
		earthWallRange = config.getInt("Properties.Earth.EarthWall.Range");
		earthWallHeight = config.getInt("Properties.Earth.EarthWall.Height");
		earthWallWidth = config.getInt("Properties.Earth.EarthWall.Width");
		collapseRange = config.getInt("Properties.Earth.Collapse.Range");
		collapseRadius = config.getDouble("Properties.Earth.Collapse.Radius");
		tremorsenseCooldown = config
				.getLong("Properties.Earth.Tremorsense.Cooldown");
		tremorsenseMaxDepth = config
				.getInt("Properties.Earth.Tremorsense.Max-Depth");
		tremorsenseRadius = config
				.getInt("Properties.Earth.Tremorsense.Radius");
		tremorsenseLightThreshold = (byte) config
				.getInt("Properties.Earth.Tremorsense.Light-Threshold");
		arcOfFireArc = config.getInt("Properties.Fire.ArcOfFire.Arc");
		arcOfFireRange = config.getInt("Properties.Fire.ArcOfFire.Range");
		ringOfFireRange = config.getInt("Properties.Fire.RingOfFire.Range");
		extinguishRange = config.getDouble("Properties.Fire.Extinguish.Range");
		extinguishRadius = config
				.getDouble("Properties.Fire.Extinguish.Radius");
		fireballCooldown = config.getLong("Properties.Fire.Fireball.Cooldown");
		fireballSpeed = config.getDouble("Properties.Fire.Fireball.Speed");
		fireJetSpeed = config.getDouble("Properties.Fire.FireJet.Speed");
		fireJetDuration = config.getLong("Properties.Fire.FireJet.Duration");
		fireJetCooldown = config.getLong("Properties.Fire.FireJet.CoolDown");
		fireStreamSpeed = config.getDouble("Properties.Fire.FireStream.Speed");
		heatMeltRange = config.getInt("Properties.Fire.HeatMelt.Range");
		heatMeltRadius = config.getInt("Properties.Fire.HeatMelt.Radius");
		illuminationRange = config.getInt("Properties.Fire.Illumination.Range");
		dayFactor = config.getDouble("Properties.Fire.Day-Power-Factor");
		freezeMeltRange = config.getInt("Properties.Water.FreezeMelt.Range");
		freezeMeltRadius = config.getInt("Properties.Water.FreezeMelt.Radius");
		healingWatersRadius = config
				.getDouble("Properties.Water.HealingWaters.Radius");
		healingWatersInterval = config
				.getLong("Properties.Water.HealingWaters.Interval");
		plantbendingRange = config
				.getInt("Properties.Water.Plantbending.Range");
		walkOnWaterRadius = config
				.getDouble("Properties.Water.WalkOnWater.Radius");
		waterManipulationRange = config
				.getDouble("Properties.Water.WaterManipulation.Range");
		waterManipulationSpeed = config
				.getDouble("Properties.Water.WaterManipulation.Speed");
		waterSpoutHeight = config.getInt("Properties.Water.WaterSpout.Height");
		waterWallRange = config.getDouble("Properties.Water.WaterWall.Range");
		waterWallRadius = config.getDouble("Properties.Water.WaterWall.Radius");
		waveRadius = config.getDouble("Properties.Water.Wave.Radius");
		waveHorizontalPush = config
				.getDouble("Properties.Water.Wave.Horizontal-Push-Force");
		waveVerticalPush = config
				.getDouble("Properties.Water.Wave.Vertical-Push-Force");
		fastSwimmingFactor = config
				.getDouble("Properties.Water.FastSwimming.Factor");
		nightFactor = config.getDouble("Properties.Water.Night-Power-Factor");
		try {
			config.options().copyDefaults(true);
			config.save(file);
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
