private void update() {
		checkPause();
		if (this.hasFocus() && g.state == 1 && !pause) {
			tick++;
			if (tick % 60 == 0) g.time++;
			updateControls();
			if (tick % ySpeed == 0) {
				sound.playSound(5);
				yPos++;
				checkCollision();
				initObjCoord();
			}
			if (xSpeed != 0 && tick % xSpeed == 0) {
				checkSideCollision();
			}
		} else {
			if (!hasFocus()) pause = false;
			if (g.state == 1) contr.releaseAll();
		}
	}