public static Level LoadLevel(File f){
		saveFile = new YAMLFile(true);
		saveFile.Load(f);
		
		Level level = new Level(saveFile.getInt("levelWidht"), saveFile.getInt("levelHeight"), saveFile.getString("levelName"));
		
		Game.get().ppb_x = 800 / level.getWidth();
		Game.get().ppb_y = 800 / level.getHeight();
		
		for(int w = 0; w < level.getWidth(); w++){
			for(int h = 0; h < level.getHeight(); h++){
				level.getBlock(w, h).setType(saveFile.getInt("blocks.x" + w + ".y" + h + ".type"));
				level.getBlock(w, h).setColor(new Color(saveFile.getInt("blocks.x" + w + ".y" + h + ".color")));
			}
		}
		
		for(int i = 0; i<saveFile.getInt("entityAmount"); i++){
			try {
				Entity entity = Game.get().pluginManger.getEntityByClass(saveFile.getString("entitys." + i + ".class"));
				if(saveFile.getString("entitys." + i + ".data") == null){
					entity.Create(saveFile.getInt("entitys." + i + ".x"), saveFile.getInt("entitys." + i + ".y"), "");
				}else{
					entity.Create(saveFile.getInt("entitys." + i + ".x"), saveFile.getInt("entitys." + i + ".y"), saveFile.getString("entitys." + i + ".data"));
				}
				level.getEntitys().add(entity);
			} catch (Exception e) {
				e.printStackTrace();
			}
			
		}
		
		int r, g, b;
		r = saveFile.getInt("backgroundColor.red");
		g = saveFile.getInt("backgroundColor.green");
		b = saveFile.getInt("backgroundColor.blue");
		level.setBackgroundColor(new Color(r,g,b));
		
		r = saveFile.getInt("standardBlockColor.red");
		g = saveFile.getInt("standardBlockColor.green");
		b = saveFile.getInt("standardBlockColor.blue");
		level.setStandardBlockColor(new Color(r,g,b));
		
		Spawn s = new Spawn();
		s.Create(saveFile.getInt("spawn.x"), saveFile.getInt("spawn.y"), "");
		level.setSpawn(s);
		
		return level;
	}