Difference for server/gods.c from version 1.54 to 1.55


version 1.54 version 1.55
Line 1
 
Line 1
 /*  /*
  * static char *rcsid_gods_c =   * static char *rcsid_gods_c =
  *   "$Id: gods.c,v 1.54 2005/10/16 08:48:30 ryo_saeba Exp $";   *   "$Id: gods.c,v 1.55 2005/10/18 16:54:31 gros Exp $";
  */   */
   
 /*  /*
Line 240
 
Line 240
  */   */
 void pray_at_altar(object *pl, object *altar, object *skill) {  void pray_at_altar(object *pl, object *altar, object *skill) {
     object *pl_god=find_god(determine_god(pl));      object *pl_god=find_god(determine_god(pl));
     int return_pray_script; /* GROS : This is for return value of script */  
     event *evt;  
   
     /* GROS: Handle for plugin altar-parying (apply) event */      /* Lauwenmark: Handle for plugin altar-parying (apply) event */
     if ((evt = find_event(altar, EVENT_APPLY)) != NULL)      if (execute_event(altar, EVENT_APPLY,pl,NULL,NULL,SCRIPT_FIX_ALL)!=0)
     {          return;
         CFParm CFP;  
         CFParm* CFR;  
         int k, l, m;  
         uint32 n;  
         k = EVENT_APPLY;  
         l = SCRIPT_FIX_ALL;  
         m = 0;  
         n = 0;  
         CFP.Value[0] = &k;  
         CFP.Value[1] = pl;  
         CFP.Value[2] = altar;  
         CFP.Value[3] = NULL;  
         CFP.Value[4] = NULL;  
         CFP.Value[5] = &n;  
         CFP.Value[6] = &m;  
         CFP.Value[7] = &m;  
         CFP.Value[8] = &l;  
         CFP.Value[9] = (void*)evt->hook;  
         CFP.Value[10]= (void*)evt->options;  
         if (findPlugin(evt->plugin)>=0)  
         {  
             CFR = (PlugList[findPlugin(evt->plugin)].eventfunc) (&CFP);  
             return_pray_script = *(int *)(CFR->Value[0]);  
             free(CFR);  
             if (return_pray_script) return;  
         }  
     }  
   
     /* If non consecrate altar, don't do anything */      /* If non consecrate altar, don't do anything */
     if (!altar->other_arch) return;      if (!altar->other_arch) return;
Line 282
 
Line 253
  become_follower(pl,&altar->other_arch->clone);   become_follower(pl,&altar->other_arch->clone);
  return;   return;
   
     } else if(!strcmp(pl_god->name,altar->other_arch->clone.name)) { /* pray at your gods altar */      } else if(!strcmp(pl_god->name,altar->other_arch->clone.name)) {
           /* pray at your gods altar */
  int bonus = (pl->stats.Wis+skill->level)/10;   int bonus = (pl->stats.Wis+skill->level)/10;
   
  /* we can get neg grace up faster */   /* we can get neg grace up faster */
Line 315
 
Line 287
  * is the opposing god - we need to verify that exists before   * is the opposing god - we need to verify that exists before
  * using its values.   * using its values.
  */   */
  if(pl_god->other_arch && (altar->other_arch->name==pl_god->other_arch->name)) {          if(pl_god->other_arch &&
              (altar->other_arch->name==pl_god->other_arch->name)) {
      angry=2;       angry=2;
      if(random_roll(0, skill->level+2, pl, PREFER_LOW)-5 > 0) {       if(random_roll(0, skill->level+2, pl, PREFER_LOW)-5 > 0) {
  object *tmp;   object *tmp;


Legend:
line(s) removed in v.1.54 
line(s) changed
 line(s) added in v.1.55

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