@Override
public void retrieveAssets() {
if (voice == null && fileName != null) {
EngineLogger.debug("RETRIEVING VOICE: " + fileName);
voice = EngineAssetManager.getInstance().get(EngineAssetManager.VOICE_DIR + fileName, Music.class);
voice.setOnCompletionListener(new OnCompletionListener() {
@Override
public void onCompletion(Music music) {
if (textManager.getCurrentText() != null)
textManager.getCurrentText().setAutoTime();
}
});
if (voice != null)
voice.setVolume(volume * VOLUME_MULTIPLIER);
if (isPlayingSer) {
voice.play();
if (voice != null) {
voice.setPosition(voicePosSer);
}
isPlayingSer = false;
voicePosSer = 0f;
}
}
}