I usually try to figure out my problems with coding before I start wasting your time trying to fix what I should be able to debug, but I'm lost here. I'm trying to make a spell called "Ice storm." It's an area-affect spell that casts a "chill touch" spell on all in the room of the caster, plus the rooms that have exits surrounding the caster's room. I am obviously getting into those rooms, but when I try to use the chill touch spell on the victims, it doesn't appear to work at all. Here's the body of my spell: #define CURRENT(ch, direction) world[ch->in_room].dir_option[(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,current_direction)].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_victm); } } } } } 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); } } } Anyone care to tell me why it will work for the room I am in(it does cast the chill touch spell on all in the caster's room) but not in the surrounding ones? ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 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