[REQUEST] AdPlug music plugin

0 favourites
  • 13 posts
From the Asset Store
Antisuspend Plugin for Construct 3 prevents the runtime from getting suspended.
  • I love the sound of the old OPL chip music in early to mid nineties games, and the best method of emulation these days tends to be AdPlug: http://adplug.sourceforge.net

    I know over at the Adventure Game Studio forums they managed to get AdPlug ported as an addon to their engine: http://www.adventuregamestudio.co.uk/fo ... c=23365.40

    There's also the MAME OPL and Dosbox OPL emulators, but AdPlug is probably the easiest way of doing this. Anybody good with porting code that wants/needs this? <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

  • There's no plugin but you can play mod files with examples here:

  • Thanks, mod files are a lot different to how adlib works. Adlib is basically a 4-operator fm synthesizer that accepts midi-type files, whereas mod-type files, as you'll know, have patterns that trigger small samples packed directly into the file. It would be impossible to emulate precisely the sound adlib using mod files.

  • To me it's just another file format. It looks like it's been ported to javascript here:

    http://www.wothke.ch/AdLibido/

    It likely can be used in a similar manner to the stuff in that other topic.

  • To me it's just another file format. It looks like it's been ported to javascript here:

    http://www.wothke.ch/AdLibido/

    It likely can be used in a similar manner to the stuff in that other topic.

    Precisely, so hopefully if there's enough interest, someone with skills might be able to look into porting it to C2? <img src="{SMILIES_PATH}/icon_e_biggrin.gif" alt=":D" title="Very Happy">

  • Here's another example of OPL emulation: http://opl3.cozendey.com if I had proper programming skills I'd take a look myself, I'd love to hear from anyone else that's interested in having this functionality available in C2.

  • Okay, since a it has already been ported to JavaScript, R0J0hound what is the next step to get this working with construct?

  • The next step would be to make a plugin that runs the js code necessary to start playing sound. The js libraries usually have a working example that you'd mostly copy.

  • So here are the repos for the js version: https://github.com/wothke , as I said I have absolutely no experience in javascript or writing plugins, but I'm interested in how difficult it would be to port this over. R0J0hound what type of library would you suggest might be closest to this?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • The library to use depends on what file format you want to play. Taking that adpug link I posted and tweaking the js it uses a bit results in the attached capx. It uses the same method as my mod player capx'. All it does is play any file you specify. Any other features would require delving deep into the source to: A find if such a feature is possible and B. figuring out how to use it.

  • Wow, thankyou so much for this!! It appears to be working perfectly playing tracks, and I assume you can pass functions to it like stop and paused, since playSong works? This is perfect, I think it could be developed into an amazing, fully-featured OPL-emulator if worked on (like I said, I'd love to if I had any javascript knowledge at all!) especially useful if folks wanted tempo changes or even pitch transposition.

    Thanks for this, I can totally use this in game as it is!

  • thank you very much Mr R0J0hound.

    the script loader is perfect for me , no warnings during page loading.

  • Still works great in Chrome, but in NW.js:

    Javscript Error!
    Uncaught ReferenceError: module is not defined[/code:3gcktvo7]
    
    Any ideas what this means?
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)