Difference for server/c_object.c from version 1.22 to 1.23


version 1.22 version 1.23
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_c_object_c =   * static char *rcsid_c_object_c =
  *   "$Id: c_object.c,v 1.22 2001/05/09 05:16:50 mwedel Exp $";   *   "$Id: c_object.c,v 1.23 2001/05/09 09:39:56 darth_bob Exp $";
  */   */
 /*  /*
     CrossFire, A Multiplayer game for X-windows      CrossFire, A Multiplayer game for X-windows
Line 168
 
Line 168
    }     }
    skillno=lookup_skill_by_name(params);     skillno=lookup_skill_by_name(params);
    if (skillno==-1) {     if (skillno==-1) {
  new_draw_info_format(NDI_UNIQUE,0,pl,"Couldn't find skill %s", params);   new_draw_info_format(NDI_UNIQUE,0,pl,"Couldn't find the skill %s", params);
  return 0;   return 0;
    }     }
    return change_skill(pl,skillno);     return change_skill(pl,skillno);
Line 200
 
Line 200
  player_apply(op,inv,aflag,0);   player_apply(op,inv,aflag,0);
     } else      } else
    new_draw_info_format(NDI_UNIQUE, 0, op,     new_draw_info_format(NDI_UNIQUE, 0, op,
      "Could not find any match to %s.",params);       "Could not find any match to the %s.",params);
   }    }
   return 0;    return 0;
 }  }
Line 219
 
Line 219
     buf[0] = 0;      buf[0] = 0;
   
     if (! QUERY_FLAG (sack, FLAG_APPLIED))      if (! QUERY_FLAG (sack, FLAG_APPLIED))
  sprintf (buf, "%s is not active.", query_name(sack));   sprintf (buf, "The %s is not active.", query_name(sack));
     if (sack == op)      if (sack == op)
  sprintf (buf, "You can't put %s into itself.", query_name(sack));   sprintf (buf, "You can't put the %s into itself.", query_name(sack));
     if (sack->race && (sack->race != op->race || op->type == CONTAINER      if (sack->race && (sack->race != op->race || op->type == CONTAINER
         || (sack->stats.food && sack->stats.food != op->type)))          || (sack->stats.food && sack->stats.food != op->type)))
  sprintf (buf, "You can put only %s into %s.", sack->race,   sprintf (buf, "You can put only %s into the %s.", sack->race,
  query_name(sack));   query_name(sack));
     if (op->type == SPECIAL_KEY && sack->slaying && op->slaying)      if (op->type == SPECIAL_KEY && sack->slaying && op->slaying)
  sprintf (buf, "You don't want put the key into %s.", query_name(sack));   sprintf (buf, "You don't want put the key into %s.", query_name(sack));
     if (sack->weight_limit && sack->carrying + (nrof ? nrof : 1) *       if (sack->weight_limit && sack->carrying + (nrof ? nrof : 1) *
  (op->weight + (op->type==CONTAINER?(op->carrying*op->stats.Str):0))   (op->weight + (op->type==CONTAINER?(op->carrying*op->stats.Str):0))
  * (100 - sack->stats.Str) / 100  > sack->weight_limit)   * (100 - sack->stats.Str) / 100  > sack->weight_limit)
  sprintf (buf, "That won't fit in %s!", query_name(sack));   sprintf (buf, "That won't fit in the %s!", query_name(sack));
     if (buf[0]) {      if (buf[0]) {
  if (pl)   if (pl)
      new_draw_info(NDI_UNIQUE, 0,pl, buf);       new_draw_info(NDI_UNIQUE, 0,pl, buf);
Line 325
 
Line 325
  }   }
     }      }
     if(QUERY_FLAG(tmp, FLAG_UNPAID))      if(QUERY_FLAG(tmp, FLAG_UNPAID))
  (void) sprintf(buf,"%s will cost you %s.", query_name(tmp),   (void) sprintf(buf,"The %s will cost you %s.", query_name(tmp),
  query_cost_string(tmp,pl,F_BUY));   query_cost_string(tmp,pl,F_BUY));
     else      else
  (void) sprintf(buf,"You pick up %s.", query_name(tmp));   (void) sprintf(buf,"You pick up the %s.", query_name(tmp));
     new_draw_info(NDI_UNIQUE, 0,pl,buf);      new_draw_info(NDI_UNIQUE, 0,pl,buf);
   
     tmp = insert_ob_in_ob(tmp, op);      tmp = insert_ob_in_ob(tmp, op);
Line 363
 
Line 363
     if (alt)      if (alt)
     {      {
         if ( ! can_pick (op, alt)) {          if ( ! can_pick (op, alt)) {
             new_draw_info_format (NDI_UNIQUE, 0, op, "You can't pick up a %s.",              new_draw_info_format (NDI_UNIQUE, 0, op, "You can't pick up the %s.",
                                   alt->name);                                    alt->name);
      goto leave;       goto leave;
         }          }
Line 513
 
Line 513
     if (sack==tmp) return; /* Can't put an object in itself */      if (sack==tmp) return; /* Can't put an object in itself */
     if (sack->type != CONTAINER) {      if (sack->type != CONTAINER) {
       new_draw_info_format(NDI_UNIQUE, 0,op,        new_draw_info_format(NDI_UNIQUE, 0,op,
  "%s is not a container.", query_name(sack));   "The %s is not a container.", query_name(sack));
       return;        return;
     }      }
     if (QUERY_FLAG(tmp,FLAG_STARTEQUIP)) {      if (QUERY_FLAG(tmp,FLAG_STARTEQUIP)) {
       new_draw_info_format(NDI_UNIQUE, 0,op,        new_draw_info_format(NDI_UNIQUE, 0,op,
  "You cannot put %s in the container.", query_name(tmp));   "You cannot put the %s in the container.", query_name(tmp));
       return;        return;
     }      }
     if (tmp->type == CONTAINER && tmp->inv) {      if (tmp->type == CONTAINER && tmp->inv) {
Line 570
 
Line 570
     } else      } else
  remove_ob(tmp);   remove_ob(tmp);
   
     sprintf(buf, "You put %s in ", query_name(tmp));      sprintf(buf, "You put the %s in ", query_name(tmp));
     strcat (buf, query_name(sack));      strcat (buf, query_name(sack));
     strcat (buf, ".");      strcat (buf, ".");
     tmp_tag = tmp->count;      tmp_tag = tmp->count;
Line 637
 
Line 637
       remove_ob (tmp);        remove_ob (tmp);
   
     if (QUERY_FLAG (tmp, FLAG_STARTEQUIP)) {      if (QUERY_FLAG (tmp, FLAG_STARTEQUIP)) {
       sprintf(buf,"You drop %s.", query_name(tmp));        sprintf(buf,"You drop the %s.", query_name(tmp));
       new_draw_info(NDI_UNIQUE, 0,op,buf);        new_draw_info(NDI_UNIQUE, 0,op,buf);
       new_draw_info(NDI_UNIQUE, 0,op,"The gods who lent it to you retrieves it.");        new_draw_info(NDI_UNIQUE, 0,op,"The gods who lent it to you retrieves it.");
  esrv_del_item (op->contr, tmp->count);   esrv_del_item (op->contr, tmp->count);
Line 1142
 
Line 1142
   
     if(tmp->value&&!QUERY_FLAG(tmp, FLAG_STARTEQUIP)) {      if(tmp->value&&!QUERY_FLAG(tmp, FLAG_STARTEQUIP)) {
  if(QUERY_FLAG(tmp, FLAG_UNPAID))   if(QUERY_FLAG(tmp, FLAG_UNPAID))
      sprintf(buf,"%s would cost you %s.",       sprintf(buf,"The %s would cost you %s.",
      tmp->nrof>1?"They":"It",query_cost_string(tmp,op,F_BUY));       tmp->nrof>1?"They":"It",query_cost_string(tmp,op,F_BUY));
  else   else
      sprintf(buf,"You would get %s for %s.",       sprintf(buf,"You would get %s for the %s.",
      query_cost_string(tmp,op,F_SELL), tmp->nrof>1?"them":"it");       query_cost_string(tmp,op,F_SELL), tmp->nrof>1?"them":"it");
  new_draw_info(NDI_UNIQUE, 0,op,buf);   new_draw_info(NDI_UNIQUE, 0,op,buf);
     }      }


Legend:
line(s) removed in v.1.22 
line(s) changed
 line(s) added in v.1.23

File made using version 1.98 of cvs2html by leaf at 2011-07-21 17:28