we'll try this again...ice storm

CAVNESS@utxvms.cc.utexas.edu
Date: 04/23/94


Hi again, it's me. :)

I'm wanting to have a spell that not only affects those in your room, but
also affects those in the rooms directly surrounding you as evidenced by the 
rooms linked by exits.

The spell is as follows:

#define CURRENT(ch) world[(ch)->in_room].dir_option[current_direction]->to_room


ASPELL(spell_ice_storm)
{
   int  dam,current_direction;
   struct char_data *tmp_victim, *temp;

  assert(ch);


  send_to_char("You summon an ice storm into your area!\n\r", ch);

 for (current_direction=0;current_direction<6;current_direction++)
 {
  if (!world[ch->in_room].dir_option[current_direction])
     {
        spell_ice_blast(GET_LEVEL(ch),ch, victim,0);
        return;
      }
  else
 {
     if (EXIT(ch, current_direction)->to_room!=NOWHERE)
      {

      for (tmp_victim = world[CURRENT(ch)].people; tmp_victim; tmp_victim = temp) 
        {
         temp = tmp_victim->next;
         if ( (ch->in_room == tmp_victim->in_room) && (ch != tmp_victim) ) 
         {
           spell_chill_touch(GET_LEVEL(ch), ch, tmp_victim, 0); 
           if (world[ch->in_room].zone==world[tmp_victim->in_room].zone)
               send_to_char("The room is filled with ice shards!\n\r", tmp_vict
m);  /* er, that's tmp_victim */
         }
       }
      }
    }
  }

  for (tmp_victim = character_list; tmp_victim; tmp_victim = temp) 
   {
      temp = tmp_victim->next;
     if ( (ch->in_room == tmp_victim->in_room) && (ch != tmp_victim) ) 
     {
          spell_chill_touch(GET_LEVEL(ch), ch, tmp_victim, 0); 
       
         if (world[ch->in_room].zone == world[tmp_victim->in_room].zone)
         send_to_char("The room is filled with ice shards!\n\r", tmp_victim);
        }

    }
 }



The ice blast spell is an area-affect spell that does a chill-touch on every
player in the room.

The problem is, Ice storm is acting the exact same as ice blast...can anyone
see my glaring error?

thanks. :)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cavness@utxvms.cc.utexas.edu        |       The Great Holy Star Goat
Kenneth G. Cavness                  |          is with all of us,
"Supreme Diva"                      |         braised be Its name.
"I'm pro-choice--please don't       |
shoot me in the back."              |     Braise the name of Our Lard!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                    



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