|
From: <cro...@li...> - 2003-03-21 08:01:21
|
Module Name: crossfire
Committed By: mwedel
Date: Fri Mar 21 08:01:14 UTC 2003
Modified Files:
crossfire: ChangeLog
crossfire/server: spell_effect.c spell_util.c
Log Message:
server/spell_effect.c: Some code cleanuip to cast_change_attr - mostly
to combine the processing of the stat improving spells together.
The actual change to playability is that bless and holy possession
don't stack if cast multiple times.
server/spell_util.c: Modify create_aura so that player can't have more than
one aura (of the same type) active at a time.
MSW 2003-03-20
The following files had too many changes to show the context diffs here:
cvs rdiff -r1.103 -r1.104 crossfire/server/spell_effect.c
Start of context diffs
Index: crossfire/ChangeLog
diff -c crossfire/ChangeLog:1.57 crossfire/ChangeLog:1.58
*** crossfire/ChangeLog:1.57 Wed Mar 19 23:57:57 2003
--- crossfire/ChangeLog Fri Mar 21 00:01:03 2003
***************
*** 17,22 ****
--- 17,30 ----
------------------------------------------------------------------------------
Changes for CVS:
+ server/spell_effect.c: Some code cleanuip to cast_change_attr - mostly
+ to combine the processing of the stat improving spells together.
+ The actual change to playability is that bless and holy possession
+ don't stack if cast multiple times.
+ server/spell_util.c: Modify create_aura so that player can't have more than
+ one aura (of the same type) active at a time.
+ MSW 2003-03-20
+
server/apply.c: Change weapon improving code to only use up the number of
potions that it needs, and not all on the ground. Required adding
another arg to eat_item() which is the number of items to consume.
Index: crossfire/server/spell_util.c
diff -c crossfire/server/spell_util.c:1.77 crossfire/server/spell_util.c:1.78
*** crossfire/server/spell_util.c:1.77 Fri Feb 21 23:26:56 2003
--- crossfire/server/spell_util.c Fri Mar 21 00:01:11 2003
***************
*** 1,6 ****
/*
* static char *rcsid_spell_util_c =
! * "$Id: spell_util.c,v 1.77 2003/02/22 07:26:56 mwedel Exp $";
*/
--- 1,6 ----
/*
* static char *rcsid_spell_util_c =
! * "$Id: spell_util.c,v 1.78 2003/03/21 08:01:11 mwedel Exp $";
*/
***************
*** 2318,2337 ****
int create_aura(object *op, object *caster, archetype *aura_arch, int spell_type,
int magic)
{
! object *new_aura = arch_to_object(aura_arch);
! new_aura->stats.food = SP_PARAMETERS[spell_type].bdur +
10* SP_level_strength_adjust(op,caster,spell_type);
! new_aura->stats.dam = SP_PARAMETERS[spell_type].bdam
+SP_level_dam_adjust(op,caster,spell_type);
! set_owner(new_aura,op);
! if(magic) new_aura->attacktype|=AT_MAGIC;
! if(new_aura->owner) {
! new_aura->chosen_skill = op->chosen_skill;
! if(new_aura->chosen_skill) new_aura->exp_obj = op->chosen_skill->exp_obj;
! }
! new_aura->level = SK_level(caster);
! insert_ob_in_ob(new_aura, op);
! return 1;
}
/* look_up_spell_by_name: peterm
--- 2318,2348 ----
int create_aura(object *op, object *caster, archetype *aura_arch, int spell_type,
int magic)
{
! int refresh=0;
! object *new_aura;
!
! new_aura = present_arch_in_ob(aura_arch, op);
! if (new_aura) refresh=1;
! else new_aura = arch_to_object(aura_arch);
!
! new_aura->stats.food = SP_PARAMETERS[spell_type].bdur +
10* SP_level_strength_adjust(op,caster,spell_type);
! new_aura->stats.dam = SP_PARAMETERS[spell_type].bdam
+SP_level_dam_adjust(op,caster,spell_type);
!
! set_owner(new_aura,op);
! if(magic) new_aura->attacktype|=AT_MAGIC;
!
! if(new_aura->owner) {
! new_aura->chosen_skill = op->chosen_skill;
! if(new_aura->chosen_skill) new_aura->exp_obj = op->chosen_skill->exp_obj;
! }
! new_aura->level = SK_level(caster);
! if (refresh)
! new_draw_info(NDI_UNIQUE, 0, op, "You recast the spell while in effect.");
! else
! insert_ob_in_ob(new_aura, op);
! return 1;
}
/* look_up_spell_by_name: peterm
|