version 1.47 | | version 1.48 |
---|
| | |
/* | | /* |
* static char *rcsid_player_c = | | * static char *rcsid_player_c = |
* "$Id: player.c,v 1.47 2001/04/06 19:07:22 michtoen Exp $"; | | * "$Id: player.c,v 1.48 2001/04/08 02:37:26 mwedel Exp $"; |
*/ | | */ |
| | |
/* | | /* |
| | |
{ | | { |
object *bow, *arrow = NULL, *left; | | object *bow, *arrow = NULL, *left; |
tag_t left_tag; | | tag_t left_tag; |
| | |
| | if (!dir) { |
| | new_draw_info(NDI_UNIQUE, 0,op, "You can't shoot yourself!"); |
| | return; |
| | } |
| | |
for(bow=op->inv; bow; bow=bow->below) | | for(bow=op->inv; bow; bow=bow->below) |
if(bow->type==BOW && QUERY_FLAG(bow, FLAG_APPLIED)) | | if(bow->type==BOW && QUERY_FLAG(bow, FLAG_APPLIED)) |
break; | | break; |
| | |
} | | } |
#endif | | #endif |
if( !bow->race ) { | | if( !bow->race ) { |
sprintf (errmsg, "Your %s is broken.", bow->name); | | new_draw_info_format(NDI_UNIQUE, 0,op, "Your %s is broken.", bow->name); |
new_draw_info(NDI_UNIQUE, 0,op, errmsg); | | |
op->contr->count_left=0; | | op->contr->count_left=0; |
return; | | return; |
} | | } |
if ((arrow=find_arrow(op, bow->race)) == NULL) { | | if ((arrow=find_arrow(op, bow->race)) == NULL) { |
sprintf (errmsg, "You have no %s left.", bow->race); | | new_draw_info_format(NDI_UNIQUE, 0,op,"You have no %s left.", bow->race); |
new_draw_info(NDI_UNIQUE, 0,op,errmsg); | | |
op->contr->count_left=0; | | op->contr->count_left=0; |
return; | | return; |
} | | } |