version 1.29 | | version 1.30 |
---|
| | |
/* | | /* |
* static char *rcsid_disease_c = | | * static char *rcsid_disease_c = |
* "$Id: disease.c,v 1.29 2005/08/17 07:44:45 akirschbaum Exp $"; | | * "$Id: disease.c,v 1.30 2005/10/01 18:08:35 ryo_saeba Exp $"; |
*/ | | */ |
/* | | /* |
CrossFire, A Multiplayer game for X-windows | | CrossFire, A Multiplayer game for X-windows |
| | |
| | |
int move_disease(object *disease) { | | int move_disease(object *disease) { |
/* first task is to determine if the disease is inside or outside of someone. | | /* first task is to determine if the disease is inside or outside of someone. |
* If outside, we decrement 'hp' until we're gone. | | * If outside, we decrement 'value' until we're gone. |
*/ | | */ |
| | |
if(disease->env==NULL) { /* we're outside of someone */ | | if(disease->env==NULL) { /* we're outside of someone */ |
disease->value--; | | disease->value--; |
if(disease->value==0) { | | if(disease->value<=0) { |
remove_ob(disease); | | remove_ob(disease); |
free_object(disease); | | free_object(disease); |
return 1; | | return 1; |