This is a read only copy without any forum functionality of the old Modcraft forum.
If there is anything that you would like to have removed, message me on Discord via Kaev#5208.
Big thanks to Alastor for making this copy!

Menu

Author Topic: [QUESTION] How to make a spell play a sound (Only function)  (Read 4837 times)

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
[QUESTION] How to make a spell play a sound (Only function)
« on: February 17, 2012, 10:17:05 pm »
1) Pretty self-explanatory. All I want is to be able to create a spell whose sole function is to play a soundfile uncut regardless of any interruptions and whatnot.

What I've done so far was to edit the SpellVisual.dbc, SoundEtnries.dbc and Spell.dbc to make this happen. However upon launching WoW it gave me an error which indicated that SoundEntries.dbc lacked a column (was 29 columns there, however the game expected there to be a total of 30 columns).

I have spotted which column corresponds to the spell visual (already knew) in the Spell.dbc, changed it to the ID of the spell visual that I have created. And I've figured out which column sets the sound effect for the spell visual and changed it to the Id of the entry that I've created in SoundEntries.dbc.

The spell has no global or normal cooldown, has no attributes and no mechs. It only has an effect, a visual, an icon and a name. The visual is also plain simple. No visual effects - ironically - yet just a sound effect.


2) If this does not work I'll resort to lua and create something resembling an addon to do accomplish what I need. However then I'll need to figure out how to make the said sound get heard by anyone within range.


If anyone could help me with either of those, I'd totally appreciate it.

Best Regards,
Can (Ulec)
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Steff

  • Administrator
  • Creator of Worlds
  • *****
  • Posts: 4551
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #1 on: February 18, 2012, 07:30:05 am »
Have a look at point 4

viewtopic.php?f=26&t=98
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Please mark as solved if solved.
Don't ask if you could ask a question... JUST ask the Question.
You can send me also offline messages. I will answer if I get online.
Skype: project.modcraft
Discord: steff#6954

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #2 on: February 18, 2012, 09:11:42 am »
I don't get how that is relevant to my issue. I extracted data from locale-enUs.MPQ alone. I mean I've done it countless times before, I'm sure that is not the issue.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #3 on: February 18, 2012, 09:25:57 am »
I get it now. The issue was most possible regarding the 7th point there. Will let you know whether it's working or not.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #4 on: February 18, 2012, 11:44:22 am »
I figured out the issue but now I can't get the sound to work.

I'm sure that my SoundEntries.dbc and Spell.dbc entries are alright. However I have no clue regarding the flags or columns of the SpellVisual.dbc other than the columns 12 and 13 (11 and 12 for me while viewing on Taliis or another DBC editor)

I set the value at column 12 to 1 to enable the 'missile sound' and enter the sound entry ID to the 13rd column. However it doesn't paly anything.

I've tested the sound in-game by playing it through a script. The sound file is working fine. I think I'm just having a problem with the SpellVisual.dbc. Would appreciate any help.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Laniax

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 62
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #5 on: February 18, 2012, 12:53:37 pm »
If i were in your situation, i'd copy an exisiting spell, which wouldn't need a target and doesn't apply a buff or smth. For example: Blink Visual. Then i'd try to replace it's sound with the custom one. And if that is working ingame i'd try to get rid of the visual.

Although i think its also possible to trigger a sound within the core (so without the use of a spell). But that depends on what you want to achieve.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Current project: AIO Emulation solution.

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #6 on: February 18, 2012, 01:15:21 pm »
I'm familiar with what each column stands for/does within the spell database file,  at least almost all of them so copying an existing spell or creating a new one from scratch doesn't change anything in my case. The spell works anyways. It's the sound effect which is not getting triggered for some reason.

So the spell's functional, sound file's working. My issue persists and it is regarding the SpellVisual.dbc, nothing else from what I can tell.

Also, I want the character to play the said sound file which should be heard by people within range. The default range for spell sounds is what I wanted for it to have anyways so there is no need to fiddle with other stuff to change that. But it must be local.

Also it has to be something 'pressable', you know. Something that I can lay onto my action bars without the need to create a macro for it prior to using it. So there should be no additional effort put into it. Once I manage to get this working it'll be done.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Eatos

  • Registred Member
  • LUA Script Tinker
  • *****
  • Posts: 46
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #7 on: February 19, 2012, 03:45:37 am »
well you can code spell to play a sound :)
Regardless of the core you are using you can make a empty dummy or scripteffect spells that all what will do is trigger sound
like
case spellid:
   p_caster->PlaySoundToSet(soundid);
  break;
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #8 on: February 21, 2012, 11:40:58 am »
So I will have to script it? I don't have the slightest clue about where to place that though. I take it that there won't be any database work regarding this then?
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #9 on: February 21, 2012, 09:22:54 pm »
I've managed to get it work yesterday but it's a tad glitchy when the spell sounds are used. Could you elaborate further on that script?
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Eatos

  • Registred Member
  • LUA Script Tinker
  • *****
  • Posts: 46
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #10 on: February 21, 2012, 11:50:35 pm »
If my first idea didnt help you you could edit effects of spell you have made.Set effect1 to 132
and effect value number of sound id you want to trigger
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #11 on: February 23, 2012, 05:40:31 pm »
Quote from: "Eatos"
If my first idea didnt help you you could edit effects of spell you have made.Set effect1 to 132
and effect value number of sound id you want to trigger

That cuts lots of extra database for me yet it doesn't seem to be working for me.

You're talking about columns 72 and 73 in Spell.dbc, right? I've assigned the value of 132 to the 72nd column, and the SoundEffectID to the 73rd. Yet it doesn't seem to be working. Any idea why?
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Eatos

  • Registred Member
  • LUA Script Tinker
  • *****
  • Posts: 46
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #12 on: February 24, 2012, 03:29:56 pm »
Quote from: "Ulec"
Quote from: "Eatos"
If my first idea didnt help you you could edit effects of spell you have made.Set effect1 to 132
and effect value number of sound id you want to trigger

That cuts lots of extra database for me yet it doesn't seem to be working for me.

You're talking about columns 72 and 73 in Spell.dbc, right? I've assigned the value of 132 to the 72nd column, and the SoundEffectID to the 73rd. Yet it doesn't seem to be working. Any idea why?


No...Wrong Fields are you using.
Ok in Tallis
Column 71- set to 132 (Apply Aura Play Music)
and Column 110 - set it to your soundid ( Effect1 Field )

And there you go :)
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #13 on: February 24, 2012, 06:30:58 pm »
Quote from: "Eatos"
Quote from: "Ulec"
Quote from: "Eatos"
If my first idea didnt help you you could edit effects of spell you have made.Set effect1 to 132
and effect value number of sound id you want to trigger

That cuts lots of extra database for me yet it doesn't seem to be working for me.

You're talking about columns 72 and 73 in Spell.dbc, right? I've assigned the value of 132 to the 72nd column, and the SoundEffectID to the 73rd. Yet it doesn't seem to be working. Any idea why?


No...Wrong Fields are you using.
Ok in Tallis
Column 71- set to 132 (Apply Aura Play Music)
and Column 110 - set it to your soundid ( Effect1 Field )

And there you go :)

Ah, alright. Appreciate it. Going to try it now. That should cut down on my database work heavily.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Ulec

  • Registred Member
  • Polygonshifter
  • *****
  • Posts: 63
    • View Profile
Re: [QUESTION] How to make a spell play a sound (Only function)
« Reply #14 on: February 24, 2012, 07:38:26 pm »
It is not working that way I'm afraid. It does nothing :/

Even none of the original spells within the .dbc with the effect '132' are not doing anything. Perhaps it has to do with my core/emu?
« Last Edit: January 01, 1970, 01:00:00 am by Admin »