void setSpeed(int speed) {
        switch (speed) {
        case -2:
            factor = 0;
            break;
        case -1:
            factor = 0.5;
            break;
        case 0:
            factor = 1.2;
            break;
        case 1:
            factor = 2.5;
            break;
        case 2:
            factor = 5.0;
            break;

        }
    }