@Override
	public void update(long delta) {
		
		double timeFactor = (delta) / Main.targetFrameDuration;
		System.out.println(timeFactor);
		// SPACE DOWN
		if (Input.keyDown(32)) {
			spaceDown = true;
			progressSpeed += 0.05 * timeFactor;
		} else {
			if (spaceDown && releaseListener != null) {
				releaseListener.jump(progress);
			}
			spaceDown = false;
			progressSpeed = 1;
			progress *= Math.pow(0.8, timeFactor);
		}
		
		progress += progressSpeed * timeFactor;
		
		if (progress < 0) progress = 0;
		if (progress > width) progress = width;
	}