Page 1 of 1

Item destruction by spells

Posted: Fri Jan 23, 2004 3:53 pm
by Ripper
As everyone knows, some spells (like fireball, icestorm, lightning, ...)
destroy items lying on the ground. Recently however (I haven't noticed
this in previous versions), even spells like fear, paralyze, slow, etc. do.

I checked the source and noticed that all (?) spells seem to get
the attacktype 'magic' added to them. Although the item destruction code
includes a check against attacktypes like fear and paralyze and doesn't
(or shouln't) destroy items hit by them, these spells still have the 'magic'
attacktype and thus destroy the items.

Possible solutions:

1. Don't add the attacktype 'magic' to every spell, or
2. Include this attacktype in the item destruction check, but only if spells
like manabolt/ball shouldn't destroy items.

Regards, Ripper

Posted: Fri Jan 23, 2004 7:30 pm
by hoxu
I agree that the "non-damaging" spells should not destroy items. I think this was discussed some time ago but I don't remember the outcome.

Posted: Tue Jan 27, 2004 2:39 am
by Leaf
I wonder how long this "feature" has been around...

It looks like the Partial Resistance (PR) code my have caused this, which was checked in to CVS around Dec-2000

Posted: Wed Jan 28, 2004 8:29 am
by hoxu
I think I noticed it sometime during 2003.