Sound when pet dies
View Single Post
04-30-21, 12:36 PM
A Molten Giant
Join Date: Apr 2007
Originally Posted by
Oh nice I didnt saw it, thanks.
My pet was killed by the dummy at Boralus and there was a coin sound.
is a nice sound.
Edit: I changed the sound and deleted f:RegisterUnitEvent("UNIT_PET", "player") because this part plays the sound a second time when I use the Revive Pet ability. Just f:RegisterUnitEvent("UNIT_HEALTH", "pet") is enough.
You are not limited to that soundkit constant table. If you want to explore all of the possible sound IDs, you can browse
and use the number in the URL for the sound page. For example, the "level up" sound is at
. The number in the URL is 888 so you would use PlaySound(888) to play it.
Examples I use for some stuff is PlaySound(23331) which has a few random "engineering doodad" fun sounds. I also use the old major/minor glyph sounds for special events PlaySoundFile(567404)PlaySoundFile(567487) I don't remember which one is which, but played together, they sound great.
Notice how those last two say "PlaySoundFile" instead. Sound IDs, which PlaySound uses, are basically indexes to a scripted table of sounds, some going to single sounds, others going to a group of randomly played sounds. File IDs, however, correlate directly to a file. File IDs are a little more tricky to get if you don't know what you're doing.
is one of the best tools available. That specific link takes you to the main sound table for the game. Searching names or IDs gets you File IDs in the FileDataID columns.
Going back to that engineering doodad ID,
let's search for that
. Now we know that ID plays one of five random sounds.
Lua Wall of Shame
Don't like combat text on frames?
Last edited by Kanegasi : 04-30-21 at
View Public Profile
Send a private message to Kanegasi
Find More Posts by Kanegasi