Difference for server/apply.c from version 1.139 to 1.140


version 1.139 version 1.140
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_apply_c =   * static char *rcsid_apply_c =
  *   "$Id: apply.c,v 1.139 2005/10/01 16:36:35 ryo_saeba Exp $";   *   "$Id: apply.c,v 1.140 2005/10/03 03:29:41 cavesomething Exp $";
  */   */
 /*  /*
     CrossFire, A Multiplayer game for X-windows      CrossFire, A Multiplayer game for X-windows
Line 1190
 
Line 1190
 static int apply_shop_mat (object *shop_mat, object *op)  static int apply_shop_mat (object *shop_mat, object *op)
 {  {
     int rv = 0;      int rv = 0;
       double opinion;
     object *tmp, *next;      object *tmp, *next;
   
     SET_FLAG (op,FLAG_NO_APPLY);   /* prevent loops */      SET_FLAG (op,FLAG_NO_APPLY);   /* prevent loops */
Line 1246
 
Line 1247
  */   */
  else if ( ! rv && (tmp = get_map_ob (op->map, op->x, op->y)) != NULL   else if ( ! rv && (tmp = get_map_ob (op->map, op->x, op->y)) != NULL
     && tmp->type != SHOP_FLOOR) {      && tmp->type != SHOP_FLOOR) {
      new_draw_info (NDI_UNIQUE, 0, op, "Thank you for visiting our shop.");       opinion = shopkeeper_approval(op->map, op);
        if ( opinion > 0.9)
    new_draw_info (NDI_UNIQUE, 0, op, "The shopkeeper gives you a friendly wave.");
        else if ( opinion > 0.75)
    new_draw_info (NDI_UNIQUE, 0, op, "The shopkeeper waves to you.");
        else if ( opinion > 0.5)
    new_draw_info (NDI_UNIQUE, 0, op, "The shopkeeper ignores you.");
        else
    new_draw_info (NDI_UNIQUE, 0, op, "The shopkeeper glares at you with contempt.");
  }   }
     }      }
     else {      else {


Legend:
line(s) removed in v.1.139 
line(s) changed
 line(s) added in v.1.140

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