如何在 andengine 中播放 mp3?
我想在我的条件匹配时播放声音,但我不知道如何在andengine中播放声音或音乐?
帮助我找到我的解决方案。
你的回答将被奖励。
i want to play sound when my condition is matched, but i don't how can i play sound or music in andengine?
help me to find my solution.
your answer will be awarded.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
显然,您也可以在
AndEngine
中使用MediaPlayer
,它可以像在Android
中一样正常工作,因为AndEngine
是也是Android本身的一部分。您可以将文件保存在
res/raw/anyfile.mp3
中You can obviously use the
MediaPlayer
inAndEngine
too, it works fine as it does inAndroid
, becauseAndEngine
is also a part of Android itself.You can keep your file in
res/raw/anyfile.mp3
虽然我还没有执行声音任务,但希望本教程链接对您有所帮助,
though i haven't perform a sound task, but hope this tutorial link will help u,,
http://www.droidnova.com/creating-sound-effects-in-android-part-1,570.html