Crossfire Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

slay bug..



Hi..

   I'm reporting a bug in attack.c that causes all weapons with
slaying slay everything.. I fixed the bug locally in .6 and thought
you'd have it fixed to .7, but it's still here so here is a bug report..

The bug is easily fixed by replacing

Starting line 492:
    if (hitter->slaying) {
	if (((op->race !=NULL && strstr(op->race, hitter->slaying)) ||
#ifndef MULTIPLE_GODS
	  (strstr(hitter->slaying, undead_name) && QUERY_FLAG(op,FLAG_UNDEAD)) ||
#endif
	  (op->arch && op->arch->name!=NULL && strstr(op->arch->name, hitter->slaying))))
	    does_slay=1;
	    dam*=3;

with 

    if (hitter->slaying) {
	if (((op->race !=NULL && strstr(op->race, hitter->slaying)) ||
#ifndef MULTIPLE_GODS
	  (strstr(hitter->slaying, undead_name) && QUERY_FLAG(op,FLAG_UNDEAD)) ||
#endif
	  (op->arch && op->arch->name!=NULL && strstr(op->arch->name, hitter->slaying)))) {
	    does_slay=1;
	    dam*=3;
        }

notice the extra pair of {}..

						/Alexander Wolgast
                                                 (e5alex@etek.chalmers.se)

Keeper of games (gam@etek.chalmers.se)..