Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

Playing sound files from Xcode

edited May 2012 in General Posts: 65

Hi. Quick feasibility question. Now I've got my project running from Xcode, would there be any way to start playing an mp3 at the start of a new scene or level? I guess just a way to call out to ObjC from lua and I should be able to figure the rest out. If there's no definite answer yet that's cool I'll get round to exploring it sooner or later and report back! Just haven't found the time lately.



  • SimeonSimeon Admin Mod
    Posts: 5,651

    The ideal way would be to create a C library that links Lua to native code. That way you could use Lua function calls to control the music.

    If you only need one music track then you could simply start it playing in the main app delegate. Though that's not very flexible.

  • Posts: 25

    Would this be something that could be added to codea core? I'd love to add some bits of dialog into my game!

  • SimeonSimeon Admin Mod
    Posts: 5,651

    At some point, I think so. But the API and UI for actually getting sounds onto the iPad would need to be designed.

  • Posts: 25

    Could someone give me an idea of what would be required (what the workflow would be) to pull in an external library into the Xcode project, and control it via lua?

Sign In or Register to comment.