@Override
  public void init(GameContainer gc, StateBasedGame sbg) throws SlickException {
    super.init(gc, sbg);
    input = gc.getInput();
    soundJump = new Sound2(Conf.SND_BIP_PATH + "bip6.ogg");
    soundJump2 = new Sound2(Conf.SND_DEPLACEMENT_PATH + "saut.ogg");
    soundBump = new Sound2(Conf.SND_DEPLACEMENT_PATH + "bump.ogg");
    killedEnemySound = new Sound2(Conf.SND_PERSOS_PATH + "hurt_light2.ogg");
    helpSound = new Sound2(Conf.getVoice("jeuf1"));

    font = new AngelCodeFont(Conf.FONTS_PATH + "hiero.fnt", Conf.FONTS_PATH + "hiero.png");
    // We set Open Al constants about physical world
    AL10.alDopplerFactor(1.0f); // Doppler effect
    AL10.alDopplerVelocity(1.0f); // Sound speed
    AL10.alDistanceModel(AL11.AL_EXPONENT_DISTANCE);
    AL10.alDopplerFactor(50.0f);
  }
Exemple #2
0
 public void setDopplerSpeed(float val) {
   AL10.alDopplerVelocity(val);
 }