本文整理汇总了Java中com.b3dgs.lionengine.audio.AudioFactory类的典型用法代码示例。如果您正苦于以下问题:Java AudioFactory类的具体用法?Java AudioFactory怎么用?Java AudioFactory使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
AudioFactory类属于com.b3dgs.lionengine.audio包,在下文中一共展示了AudioFactory类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: WeaponSetup
import com.b3dgs.lionengine.audio.AudioFactory; //导入依赖的package包/类
/**
* Create a weapon setup.
*
* @param config The config media.
* @throws LionEngineException If error when opening the media.
*/
public WeaponSetup(Media config)
{
super(config);
if (hasNode(NODE_FIRE))
{
final String sfxFile = getText(NODE_FIRE);
sfxFire = AudioFactory.loadAudio(Medias.create(Constant.FOLDER_SFX,
UtilFile.normalizeExtension(sfxFile,
Sfx.AUDIO_FILE_EXTENSION)));
}
else
{
sfxFire = null;
}
}
示例2: start
import com.b3dgs.lionengine.audio.AudioFactory; //导入依赖的package包/类
@Override
protected void start(Bundle bundle)
{
EngineAndroid.start(Constant.NAME, Constant.VERSION, this);
AudioFactory.addFormat(new AudioVoidFormat("wav", "sc68"));
Loader.start(Config.windowed(Constant.NATIVE), Loading.class);
}
示例3: start
import com.b3dgs.lionengine.audio.AudioFactory; //导入依赖的package包/类
@Override
protected void start(Bundle bundle)
{
EngineAndroid.start(Constant.NAME, Constant.VERSION, this);
AudioFactory.addFormat(new WavFormat(), AdPlugFormat.getFailsafe());
Sfx.setEnabled(true);
Loader.start(Config.windowed(Constant.NATIVE), Loading.class);
}
示例4: main
import com.b3dgs.lionengine.audio.AudioFactory; //导入依赖的package包/类
/**
* Main function.
*
* @param args The arguments.
*/
public static void main(String[] args)
{
EngineAwt.start(Constant.NAME, Constant.VERSION, AppTyrianPc.class);
AudioFactory.addFormat(new WavFormat(), AdPlugFormat.getFailsafe());
Sfx.setEnabled(true);
Loader.start(Config.windowed(Constant.NATIVE.get2x()), Loading.class);
}
示例5: start
import com.b3dgs.lionengine.audio.AudioFactory; //导入依赖的package包/类
@Override
protected void start(Bundle bundle)
{
EngineAndroid.start(Constant.NAME, Constant.VERSION, this);
AudioFactory.addFormat(new AudioVoidFormat("wav", "lds"));
Loader.start(Config.windowed(Constant.NATIVE), Loading.class);
}