public void setTarget(Spatial target) {
        this.target = target;
        
        if(target != null) {
            Vector3f targetPosition = target.getWorldTranslation();
            Vector3f cameraLoctaion = new Vector3f(targetPosition.x, targetPosition.y + 20, targetPosition.z + 20);
            cam.setLocation(cameraLoctaion);
            
            cam.lookAt(targetPosition, Vector3f.UNIT_Y);
        }
    }