User Tag List

Page 1 of 2 1 2 LastLast
Results 1 to 7 of 9

Thread: DBC editing - spell creation

  1. #1
    Enthusiast
    Join Date
    May 2013
    Posts
    26
    XP
    2,595
    Level
    14
    Thanks
    8
    Thanked 12 Times in 3 Posts

    DBC editing - spell creation

    I'm not sure what the policy is for dbc editing here, take it down if you don't condone it.
    This has been posted by me over at modcraft and ac web (completely lost on ac web ) but it might server some purpose, so here it goes. I'm working on the rest, honest.

    Get yourself MyDBCEditor (google it...tada) [DON'T FORGET TO TICK THE "ZERO BASED" TICKBOX AT THE BOTTOM OF THE EDITOR OR THE COLUMN IDS WILL NOT BE THE SAME AS IN THIS TUTORIAL]

    Open up Spell.dbc (you're doing so well)

    Tonight we're going to tackle a basic but surprisingly educating problem to solve:

    There are a few things you need to know about spells. More often than you'd think there is more than one spell involved in the casting of a "singular" spell. For instance, Holy Shock, this spell either heals the target if friendly or damages the target if hostile. Now, unfortunately, dbc's don't handle any mechanic this dynamic and therefore it's handled via the core and there are actually two spells (two entries in the dbc) for each rank of holy shock, one that heals and one that deals damage. Right, now say you wanted to edit holy shock for your new fantabulous twink server so you hop along to open-wow and look up Holy Shock (http://wotlk.openwow.com/?spell=20473) and openwow tells you that the id is 20473. Great, now you head on over to column 80 (incidentally I'll teach you what these columns actually mean, just knowing "that's the one that has the same number as the tooltip" is ridiculous, but I digress...) but what's this? it's empty! you check all the other nearby columns in the vague hope that there will be a number that you can change that will do the right thing, but none of them come close to the damage/healing value specified in the tooltip! ah well, I guess your twink realm won't be so fantabulous after all, right? WRONG MOTHERFUCKER! Here's the solution to your problem, but in order to understand it you have to approach it logically. I've already told you, spell such as holy shock have to be handled in the core, but this is the spell you use to cast it, so this spell must tell you something... It does, the tooltip tells you everything, it tells you how much it will heal for on friendly targets and how much it will damage your newly created super custom fun time boss for your amazing twink server. So, now you go in search of the tooltip column in the DBC, which, by the way, is 170 (most of the time) and you see this:

    Quote:Blasts the target with Holy energy, causing $25912s1 Holy damage to an enemy, or $25914s1 healing to an ally.


    Ooooh numbers, let's break this down:

    "$" pretty much means your getting a value from somewhere else in the dbc. What comes after it is what row it's getting that value from, if there is no number after it, that means it's getting the number from it's own row (e.g. $s1)

    "s" stands for the effectbasepoint columns a.k.a 80-82

    "1" doesn't have to be 1, but it stands for which of the effectbasepoint columns it is getting the number from, in this case it's column 80, if it was 2 then it would be column 81 and if it was 3 then it would be column 82.

    With this new found knowledge you can see that the tooltip is pointing to two different rows (two different spells) to return the heal/damage values. For the heal value it's pointing to row 25914, and sure enough, if we go to row 25914 at column 80, there's the value for the minimum heal for holy shock.



    Right ok that's it for tonight, do it yourself with a spell like haunt, see if you can successfully modify both values.

    Part one continued: Columns explained

    I'm going to try and teach columsn with something to relate to. So let us deconstruct a spell.
    Lets take rank 3 fireball (http://wotlk.openwow.com/?spell=145) as it's nice and simple. Ok, so let's look at what fireball does: It takes 2.5 seconds to shoot a projectile (fire-ball... durrr) which deals 53-73 fire damage and then 2 damage over 6 seconds after that.


    Quote:It takes 2.5 seconds


    This is the cast time. Column 28 handles cast time, but it stands for the casting time index, not the time itself. The value here points to a row in another dbc, SpellCastTimes.dbc. With our fireball, the value in column 28 is 19 so we need to go to SpellCastTimes.dbc and look at row 19 to understand further. We're only interested in column one and the row id in spellcasttimes.dbc as it tells us how long the cast time is, at row 19 the value in column 1 is 2500, so this means that it's done in milliseconds (1000 milliseconds in a second). If you wanted to change the cast time of fireball then you would need to change the value in column 28 (spell.dbc) to a different row id from SpellCastTimes.dbc.


    Quote:shoot a projectile (fire-ball...dur)


    This is the visual of the spell. Spell visuals are exceedingly complex so I won't go into too much detail as it would no longer be defined basic. But, column 131 is the spell visual column, to oversimplify, this is what makes the fireball look like a fireball, what makes the explosions on impact and what controlls the casting visual. The path of the fireball through the air is controlled elsewhere, but this will be discussed at another time, it's much more advanced. I suggest, for now, you don't tamper with this, it's unlikely it will turn out well. I promise I'll get round to a comprehensive tutorial on it.


    Quote:deals 53-73 fire damage and then 2 damage over 6 seconds after that.


    This is the fun stuff, but also the most complex. We'll start at the beginning, basic attributes of the spell (columns 4-11 define atributes, these are like limiting factors). The only attribute that fireball has is in column four and it's 0x10000 which means that the spell cannot be cast whilst shapeshifted, simple, this is an attribute that almost every spell has (apart from the obvious exceptions) What the attributes mean can be found here: http://www.pxr.dk/wowdev/wiki/index....dbc/Attributes (mind, this is only for the first attribute column, each one has its own set).

    The spell target type also needs to be defined somewhere, this is defined in column 16. For fireball the value here is zero, which means it can have a singular player/creature target, we'll get on to how this is further refined in a bit.
    Lets move on to the spell effects. Columns 71-73 define the effects of the spell. Fireball has two effects, some instant damage and a periodic damage tick. Column 71 for fireball has the value 2 which stands for SPELL_EFFECT_SCHOOL_DAMAGE ( list can be found here : http://www.pxr.dk/wowdev/wiki/index....ell.dbc/Effect), Column 72 for fireball has the value 6 which stands for SPELL_EFFECT_APPLY AURA.

    Lets deal with the SPELL_EFFECT_SCHOOL_DAMAGE first, this means that damage of a particular school is done to the target. The school of damage is defined at column 225, where the value for fireball is 4, which is the value for the fire school of damage. We then go to columns 80-82, which are the effectbasepoints columns, and it is (sortof) the amount of the effect that is applied, so for fireball the value in column 80 (the first effect therefore the first effectbasepoint column) is 52, which means that 53 points of fire damage will be dealt to the target (0 is counted as 1 here), sorted.

    As for SPELL_EFFECT_APPLY_AURA, well we need to say which aura is applied. So we go to columns 95-97, which are the columns for "effectapplyauraname". We go to column 96, as the effect was defined in the second effect column and therefore the aura defined should be in the second applyaura column. For fireball the value in column 96 is 3, which stands for SPELL_AURA_PERIODIC_DAMAGE (http://www.pxr.dk/wowdev/wiki/index....tApplyAuraName) so this means periodic damage is done. Columns 98-100 handle the effect amplitude, which in this case handles the amount of time between the damage ticks, so if we look at column 99 (second column, again, same reasons as before) we see the value for fireball which is 2000, which means that periodic damage will be dealt every 2 seconds (measured in milliseconds). Now we go to the second effectbasepoints column (81) and see that the value is 1 which means 2 damage will be done every 2 seconds. But the after effect of fireball only lasts 6 seconds so this needs to defined somewhere and it is, in column 40, the durationindex column. This column points to the spellduration.dbc and for fireball has the value 32, which points to row 32 in spellduration.dbc which is 6000 a.k.a 6 seconds in milliseconds.
    Now, to get back to how the target is refined, we already know it has to be a singular player/creature, but columns 86-88 handle what each effect of the spell can, well, affect. With fireball in column 86 and 87 the value is 6, which means that the effects can not be applied to the caster, in other words, the spell cannot be cast on self.


    Ok, I think that's it for the basic explanations of the dbc columns, I hope you enjoyed and I hope it's not too much of a wall of text!

    If you don't like it, tell me to stop and I'll stop, I don't care as long as you don't run around screaming about how inferior I am compared to your immense power etc.
    If you do like it, just say thanks.

    Before you think I'm wrong, bear in mind I've simplified the explanations of some things in order for easy reading.

    I will update this as time progresses.
    Last edited by crumpets; 06-04-2013 at 06:19 PM.
    Achievements:
    1 year registered Member Level X

  2. The Following 9 Users Say Thank You to crumpets For This Useful Post:


  3. #2
    Founder <span style='color: #FF4500'>Tommy</span>'s Avatar
    Join Date
    Apr 2013
    Posts
    7,391
    XP
    3,449,104
    Level
    378
    Thanks
    889
    Thanked 1,855 Times in 1,119 Posts
    I always wondered how to do this! Thanks for the tutorial, greatly appreciated!

  4. #3
    Respected Member <span style='color: #000000'><span class='glow_FFFFFF'>Selik</span></span>'s Avatar
    Join Date
    Apr 2013
    Location
    Tommy's mom.
    Posts
    141
    XP
    4,070
    Level
    18
    Thanks
    26
    Thanked 13 Times in 13 Posts
    Thanks for the tutorial!
    Awards:
    LOL Facepalm! Raffle Winner
    [Nom Entertainment] Click click.

  5. #4
    Enthusiast
    Join Date
    Apr 2014
    Posts
    6
    XP
    1,845
    Level
    11
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Thanks for the tutorial :)
    I got a question: I try to modify the %weapon damage of Chimera Shot and don't know where to do that. I had a look as you pointed out in your tutorial but it did not really help me out.
    It says: 'You deal $s3%' etc. following I had a look at the 82th column where it says -1 ( http://prntscr.com/3mrmnv )
    I am quite new to .dbc edits so I don't really know where to look for the 'weapon damage value' now. Would be nice if you could give me a tip where to have a look if this doesnt work.


    Regards,
    Paland

  6. #5
    Moderator / Eluna Dev <span style='color: #FF0000'><span class='glow_8B0000'>Rochet2</span></span>'s Avatar
    Join Date
    Apr 2013
    Location
    Finland
    Posts
    1,857
    XP
    13,474
    Level
    35
    Thanks
    95
    Thanked 591 Times in 418 Posts
    Quote Originally Posted by Paland View Post
    Thanks for the tutorial :)
    I got a question: I try to modify the %weapon damage of Chimera Shot and don't know where to do that. I had a look as you pointed out in your tutorial but it did not really help me out.
    It says: 'You deal $s3%' etc. following I had a look at the 82th column where it says -1 ( http://prntscr.com/3mrmnv )
    I am quite new to .dbc edits so I don't really know where to look for the 'weapon damage value' now. Would be nice if you could give me a tip where to have a look if this doesnt work.


    Regards,
    Paland
    The guide assumes that ID is at 0 index like here:
    http://www.pxr.dk/wowdev/wiki/index....bc#3.3.5.12340

    Your SS has it at index 1.
    This means that column 82 is actually 81 in the SS.

    The column saying 399 is the one you edit for the damage %, which apparently you have already ,.. since it was 124 at the beginning.

  7. The Following 2 Users Say Thank You to Rochet2 For This Useful Post:


  8. #6
    Enthusiast
    Join Date
    Apr 2014
    Posts
    6
    XP
    1,845
    Level
    11
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Thanks a lot. I will try it out :)

    Edit:
    Works :) - http://prntscr.com/3mtjxj
    And no I did not edit it, I became dev at a server and was confronted with these things, just need to correct them now :P

    Thanks a lot.

    Regards,

    Paland
    Last edited by Paland; 06-01-2014 at 02:30 AM. Reason: Tested and works
    Achievements:
    1 year registered Level X

  9. #7
    Enthusiast
    Join Date
    Apr 2014
    Posts
    6
    XP
    1,845
    Level
    11
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Another thing: I tried to modify Rogues' Envenom spell (57993). In spell discription it says "Finishing move that consumes your Deadly Poison doses on the target and deals instant poison damage. Following the Envenom attack you have an additional $s3% chance to apply Deadly Poison and a $s2% increased frequency of applying Instant Poison for 1 sec plus an additional 1 sec per combo point. One dose is consumed for each combo point:
    1 dose: ${($m1-1)*1+$AP*0.09} damage
    2 doses: ${($m1-1)*2+$AP*0.18} damage
    3 doses: ${($m1-1)*3+$AP*0.27} damage
    4 doses: ${($m1-1)*4+$AP*0.36} damage
    5 doses: ${($m1-1)*5+$AP*0.45} damage"

    I wanted to know where to find the AP* 0.45/0.36 for each dose or how to modify it. Also what does $m1 point at? I don't know how to use the parameter atm, would be nice if somebody could explain that to me :)

    Regards,
    Paland.
    Last edited by Paland; 06-01-2014 at 02:22 AM.
    Achievements:
    1 year registered Level X

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •