public void setType(Type type){
		long now, then, delta;
		then = System.nanoTime();
		
		this.type = type;
		try{
			this.texture = TextureLoader.getTexture("PNG", new FileInputStream(new File(type.location)));
		}catch(FileNotFoundException e){
			e.printStackTrace();
			if(doLog){
				log.writeToLog("CRITICAL ERROR: ");
				e.printStackTrace(log.p);
				log.endLogging();
			}
		}catch(IOException e){
			e.printStackTrace();
			if(doLog){
				log.writeToLog("CRITICAL ERROR: ");
				e.printStackTrace(log.p);
				log.endLogging();
			}
		}
		
		now = System.nanoTime();
		delta = now - then;
		System.out.println(doLog);
		if(doLog)
			this.log.writeToLog("Changing tile types, " + delta + " ns, " + (delta / 1000000) + " ms.");
	}