Difference for server/apply.c from version 1.68 to 1.69


version 1.68 version 1.69
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_apply_c =   * static char *rcsid_apply_c =
  *   "$Id: apply.c,v 1.68 2002/11/13 00:26:13 garbled Exp $";   *   "$Id: apply.c,v 1.69 2002/11/26 08:48:20 garbled Exp $";
  */   */
 /*  /*
     CrossFire, A Multiplayer game for X-windows      CrossFire, A Multiplayer game for X-windows
Line 844
 
Line 844
      CLEAR_FLAG (op->container, FLAG_WALK_OFF);       CLEAR_FLAG (op->container, FLAG_WALK_OFF);
      CLEAR_FLAG (op->container, FLAG_FLY_OFF);       CLEAR_FLAG (op->container, FLAG_FLY_OFF);
  }   }
 #ifdef PLUGINS  
  /* GROS: Handle for plugin close event */   /* GROS: Handle for plugin close event */
  if(tmp->event_hook[EVENT_CLOSE] != NULL)   if(tmp->event_hook[EVENT_CLOSE] != NULL)
  {   {
Line 873
 
Line 872
  if (rtn_script!=0) return 1;   if (rtn_script!=0) return 1;
  }   }
  }   }
 #endif  
  new_draw_info_format(NDI_UNIQUE, 0, op, "You close %s.",   new_draw_info_format(NDI_UNIQUE, 0, op, "You close %s.",
        query_name(op->container));         query_name(op->container));
  CLEAR_FLAG(op->container, FLAG_APPLIED);   CLEAR_FLAG(op->container, FLAG_APPLIED);
Line 1112
 
Line 1110
   }    }
   recursion_depth++;    recursion_depth++;
   if (trap->head) trap=trap->head;    if (trap->head) trap=trap->head;
 #ifdef PLUGINS  
   /* GROS: Handle for plugin close event */    /* GROS: Handle for plugin close event */
   if(trap->event_hook[EVENT_TRIGGER] != NULL)    if(trap->event_hook[EVENT_TRIGGER] != NULL)
   {    {
Line 1141
 
Line 1138
       if (rtn_script!=0) return;        if (rtn_script!=0) return;
     }      }
   }    }
 #endif  
   switch (trap->type)    switch (trap->type)
   {    {
   case PLAYERMOVER:    case PLAYERMOVER:
Line 1388
 
Line 1384
   
     new_draw_info_format (NDI_UNIQUE, 0, op,      new_draw_info_format (NDI_UNIQUE, 0, op,
                           "You open the %s and start reading.", tmp->name);                            "You open the %s and start reading.", tmp->name);
 #ifdef PLUGINS  
     /* GROS: Handle for plugin trigger event */      /* GROS: Handle for plugin trigger event */
     if(tmp->event_hook[EVENT_APPLY] != NULL)      if(tmp->event_hook[EVENT_APPLY] != NULL)
     {      {
Line 1412
 
Line 1407
             ((PlugList[findPlugin(tmp->event_plugin[k])].eventfunc) (&CFP));              ((PlugList[findPlugin(tmp->event_plugin[k])].eventfunc) (&CFP));
     }      }
     else      else
 #endif  
         new_draw_info(NDI_UNIQUE | NDI_NAVY, 0, op, tmp->msg);          new_draw_info(NDI_UNIQUE | NDI_NAVY, 0, op, tmp->msg);
   
     /* gain xp from reading */      /* gain xp from reading */
Line 2128
 
Line 2122
   if (op->type != PLAYER && tmp->type == TREASURE)    if (op->type != PLAYER && tmp->type == TREASURE)
     return 0;      return 0;
      
 #ifdef PLUGINS  
   /* GROS: Handle for plugin trigger event */    /* GROS: Handle for plugin trigger event */
   if(tmp->event_hook[EVENT_APPLY] != NULL)    if(tmp->event_hook[EVENT_APPLY] != NULL)
   {    {
Line 2156
 
Line 2149
         if (rtn_script!=0) return 1;          if (rtn_script!=0) return 1;
     }      }
   }    }
 #endif  
   switch (tmp->type)    switch (tmp->type)
   {    {
   case CF_HANDLE:    case CF_HANDLE:
Line 2878
 
Line 2870
      new_draw_info_format(NDI_UNIQUE, 0, who, "You wield %s.",query_name(op));       new_draw_info_format(NDI_UNIQUE, 0, who, "You wield %s.",query_name(op));
   
      (void) change_abil (who,op);       (void) change_abil (who,op);
 #ifdef PLUGINS  
      /* GROS: update the current_weapon_script field (used with EVENT_ATTACK for weapons) */       /* GROS: update the current_weapon_script field (used with EVENT_ATTACK for weapons) */
      if (op->event_hook[EVENT_ATTACK] != NULL) {       if (op->event_hook[EVENT_ATTACK] != NULL) {
  LOG(llevDebug, "Scripting Weapon wielded\n");   LOG(llevDebug, "Scripting Weapon wielded\n");
  if (who->current_weapon_script) free_string(who->current_weapon_script);   if (who->current_weapon_script) free_string(who->current_weapon_script);
  who->current_weapon_script=add_string(query_name(op));   who->current_weapon_script=add_string(query_name(op));
      }       }
 #endif  
      who->current_weapon = op;       who->current_weapon = op;
      break;       break;
   


Legend:
line(s) removed in v.1.68 
line(s) changed
 line(s) added in v.1.69

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