void setVolumePercent(float percent){
        if (percent < 0.0 || percent > 1.0)
            throw new IllegalArgumentException(percent+" is not a valid percent-value");
        if (volume_control == null){
            System.err.println("Volume-Control for sounds is not supported");
            return;
        }
        // Set the volume:
        float db = (float) ((Math.log((percent != 0.0) ? percent : 1.0E-14) / Math.log(10.0)) * 20.0);
        volume_control.setValue(db);
        before_mute = db;
    }