Death Smurfs

From: Patrick J. Dughi (dughi@IMAXX.NET)
Date: 04/02/98


        As I indicated, writing a spec_proc to do the same thing as the
death smurfs from afore was pretty simple.  This is mailer code, so bear
with me.

        Gee, thanks again for the exploding monkey snippet. It still makes
me giggle.

SPECIAL(death_smurf)
{
  struct char_data *mob,*vict;
  int door, original_location;

  if (cmd || !AWAKE(ch) || !number(0,5))
    return (FALSE);

  if(!number(0,20)) {
    /*then we create a new mob da?*/
    act("$n grimaces and with a sickening squelch, splits in two!",
                FALSE, ch, 0, 0, TO_ROOM);

    mob = read_mobile(GET_MOB_RNUM(ch), REAL);
    char_to_room(mob, ch->in_room);
    return TRUE;
  } else if (!number(0,10)) {
    for (vict = world[ch->in_room].people; vict; vict = vict->next_in_room)
      if (CAN_SEE(vict,ch) && !number(0, 4))
        break;

    if(vict==NULL) {
      act("$n says 'GNAP!' to no one in particular.", 1, ch, 0, 0,
                TO_ROOM);
      return TRUE;
    }
    act("$n says 'GNAP!' and bites $N on their butt!", 1, ch, 0,
                vict, TO_NOTVICT);
    act("$n says 'GNAP!' and bites your tush!", 1, ch, 0,
                vict, TO_VICT);
    GET_MAX_HIT(vict) = GET_MAX_HIT(vict) - 1;
    return TRUE;
  } else {
    for (door = 0; door < NUM_OF_DIRS; door++) {
      if (EXIT(ch, door) && EXIT(ch, door)->to_room != NOWHERE &&
          !IS_SET(EXIT(ch, door)->exit_info, EX_CLOSED)) {
        original_location=ch->in_room;
        char_from_room(ch);
        char_to_room(ch, EXIT(ch,door)->to_room);
        act("From an adjacent room comes the annoying whine of some repetive singing!",
                 1, ch, 0, 0 , TO_ROOM);
        char_from_room(ch);
        char_to_room(ch, original_location);
      }
    }
    act("The $n starts to sing quite loudly!", 1, ch, 0, 0, TO_ROOM);
    act("LA-LA LA-LA-LA-LA LA-LA-LA-LA-LA!",1, ch, 0, 0 , TO_ROOM);
    return TRUE;
  }
  return FALSE;
}

        Right, and extra kudo-points to you if you realize why I threw in
that "gnap" bit. You watch cartoons too much.

                                                        PjD


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



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