Difference for plugins/cfanim/cfanim.c from version 1.2 to 1.3


version 1.2 version 1.3
Line 39
 
Line 39
   
 CFPContext* context_stack;  CFPContext* context_stack;
 CFPContext* current_context;  CFPContext* current_context;
 static int current_command = -999;  
 CFanimation *first_animation=NULL;  CFanimation *first_animation=NULL;
   
 int get_dir_from_name (char*name)  int get_dir_from_name (char*name)
Line 274
 
Line 273
 int runghosted(struct CFanimation_struct* animation, long int id, void* parameters)  int runghosted(struct CFanimation_struct* animation, long int id, void* parameters)
 {  {
     object* corpse;      object* corpse;
     int val;  
     if ( (id && animation->ghosted) ||      if ( (id && animation->ghosted) ||
           (!id && !animation->ghosted) )            (!id && !animation->ghosted) )
         runghosted(animation, !id, parameters);          runghosted(animation, !id, parameters);
Line 355
 
Line 354
 }  }
 int runteleport(struct CFanimation_struct* animation, long int id, void* parameters)  int runteleport(struct CFanimation_struct* animation, long int id, void* parameters)
 {  {
     int val=0;  
     teleport_params* teleport=(teleport_params*)parameters;      teleport_params* teleport=(teleport_params*)parameters;
     if (!parameters)      if (!parameters)
         return 0;          return 0;
Line 837
 
Line 835
 void animate_one(CFanimation* animation, long int milliseconds)  void animate_one(CFanimation* animation, long int milliseconds)
 {  {
     CFmovement* current;      CFmovement* current;
     int val;  
     if (animation->time_representation==time_second)      if (animation->time_representation==time_second)
         animation->tick_left+=milliseconds;          animation->tick_left+=milliseconds;
     else animation->tick_left++;      else animation->tick_left++;
     if (animation->verbose)      if (animation->verbose)
         printf("CFAnim: Ticking %s for %s. Tickleft is %d\n",          printf("CFAnim: Ticking %s for %s. Tickleft is %ld\n",
                animation->name,animation->victim->name,animation->tick_left);                 animation->name,animation->victim->name,animation->tick_left);
     if (animation->invisible)      if (animation->invisible)
         animation->victim->invisible=10;          animation->victim->invisible=10;
Line 927
 
Line 925
   
 void pushContext(CFPContext* context)  void pushContext(CFPContext* context)
 {  {
     CFPContext* stack_context;  
     if (current_context == NULL)      if (current_context == NULL)
     {      {
         context_stack = context;          context_stack = context;
Line 956
 
Line 953
 int initPlugin(const char* iversion, f_plug_api gethooksptr)  int initPlugin(const char* iversion, f_plug_api gethooksptr)
 {  {
     gethook = gethooksptr;      gethook = gethooksptr;
     int i;  
     printf("CFAnim 2.0a init\n");      printf("CFAnim 2.0a init\n");
   
     /* Place your initialization code here */      /* Place your initialization code here */
Line 967
 
Line 964
 {  {
     va_list args;      va_list args;
     char* propname;      char* propname;
     int i;  
     va_start(args, type);      va_start(args, type);
     propname = va_arg(args, char *);      propname = va_arg(args, char *);
     printf("Property name: %s\n", propname);      printf("Property name: %s\n", propname);
Line 1015
 
Line 1012
     context = malloc(sizeof(CFPContext));      context = malloc(sizeof(CFPContext));
     char* buf;      char* buf;
     player* pl;      player* pl;
     object* op;  
   
     va_start(args, type);      va_start(args, type);
     context->event_code = va_arg(args, int);      context->event_code = va_arg(args, int);


Legend:
line(s) removed in v.1.2 
line(s) changed
 line(s) added in v.1.3

File made using version 1.98 of cvs2html by leaf at 2011-07-21 16:58