Difference for server/player.c from version 1.157 to 1.158


version 1.157 version 1.158
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_player_c =   * static char *rcsid_player_c =
  *   "$Id: player.c,v 1.157 2005/02/20 20:43:16 akirschbaum Exp $";   *   "$Id: player.c,v 1.158 2005/03/13 15:13:12 ryo_saeba Exp $";
  */   */
   
 /*  /*
Line 1233
 
Line 1233
  if (tmp->type == BOOK || tmp->type == SCROLL)    if (tmp->type == BOOK || tmp->type == SCROLL)
  { pick_up(op, tmp); if(0)fprintf(stderr,"READABLES\n"); continue; }   { pick_up(op, tmp); if(0)fprintf(stderr,"READABLES\n"); continue; }
   
       /* wands/staves/rods/horns */
       if (op->contr->mode & PU_MAGIC_DEVICE)
    if (tmp->type == WAND || tmp->type == ROD || tmp->type == HORN)
    { pick_up(op, tmp); if(0)fprintf(stderr,"MAGIC_DEVICE\n"); continue; }
   
       /* pick up all magical items */        /* pick up all magical items */
       if(op->contr->mode & PU_MAGICAL)        if(op->contr->mode & PU_MAGICAL)
Line 2285
 
Line 2289
       gen_sp = gen_sp * 10 / (op->contr->gen_sp_armour < 10? 10 : op->contr->gen_sp_armour);        gen_sp = gen_sp * 10 / (op->contr->gen_sp_armour < 10? 10 : op->contr->gen_sp_armour);
       if(op->stats.sp<op->stats.maxsp) {        if(op->stats.sp<op->stats.maxsp) {
  op->stats.sp++;   op->stats.sp++;
    /* dms do not consume food */
    if (!QUERY_FLAG(op,FLAG_WIZ)) {
  op->stats.food--;   op->stats.food--;
  if(op->contr->digestion<0)   if(op->contr->digestion<0)
    op->stats.food+=op->contr->digestion;     op->stats.food+=op->contr->digestion;
Line 2292
 
Line 2298
  random_roll(0, op->contr->digestion, op, PREFER_HIGH))   random_roll(0, op->contr->digestion, op, PREFER_HIGH))
    op->stats.food=last_food;     op->stats.food=last_food;
       }        }
         }
       if (max_sp>1) {        if (max_sp>1) {
  over_sp = (gen_sp+10)/rate_sp;   over_sp = (gen_sp+10)/rate_sp;
  if (over_sp > 0) {   if (over_sp > 0) {
Line 2335
 
Line 2342
     if(--op->last_heal<0) {      if(--op->last_heal<0) {
       if(op->stats.hp<op->stats.maxhp) {        if(op->stats.hp<op->stats.maxhp) {
  op->stats.hp++;   op->stats.hp++;
    /* dms do not consume food */
    if (!QUERY_FLAG(op,FLAG_WIZ)) {
  op->stats.food--;   op->stats.food--;
  if(op->contr->digestion<0)   if(op->contr->digestion<0)
    op->stats.food+=op->contr->digestion;     op->stats.food+=op->contr->digestion;
Line 2342
 
Line 2351
  random_roll(0, op->contr->digestion, op, PREFER_HIGH))   random_roll(0, op->contr->digestion, op, PREFER_HIGH))
    op->stats.food=last_food;     op->stats.food=last_food;
       }        }
         }
       if(max_hp>1) {        if(max_hp>1) {
  over_hp = (gen_hp<20 ? 30 : gen_hp+10)/rate_hp;   over_hp = (gen_hp<20 ? 30 : gen_hp+10)/rate_hp;
  if (over_hp > 0) {   if (over_hp > 0) {
Line 2364
 
Line 2374
  op->last_eat=25*(1+bonus)/(op->contr->gen_hp+penalty+1);   op->last_eat=25*(1+bonus)/(op->contr->gen_hp+penalty+1);
       else        else
  op->last_eat=25*(1+bonus)/(penalty +1);   op->last_eat=25*(1+bonus)/(penalty +1);
       op->stats.food--;      /* dms do not consume food */
       if (!QUERY_FLAG(op,FLAG_WIZ)) op->stats.food--;
     }      }
   }    }
   


Legend:
line(s) removed in v.1.157 
line(s) changed
 line(s) added in v.1.158

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