public void update(){
        if(isOpening){
            double time = (double)Time.getTime() /(double)Time.SECOND;
            if(time < openTime){
                float lerpFactor = (float)((time - openingStartTime) / TIME_TO_OPEN);
                getTransform().setTranslation(vectorLerp(closePosition, openPosition, lerpFactor));
            }else if(time < closingStartTime){
                getTransform().setTranslation(openPosition);
            }else if(time < closeTime){
                getTransform().setTranslation(vectorLerp(openPosition, closePosition, (float)((time - closingStartTime) / TIME_TO_OPEN)));
            }else{
                getTransform().setTranslation(closePosition);
                isOpening = false;
            }
        }
    }