Overview
Comment: | Some corrections to animate_ext and collide_with functions in exec.c. |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
c76e659783160254069a750faf3ad216 |
User & Date: | user on 2021-11-16 20:02:47 |
Other Links: | manifest | tags |
Context
2021-11-18
| ||
00:56 | Implement batch import mode. check-in: c75006b3f9 user: user tags: trunk | |
2021-11-16
| ||
20:02 | Some corrections to animate_ext and collide_with functions in exec.c. check-in: c76e659783 user: user tags: trunk | |
08:45 | Fix the =Animate instruction. check-in: 222a54522d user: user tags: trunk | |
Changes
Modified exec.c from [17b60b9454] to [d436eb2e04].
︙ | ︙ | |||
341 342 343 344 345 346 347 | an->vimage=(f&0x08?objects[n]->image:a0); if(f&0x10) an->ltime=an->vtime=t/2; switch(f&0x07) { case 0: an->status=0; an->step->flag=0; break; case 1: an->status=ANISTAT_LOGICAL; an->step->flag=ANI_ONCE; break; case 2: an->status=ANISTAT_VISUAL|ANISTAT_LOGICAL; an->step->flag=ANI_ONCE; break; case 3: an->status=ANISTAT_VISUAL; an->step->flag=ANI_ONCE; break; | | | | 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 | an->vimage=(f&0x08?objects[n]->image:a0); if(f&0x10) an->ltime=an->vtime=t/2; switch(f&0x07) { case 0: an->status=0; an->step->flag=0; break; case 1: an->status=ANISTAT_LOGICAL; an->step->flag=ANI_ONCE; break; case 2: an->status=ANISTAT_VISUAL|ANISTAT_LOGICAL; an->step->flag=ANI_ONCE; break; case 3: an->status=ANISTAT_VISUAL; an->step->flag=ANI_ONCE; break; case 4: an->status=ANISTAT_VISUAL|ANISTAT_LOGICAL; an->step->flag=ANI_LOOP; break; case 5: an->status=ANISTAT_VISUAL|ANISTAT_LOGICAL; an->step->flag=ANI_LOOP|ANI_OSC; break; case 6: an->status=ANISTAT_VISUAL|ANISTAT_SYNCHRONIZED; an->step->flag=ANI_LOOP|ANI_SYNC; an->step->slot=t&7; break; case 7: an->status=ANISTAT_LOGICAL; an->step->flag=ANI_ONCE; objects[n]->image=a0; break; } } static void animate_sync(Uint32 n,Uint32 sl,Uint32 a0) { Animation*an=objects[n]->anim; |
︙ | ︙ | |||
655 656 657 658 659 660 661 | int i,j; Uint8 r=0; Uint32 e[8]={VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK}; Uint8 re[8]={0,0,0,0,0,0,0,0}; Value v; if(StackProtection()) Throw("Call stack overflow"); for(i=0;i<8;i++) if(b&(1<<i)) e[i]=obj_layer_at(1<<i,x,y); | | > | | | > | 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 | int i,j; Uint8 r=0; Uint32 e[8]={VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK,VOIDLINK}; Uint8 re[8]={0,0,0,0,0,0,0,0}; Value v; if(StackProtection()) Throw("Call stack overflow"); for(i=0;i<8;i++) if(b&(1<<i)) e[i]=obj_layer_at(1<<i,x,y); for(i=0;i<7;i++) for(j=i+1;j<8;j++) if(e[i]==e[j]) e[j]=VOIDLINK; if(n!=VOIDLINK) { v=send_message(VOIDLINK,n,MSG_COLLIDE,NVALUE(x),NVALUE(y),NVALUE(b)); if(v.t) Throw("Type mismatch in COLLIDE"); r=v.u; } for(i=0;i<8;i++) if(e[i]!=VOIDLINK && !(r&0x02)) { v=send_message(n,e[i],MSG_COLLIDEBY,NVALUE(n==VOIDLINK?0:objects[n]->x),NVALUE(n==VOIDLINK?0:objects[n]->y),CVALUE(c)); if(v.t) Throw("Type mismatch in COLLIDEBY"); r|=re[i]=v.u; } if(!(r&0x01)) { // See if we can destroy some objects to make room |
︙ | ︙ |