Adding ele dmg to minions, poison dagger and more

Post here about all aspects of D2 mod making whether it's information, problems or whatever. Please specify whether your post is relating to Classic D2 or the Expansion.

Moderator: Nizari

Post Reply
cabbage
Posts: 9
Joined: Wed Nov 25, 2020 4:27 am

Adding ele dmg to minions, poison dagger and more

Post by cabbage » Sat Nov 28, 2020 12:46 am

Howdy,
I've been trying a few different things and got stumped, so I'm asking for help:

1. How do I add elemental damage to minions (in particular Spirit Wolves / Ravens)? I see from this post that the srvdofunc (119) doesn't read the ele fields, and from this post that I should add it to the passive fields, but I'm having trouble figuring that part out. Can someone please give me some help on where I should look for the properties that can come here?

2. If the above is correct, then synergies won't work for anything other than physical damage, and I also won't be able to give it a damage progression - is that correct? Are there any other workarounds to give it an elemental damage progression?

3. I've always wanted to do something different with Poison Dagger to enable a melee necro, and thought giving it a Zeal or Rabies behavior would be cool. Altering anything here though, it seems to break things horribly. In particular, I lose the special overriding behavior of Poison Dagger with regard to poison stacking / venom behavior. Are either of those behaviors viable (especially zeal)?

Any help appreciated, thanks!

User avatar
Cypress
Junior Member
Paladin
Posts: 131
Joined: Fri Dec 01, 2017 2:08 am

Re: Adding ele dmg to minions, poison dagger and more

Post by Cypress » Sat Nov 28, 2020 11:28 am

Hello,

(1)
Minions use aurastats/passivestats without needing aurastates/passivestates. Note that entries for aurastats/passivestats should come straight from itemstatcost.txt, and not from properties.txt. So for example, instead of inputting cold-dmg into aurastat1, you would instead put coldmindam/coldmaxdam into aurastat1/aurastat2.

(2)
Aurastatcalc1-6 and passivestatcalc1-5 accept calculations. You can emulate synergy behavior by creating a formula (viewtopic.php?t=24813). So for example, if you want a druid pet to gain +10 maximum cold damage per level, with +5% cold damage per base level in Hurricane, then you'd put in: (10*lvl)*(100+5*skill('hurricane'.blvl))/100. Note that calculations truncate themselves after each step.

Also, if you want their elemental damage to have breakpoints (like how Spirit Wolves gain +6/1/2/4/5/8 max damage per level) then you can use the formula:
A+B*max(min(lvl-1,7),0)+C*max(min(lvl-8,8),0)+D*max(min(lvl-16,6),0)+E*max(min(lvl-22,6),0)+F*max((lvl-28),0)
Where A is min/maxdamage, B is min/maxlevdam2, C is min/maxlevdam3, etc. So for example, if you want Spirit Wolves to gain as much max cold damage as they do physical, then you'd put in:
6+1*max(min(lvl-1,7),0)+2*max(min(lvl-8,8),0)+4*max(min(lvl-16,6),0)+5*max(min(lvl-22,6),0)+8*max((lvl-28),0)

(3)
Could you explain further? What exactly are you losing in comparison to the default functions? From my brief testing, I saw no difference in poison length and bit rate dealt regardless of the srvstfunc/srvdofunc of Poison Dagger. Venom's override stat also appeared to be working the same in either case (only applying to the added poison length, and not to the skill's poison length).

cabbage
Posts: 9
Joined: Wed Nov 25, 2020 4:27 am

Re: Adding ele dmg to minions, poison dagger and more

Post by cabbage » Sun Nov 29, 2020 5:55 am

Holy crap, thanks so much for the detailed answer again, I was reading about the formulae and grokking one out but you saved me a ton of time, much appreciated!

I went through the skills.txt file guide again and searched for more references on aurastats and passivestats, but still don't quite understand the difference between them. For Spirit Wolves, I ran out of space in aurastats (could fit in another 2 for coldmin and max only, because the rest of them are taken for resists), and put the coldlen in passivestat instead. It seems to work and increasing skill levels seem to be making a difference both for damage and cold length. Hopefully once I patch the tbl files it'll be easier to figure out.

For 3 - thanks for saying that, it prompted me to start a fresh go at the file. It turns out I left a srvmissile in there from another experiment and I think that's what was messing everything up.
I ended up changing both server and client functions to the Zeal ones, and just keeping the poison elemental damage seems to work perfectly! (it is super weird to me that it works, I wonder what the server functions for pdagger really do)

Post Reply

Return to “General Mod Making”