Download
(24Kb)
Download
Updated: 01-14-21 07:27 AM
Compatibility:
Shadowlands patch (9.0.2)
Updated:01-14-21 07:27 AM
Created:09-06-12 04:08 PM
Downloads:3,575
Favorites:7
MD5:
Categories:RolePlay, Music Mods, Mounts & Pets

Pet Battle Music

Version: 1.9
by: Choonstertwo [More]

Description
This AddOn simply plays custom music (like Pokemon music) during pet battles. To add tracks, follow the instructions in music.lua.

For copyright reasons I can't distribute any Pokemon music with this AddOn, but if you know of some suitable music with a permissive licence (or in the public domain), just leave a comment on Curse or WoW Interface and I'll see if I can package it with future releases.

CAUTION: The included Populate_Music scripts will completely overwrite your existing music.lua file! Make sure you back up any manual changes you make.

Both the Windows and Unix scripts require the ogginfo program from the vorbis-tools package.

On Windows, download vorbis-tools-win32-bin.7z from here, unpack it and copy ogginfo.exe, libogg.dll and libvorbis.dll into the Interface\AddOns\PetBattleMusic\ogginfo folder.

On Mac OSX, you can install vorbis-tools from Homebrew (you don't need to put ogginfo in the AddOn folder like on Windows). On other Unix-like systems, you can probably install it from your package manager.

The Unix script also requires mp3info, available from Homebrew or your package manager.

Alpha Versions, API and Source Code
For the latest alpha versions, check CurseForge. API documentation for AddOn authors can be found here.

The source code is now available on GitHub.

1.9
  • Bump TOC Interface version to 9.0
  • Fix PopulateMusic_Windows PowerShell script

1.8
  • Bump TOC Interface version to 8.0
  • Add .travis.yml file and TOC properties for the BigWigs packager script
    • https://www.wowinterface.com/forums/showthread.php?t=55801

1.7.1
  • Add missing changelog for 1.7

1.7
  • Update to 7.0

1.6
  • Update Windows scripts to work with Windows 10
    • Thanks to badjujumojo of Curse for the index
  • Update to 6.2

1.5
  • Stop mute timer when starting a new battle before the previous battle's victory/defeat music has finished
    • Fixes music stopping completely and game music being left off in the middle of a battle

1.4
  • Change PopulateMusic_Windows to use ogginfo for Ogg files
  • Update unsupported OS message in Windows scripts

1.3
  • Update to 6.0
    • Replace animation timers with new C_Timer system
  • Add Windows 8.1 support to PopulateMusic_Windows scripts
  • Add pause to end of shell script
  • Replace %d with %.0f in format patterns
    • ogginfo can return non-integer file lengths, which don't work with %d.
  • Stop using -r option to sed
    • -r is a GNU extension, not portable to all platforms
  • Add option to use backslashes in PM_Unix.sh
    • Move then and do to same line as if and for
  • Change PopulateMusic_Windows.js to compare file types instead of file extensions (which are only included in the name when they're shown in Windows explorer).
    • Move file type checks into the isAudioFile function to make the logic easier to change in future.
  • Replace all == with === in PM_Windows.js
  • Add a missing backslash in the main comment of ScriptParts\music_part0.lua and music.lua

1.2
  • Victory/defeat music will now stop playing when you enter a new battle.
  • Updated music.lua with the new instructions.
  • Removed libraries from TOC/.pkgmeta
    • We're using animation objects instead of AceTimer now
  • Added support for Ogg files to the scripts.
  • Replaced README.txt with README.md (for GitHub)
  • Updated TOC Interface number.
  • Added support for separate music tables
    • Most public API functions now take a music table name as their first argument.
    • The script part files are now numbered to support easy construction of music.lua using for loops.
  • Moved settings from core.lua to a new config.lua file.
    • Added a :GetOptionValue() method to the API to get the value of options set in config.lua
  • More documentation changes
  • Changed .docmeta format

1.1
  • Added manual LICENCE.txt output
  • Re-added the .docmeta and .pkgmeta files
  • Added public API, removed debugging code
  • Commented out CVar stuff
Optional Files (0)


Post A Reply Comment Options
Unread 09-12-16, 08:08 AM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
Originally Posted by Estelyen
Originally Posted by Choonstertwo
I can't reproduce this. Are you sure your music.lua file is correct?
I was, but it turned out I was mistaken... Apparently I threw around some mp3s in the folders last time I played WoW and didn't update the music.lua and then forgot about it during my WoW break.

Working now, was completely my error

Keep up the good work, I still totally love this addon!
Thanks, glad to hear it's working.
Report comment to moderator  
Reply With Quote
Unread 09-12-16, 07:04 AM  
Estelyen
A Kobold Labourer

Forum posts: 0
File comments: 37
Uploads: 0
Originally Posted by Choonstertwo
I can't reproduce this. Are you sure your music.lua file is correct?
I was, but it turned out I was mistaken... Apparently I threw around some mp3s in the folders last time I played WoW and didn't update the music.lua and then forgot about it during my WoW break.

Working now, was completely my error

Keep up the good work, I still totally love this addon!
Report comment to moderator  
Reply With Quote
Unread 08-30-16, 10:35 PM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
Originally Posted by Estelyen
So, it's been a while and once again, I've picked WoW up again after a lengthy break

Are you still developing this awesome addon? Because right now, when I enter a pet battle, no music is playing at all for some time. If I wait long enough, eventually one of my tracks will start playing. Maybe a track plays in the background, muted, and the music can only be heard from the second track or something
I can't reproduce this. Are you sure your music.lua file is correct?
Report comment to moderator  
Reply With Quote
Unread 08-30-16, 07:50 PM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
Originally Posted by Estelyen
So, it's been a while and once again, I've picked WoW up again after a lengthy break

Are you still developing this awesome addon? Because right now, when I enter a pet battle, no music is playing at all for some time. If I wait long enough, eventually one of my tracks will start playing. Maybe a track plays in the background, muted, and the music can only be heard from the second track or something
If there's bugs, I'll try to fix them.
Report comment to moderator  
Reply With Quote
Unread 08-30-16, 03:10 PM  
Estelyen
A Kobold Labourer

Forum posts: 0
File comments: 37
Uploads: 0
So, it's been a while and once again, I've picked WoW up again after a lengthy break

Are you still developing this awesome addon? Because right now, when I enter a pet battle, no music is playing at all for some time. If I wait long enough, eventually one of my tracks will start playing. Maybe a track plays in the background, muted, and the music can only be heard from the second track or something
Report comment to moderator  
Reply With Quote
Unread 11-12-14, 04:44 AM  
Estelyen
A Kobold Labourer

Forum posts: 0
File comments: 37
Uploads: 0
Originally Posted by Choonstertwo
I'll do some testing, but in the meantime could you try running a version from GitHub instead of CurseForge so debugging output is enabled?
Demonstration effect ftw... since I downloaded 1.5 and added the GitHub core.lua, the problem seems to have vanished. But it's been random before, so I'm going to keep the debug version for now and I'll give you a holler once I run into the issue again. Thanks a lot anyways!
Report comment to moderator  
Reply With Quote
Unread 11-09-14, 09:11 AM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
Re: 1.5

Originally Posted by Choonstertwo
I've just uploaded version 1.5, which should fix the music stopping in the middle of a battle.

I haven't been able to reproduce the issue with the end animations not playing and AddOns thinking you're still in a pet battle.
I just realised that I uploaded the 1.4 zip as 1.5. The real 1.5 zip has been uploaded now.
Report comment to moderator  
Reply With Quote
Unread 10-31-14, 10:37 AM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
1.5

I've just uploaded version 1.5, which should fix the music stopping in the middle of a battle.

I haven't been able to reproduce the issue with the end animations not playing and AddOns thinking you're still in a pet battle.
Report comment to moderator  
Reply With Quote
Unread 10-31-14, 08:05 AM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
I'll do some testing, but in the meantime could you try running a version from GitHub instead of CurseForge so debugging output is enabled? When things start acting strangely, could you upload the output to Gist and link it here?

You only need to replace core.lua; you don't need to change music.lua, config.lua or your music files.

This will be easier with an AddOn that allows you to copy the contents of your chat frame (e.g. Prat).
Last edited by Choonstertwo : 10-31-14 at 10:45 AM.
Report comment to moderator  
Reply With Quote
Unread 10-31-14, 06:46 AM  
Estelyen
A Kobold Labourer

Forum posts: 0
File comments: 37
Uploads: 0
Nope, still getting the same issue: In about 5-10% of the cases, it won't show the sequence of my pets being healed/getting exp, instead it jumps straight out of the pet battle the moment the last enemy pet dies. The music keeps on playing and some of my other addons won't show up because they seem to think that I'm still in a pet battle. When I start a new pet battle in this situation, it loads a new random track.

Now with 6.0.3 I get another issue as well: Sometimes when I enter a pet battle, the music plays for a few seconds but is then suddenly cut off before I can even enter the first command to my pets. No new music starts up until I finish the battle.

I did some pet battling before I updated your addon to 6.0 and I never saw any of these issues on vanilla

Nevertheless, I still keep using your addon as it's far too awesome for a few glitches to stop me from using it
Report comment to moderator  
Reply With Quote
Unread 10-17-14, 10:06 AM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
Re: Re: Re: Unmute music

Originally Posted by Estelyen
EDIT 2: So, it's been a month now since I reported it... Any luck in finding the issue at all?
It's been quite a bit more than a month now, I apologise as I must have forgotten about this.

Unfortunately I never found any issues; I'm not sure if 6.0 has changed anything for you now, but it may be worth a try.
Report comment to moderator  
Reply With Quote
Unread 03-30-13, 10:07 AM  
Estelyen
A Kobold Labourer

Forum posts: 0
File comments: 37
Uploads: 0
Re: Re: Unmute music

Originally Posted by Choonstertwo
That's quite odd. I'll have to see if I can narrow down the cause of that.
In the meantime I tried setting it the config.lua file to "Master" instead, now it's totally screwed up: Sometimes at the end of a pet battle, my victory music does not play and it doesn't show the sequence of my pets being healed a little and gaining EXP; the game jumps right out of the pet battle the second the last enemy pet dies (my pets DO get healed, gain EXP and level up, it just doesn't show the sequence). My custom pet battle music will keep on playing when that happens and the default background music is muted. I have to log off WoW and log back in to stop the music playing. I set the config.lua back to "SFX" thinking "Master" might just be even more broken, but since then, it keeps happening from time to time even on "SFX". I'm afraid to try out "Ambient" next because it might be screwed up even further

I'm not even sure if it isn't a bug with the pet battles themselves rather than with your addon, because it doesn't even show the usual "after-the-fight-sequence"; it just happened the first time when I set it to "Master".

Anyways, whatever causes these issues, it definitely happens at the end of a pet battle. I'm using BattlePetCount and PetLeash, maybe there's a conflict with one of these?

EDIT: Also, it appears that the problem I posted back in october is still there.
Originally Posted by Estelyen
If I get a dungeon invite while in the middle of a pet battle, the normal background music for the instance will play once and then the game changes back to the Pet Battle Music. Even if I leave the instance, the pet battle music will "butt in" again and again when a normal background music track ends.
Maybe the two are related? In one case the music doesn't stop playing despite the fact that the battle is over, in the other it keeps playing although the fight has been interrupted. I don't know anything about writing WoW Addons, but couldn't you just include a bit of code that checks every few seconds or so if the player is still in a Pet Battle and reverses the music back to normal if it returns false? As a workaround I mean, until you can nail down the true reason and fix it

EDIT 2: So, it's been a month now since I reported it... Any luck in finding the issue at all?
Last edited by Estelyen : 04-30-13 at 01:24 AM.
Report comment to moderator  
Reply With Quote
Unread 03-30-13, 08:40 AM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
Re: Unmute music

Originally Posted by Estelyen
Hi there! I've just picked up pet battling again after having ignored it since patch 5.1 (don't even know why I stopped :P). So I tried the new version of your addon, I really like being able to have different music for different events, good work!
The problem is that most of the time, the addon will leave the default WoW background music muted after a pet battle. I know I could get around that by changing the channel in the config.lua to "music", but I don't want that since it'll cut off my victory music before it's finished with the default background music starting up too early.
That's quite odd. I'll have to see if I can narrow down the cause of that.
Report comment to moderator  
Reply With Quote
Unread 03-26-13, 09:24 AM  
Estelyen
A Kobold Labourer

Forum posts: 0
File comments: 37
Uploads: 0
Unmute music

Hi there! I've just picked up pet battling again after having ignored it since patch 5.1 (don't even know why I stopped :P). So I tried the new version of your addon, I really like being able to have different music for different events, good work!
The problem is that most of the time, the addon will leave the default WoW background music muted after a pet battle. I know I could get around that by changing the channel in the config.lua to "music", but I don't want that since it'll cut off my victory music before it's finished with the default background music starting up too early.
Report comment to moderator  
Reply With Quote
Unread 01-16-13, 02:12 AM  
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view AddOns

Forum posts: 194
File comments: 105
Uploads: 34
1.2

I released version 1.2 to Curse a few days ago, but I forgot to upload it to WoWI until now (because I use Curse's repository/packager system).

Version 1.2 includes separate music for different battle types (e.g. wild, NPC, PvP) and compatibility for Windows 8 in the two Windows scripts.
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: