Difference for server/monster.c from version 1.50 to 1.51


version 1.50 version 1.51
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_monster_c =   * static char *rcsid_monster_c =
  *    "$Id: monster.c,v 1.50 2002/09/05 05:23:15 mwedel Exp $";   *    "$Id: monster.c,v 1.51 2002/09/06 04:44:46 mwedel Exp $";
  */   */
   
 /*  /*
Line 52
 
Line 52
 /* checks npc->enemy and returns that enemy if still valid,  /* checks npc->enemy and returns that enemy if still valid,
  * NULL otherwise.   * NULL otherwise.
  * this is map tile aware.   * this is map tile aware.
    * If this returns an enemy, the range vector rv should also be
    * set to sane values.
  */   */
 object *check_enemy(object *npc, rv_vector *rv) {  object *check_enemy(object *npc, rv_vector *rv) {
          
Line 221
 
Line 223
         if(!QUERY_FLAG(npc, FLAG_UNAGGRESSIVE) && !QUERY_FLAG(npc, FLAG_FRIENDLY) &&          if(!QUERY_FLAG(npc, FLAG_UNAGGRESSIVE) && !QUERY_FLAG(npc, FLAG_FRIENDLY) &&
             !QUERY_FLAG(npc, FLAG_NEUTRAL))              !QUERY_FLAG(npc, FLAG_NEUTRAL))
         {          {
      tmp = get_nearest_player(npc);       npc->enemy = get_nearest_player(npc);
        if (npc->enemy)
             if(QUERY_FLAG(npc, FLAG_FRIENDLY)&&tmp)   tmp = check_enemy(npc,rv);
         tmp = check_enemy(tmp,rv);  
         }          }
                  
     }      }
Line 235
 
Line 236
 /* Sees if this monster should wake up.  /* Sees if this monster should wake up.
  * Currently, this is only called from move_monster, and   * Currently, this is only called from move_monster, and
  * if enemy is set, then so should be rv.   * if enemy is set, then so should be rv.
    * returns 1 if the monster should wake up, 0 otherwise.
  */   */
   
 int check_wakeup(object *op, object *enemy, rv_vector *rv) {  int check_wakeup(object *op, object *enemy, rv_vector *rv) {


Legend:
line(s) removed in v.1.50 
line(s) changed
 line(s) added in v.1.51

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