Tabletop-RPG-Music / tabletop-rpg-music

A free and evergrowing collection of Fantasy and Sci Fi tracks for Foundry users. Support me at https://www.patreon.com/tabletoprpgmusic to help me keep writing!
19 stars 8 forks source link

Integrate with Moulinette #2

Closed ghost91- closed 3 years ago

ghost91- commented 3 years ago

Moulinette is a module that can be used to manage all kinds of different assets, including audio. It provides a very convenient interface to access files, drag them onto the scene, and create playlists from audio files. Moulinette provides a very easy way for content modules to integrate with it and it would be great if Tabletop RPG Music could do so.

The documentation about how this integration works can be found here: https://github.com/SvenWerlen/moulinette-core/blob/main/docs/README.md#how-to-index-assets-provided-by-other-modules

However, it is extremely easy, all that would be needed is to include a small JavaScript file in your module:

Hooks.once("ready", async function () {
  if(game.moulinette) {
    game.moulinette.sources.push({ type: "sounds", publisher: "Tabletop RPG Music", pack: "Tabletop RPG Music", source: "data", path: "modules/tabletop-rpg-music/music" })
  }
});

And of course you would need to include this JavaScript file in your module.json.

I really hope you consider adding this as it would be a tremendous help for users of both Moulinette and Tabletop RPG Music. I would also be willing to simply create a Pull Request to add this if it sounds like a good idea to you in general :)

Tabletop-RPG-Music commented 3 years ago

Hey there! I've heard good things about Moulinette, I'd be up for adding this. Feel free to create the pull request.

Tabletop-RPG-Music commented 3 years ago

@ghost91- If you get the chance could you test out whether the Moulinette integration worked? Thanks

ghost91- commented 3 years ago

Sure, will do so!

ghost91- commented 3 years ago

Tested it, it's working great: Bildschirmfoto am 2021-10-05 um 12 27 48

Tabletop-RPG-Music commented 3 years ago

Brilliant! 🙂 Sorry it took me so long!


From: Johannes Loher @.> Sent: 05 October 2021 11:28 To: Tabletop-RPG-Music/tabletop-rpg-music @.> Cc: Tabletop RPG Music @.>; State change @.> Subject: Re: [Tabletop-RPG-Music/tabletop-rpg-music] Integrate with Moulinette (#2)

Tested it, it's working great: [Bildschirmfoto am 2021-10-05 um 12 27 48]https://user-images.githubusercontent.com/236845/136006389-422a5069-0f28-4144-9d01-70c2e33f84ed.png

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://github.com/Tabletop-RPG-Music/tabletop-rpg-music/issues/2#issuecomment-934279517, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AD342KPXJ2PPZQBRPIEDVX3UFLHOXANCNFSM5AOMLEJA. Triage notifications on the go with GitHub Mobile for iOShttps://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Androidhttps://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.