ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/server/rune.c
(Generate patch)

Comparing deliantra/server/server/rune.c (file contents):
Revision 1.1.1.1 by root, Fri Feb 3 07:14:36 2006 UTC vs.
Revision 1.3 by root, Thu Jun 29 14:26:08 2006 UTC

1/* 1/*
2 * static char *rcsid_rune_c = 2 * static char *rcsid_rune_c =
3 * "$Id: rune.c,v 1.1.1.1 2006/02/03 07:14:36 root Exp $"; 3 * "$Id: rune.c,v 1.3 2006/06/29 14:26:08 root Exp $";
4 */ 4 */
5 5
6/* 6/*
7 CrossFire, A Multiplayer game for X-windows 7 CrossFire, A Multiplayer game for X-windows
8 8
258 trap_show(trap,env); 258 trap_show(trap,env);
259 259
260 /* Only if it is a spell do we proceed here */ 260 /* Only if it is a spell do we proceed here */
261 if ((trap->inv && trap->inv->type == SPELL) || 261 if ((trap->inv && trap->inv->type == SPELL) ||
262 (trap->other_arch && trap->other_arch->clone.type == SPELL)) { 262 (trap->other_arch && trap->other_arch->clone.type == SPELL)) {
263 object *spell; 263
264 /* This is necessary if the trap is inside something else */
265 remove_ob(trap);
266 trap->x=victim->x;
267 trap->y=victim->y;
268 insert_ob_in_map(trap,victim->map,trap,0);
269 if (was_destroyed (trap, trap_tag)) 264 if (was_destroyed (trap, trap_tag))
270 return; 265 return;
271 266
267 // breaks summon golem spells, which, for inexplicable reasons,
268 // do not work like summon golem spells at all but still require
269 // direction "0" to work at all.
270 //if (trap->direction)
271 // rv.direction = trap->direction;
272
272 for(i = 0; i < MAX(1, trap->stats.maxhp); i++) { 273 for(i = 0; i < MAX(1, trap->stats.maxhp); i++) {
273 if (trap->inv) 274 if (trap->inv)
274 cast_spell(trap,trap,trap->direction,trap->inv,NULL); 275 cast_spell(env,trap,trap->direction,trap->inv,NULL);
275 else { 276 else {
276 spell = arch_to_object(trap->other_arch); 277 object *spell = arch_to_object(trap->other_arch);
277 cast_spell(trap,trap,trap->direction,spell,NULL); 278 cast_spell(env,trap,trap->direction,spell,NULL);
278 free_object(spell); 279 free_object(spell);
279 } 280 }
280 } 281 }
281 } else { 282 } else {
282 rune_attack(trap,victim); 283 rune_attack(trap,victim);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines