Weird experiments
#17
BanditAngel,Mar 16 2003, 12:44 PM Wrote:For a normal bow:
Create arrow
Calculate arrow damage as the sum of all available physical damage sources

For a lightning bow:
Create and calculate arrow as above
Create lightning effect and attach it to arrow
Calculate lightning damage as the sum of all available lightning damage sources

For a fire bow:
As lightning but replace "lightning" with "fire"

For a melee weapon:
Create and calculate a physical blow
Check for lightning & fire damage sources on all gear and create and calculate if found

Hopefully that is a nice simple and accurate explanation of how it works, and therefor why Sparking Mail only stacks with lightning bows but still stacks with any melee weapon.
Yeh, that is basically it although technically you don't "attach" damage or effects to the arrow. The damage is calculated as the damage hit something.

Technically there are two arrow missiles, normal one and "elemental" one which is used for the fire and lighting arrow. When it hit, the game will calculate the damage. For the normal one it just do a physical attack. For the elemental arrow, it makes a physical attack, and then depending on if the arrow is a fire or lighting one, spawn the proper attack with that damage type (adding up all sources for that damage type, that is fire or lighting). Thus the fireghting damage is done in its own attack so to speak.

I don't remember (and can't with a quick glance at the code) if it would technically be possible to spawn both a fire or lighting attack for the same arrow. I think it would be possible for a melee attack, but not an arrow, it is either one or the other. I think in Hellfire they either made it possible or removed the ability (or something else with it) since I recall discussing that change with the Hellfire programmers. Unfortunately I don't remember. Still, I think it was for melee attacks only. That is, if you had a sword doing fire damage and you had an armor adding lighting damage. I think it was in part graphics related though. This has nothing to do with the rest of this thread though :)

So in your nice and simply summarey, just change so that "lighting effect" and lightning damage to happen upon hit instead of being attached to the arrow, pretty much as with melee and you are correct even technically :)
There are three types of people in the world. Those who can count and those who can't.
Reply


Messages In This Thread
Weird experiments - by Barsine - 03-07-2003, 11:47 AM
Weird experiments - by Nystul - 03-07-2003, 06:08 PM
Weird experiments - by WildViking - 03-08-2003, 03:39 AM
Weird experiments - by Jarulf - 03-08-2003, 11:19 AM
Weird experiments - by Barsine - 03-11-2003, 10:19 AM
Weird experiments - by NiteFox - 03-11-2003, 10:29 AM
Weird experiments - by Jarulf - 03-11-2003, 08:40 PM
Weird experiments - by Geladrius - 03-14-2003, 08:47 PM
Weird experiments - by the Langolier - 03-14-2003, 09:47 PM
Weird experiments - by Nystul - 03-14-2003, 11:36 PM
Weird experiments - by WildViking - 03-15-2003, 12:55 AM
Weird experiments - by Geladrius - 03-15-2003, 03:27 AM
Weird experiments - by Jarulf - 03-15-2003, 09:39 AM
Weird experiments - by Geladrius - 03-15-2003, 10:38 PM
Weird experiments - by Jarulf - 03-16-2003, 09:42 AM
Weird experiments - by BanditAngel - 03-16-2003, 11:53 AM
Weird experiments - by Jarulf - 03-16-2003, 12:51 PM
Weird experiments - by Geladrius - 03-16-2003, 06:27 PM
Weird experiments - by Baceolus - 02-24-2006, 12:05 AM
Weird experiments - by Yogi_Baar - 02-25-2006, 03:16 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)