version 1.30 | | version 1.31 |
---|
| | |
/* | | /* |
* static char *rcsid_spell_util_c = | | * static char *rcsid_spell_util_c = |
* "$Id: spell_util.c,v 1.30 2000/11/18 23:19:31 peterm Exp $"; | | * "$Id: spell_util.c,v 1.31 2000/11/19 07:33:30 peterm Exp $"; |
*/ | | */ |
| | |
/* | | /* |
| | |
case SP_BANISHMENT: | | case SP_BANISHMENT: |
case SP_MANA_BLAST: | | case SP_MANA_BLAST: |
case SP_WINDSTORM: | | case SP_WINDSTORM: |
| | case SP_PEACE: |
| | case SP_SPIDERWEB: |
success = cast_cone(op,caster,dir,duration,type,spellarch[type],!ability); | | success = cast_cone(op,caster,dir,duration,type,spellarch[type],!ability); |
break; | | break; |
case SP_TURN_UNDEAD: | | case SP_TURN_UNDEAD: |
| | |
case SP_FROSTBOLT: | | case SP_FROSTBOLT: |
case SP_S_LIGHTNING: | | case SP_S_LIGHTNING: |
case SP_L_LIGHTNING: | | case SP_L_LIGHTNING: |
| | case SP_FORKED_LIGHTNING: |
case SP_STEAMBOLT: | | case SP_STEAMBOLT: |
case SP_MANA_BOLT: | | case SP_MANA_BOLT: |
success = fire_bolt(op,caster,dir,type,!ability); | | success = fire_bolt(op,caster,dir,type,!ability); |
| | |
case SP_CONFUSION: | | case SP_CONFUSION: |
case SP_XRAY: | | case SP_XRAY: |
case SP_DARK_VISION: | | case SP_DARK_VISION: |
| | case SP_RAGE: |
success = cast_change_attr(op,caster,dir,type); | | success = cast_change_attr(op,caster,dir,type); |
break; | | break; |
case SP_RESTORATION: | | case SP_RESTORATION: |
| | |
} | | } |
} | | } |
| | |
| | /* drops an object based on what is in the cone's "other_arch" */ |
| | void cone_drop(object *op) { |
| | object *new_ob = arch_to_object(op->other_arch); |
| | new_ob->x = op->x; |
| | new_ob->y = op->y; |
| | new_ob->stats.food = op->stats.hp; |
| | new_ob->level = op->level; |
| | set_owner(new_ob,op->owner); |
| | if(op->chosen_skill) { |
| | new_ob->chosen_skill=op->chosen_skill; |
| | new_ob->exp_obj = op->chosen_skill->exp_obj; |
| | } |
| | insert_ob_in_map(new_ob,op->map,op); |
| | |
| | } |
| | |
| | |
void move_cone(object *op) { | | void move_cone(object *op) { |
int i; | | int i; |
tag_t tag; | | tag_t tag; |
| | |
tmp->stats.dam = op->stats.dam; | | tmp->stats.dam = op->stats.dam; |
tmp->attacktype=op->attacktype; | | tmp->attacktype=op->attacktype; |
insert_ob_in_map(tmp,op->map,op); | | insert_ob_in_map(tmp,op->map,op); |
| | if(tmp->other_arch) { cone_drop(tmp);} |
} | | } |
} | | } |
} | | } |