Re: Damage messages and types (fight.c)

From: Del (caminturn@earthlink.net)
Date: 03/26/99


George Greer wrote:
>
> On Fri, 26 Mar 1999, Del wrote:
>
> >Why have a check if !skill_message and else statement to do the same thing?
>
>   if (!IS_WEAPON(attacktype))
>     skill_message(dam, ch, victim, attacktype);
>   else {
>     if (GET_POS(victim) == POS_DEAD || dam == 0) {
>       if (!skill_message(dam, ch, victim, attacktype))
>         dam_message(dam, ch, victim, attacktype);
>     } else {
>       dam_message(dam, ch, victim, attacktype);
>     }
>   }
>
> They are in different 'if' blocks.
>

Yes, both results still do the same thing which does not make any sense.

This is what it means to me, that is why I am asking:

   if (!IS_WEAPON(attacktype))
     skill_message(dam, ch, victim, attacktype);
   else
    if (GET_POS(victim) == POS_DEAD || dam == 0)
       dam_message(dam, ch, victim, attacktype);


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     |  http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html  |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/15/00 PST