LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: ambushyell
void
ambushyell(short sn, short ext)
{
    #ifdef PLRSPRDEBUG
     if( isaplayersprite(sn) ) {
          crashgame("messing w plrsprite at 24");
     }
    #endif

     if( !validext(ext) ) {
          return;
     }
     if( sprXTptr[ext]->aimask&AI_DIDAMBUSHYELL )
          return;

     switch( sprXTptr[ext]->basepic ) {
     case ANTWALKPIC:
     case RUBWALKPIC:
          playsound(S_MALE_COMEONYOU+(krand_intercept("STAT2603")&6),sprptr[sn]->x,sprptr[sn]->y,0,ST_IMMEDIATE);
          sprXTptr[ext]->aimask|=AI_DIDAMBUSHYELL;
          break;
     case DIWALKPIC:
          playsound(S_DIM_WANTSOMETHIS+(krand_intercept("STAT2607")&2),sprptr[sn]->x,sprptr[sn]->y,0,ST_IMMEDIATE);
          sprXTptr[ext]->aimask|=AI_DIDAMBUSHYELL;
          break;
     }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebp
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x208cc
leaq 0x6ffe4(%rip), %rdi     # 0x908a9
xorl %eax, %eax
callq 0x2eb88
movzwl %bp, %r14d
cmpl $0x3fff, %r14d          # imm = 0x3FFF
ja 0x20962
leaq 0x1b894c(%rip), %r15    # 0x1d9230
movq (%r15,%r14,8), %rax
testb $0x2, 0x7(%rax)
jne 0x20962
movzwl 0xa(%rax), %eax
movl $0x97, %r12d
movl $0x6, %ebp
leaq 0x6ffbf(%rip), %rdi     # 0x908c3
cmpl $0x163, %eax            # imm = 0x163
je 0x2092b
cmpl $0x6d7, %eax            # imm = 0x6D7
je 0x2092b
cmpl $0x75f, %eax            # imm = 0x75F
jne 0x20962
movl $0xca, %r12d
movl $0x2, %ebp
leaq 0x6ffa1(%rip), %rdi     # 0x908cc
callq 0x2d112
andl %eax, %ebp
addl %r12d, %ebp
movswq %bx, %rax
leaq 0x1108f0(%rip), %rcx    # 0x131230
movq (%rcx,%rax,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
movl %ebp, %edi
xorl %ecx, %ecx
movl $0x1, %r8d
callq 0x1c370
movq (%r15,%r14,8), %rax
orw $0x200, 0x6(%rax)       # imm = 0x200
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: givewarning
void
givewarning(short i, short ext)
{
     int dist = 0L;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(i) ) {
          crashgame("messing w plrsprite at 25");
     }
    #endif

     if( option[4] != 0 ) {
          return;
     }
     if( !validext(ext) ) {
          return;
     }
     if( sprXTptr[ext]->aimask&AI_GAVEWARNING )
          return;

     dist=abs(posx[screenpeek]-sprptr[i]->x)+abs(posy[screenpeek]-sprptr[i]->y);
     if( dist > 5000 ) {
          return;
     }

     switch( sprXTptr[ext]->basepic ) {
     case COP1WALKPIC:
          playsound(S_GRD_WHATDOINGHERE+(krand_intercept("STAT2636")&4),sprptr[i]->x,sprptr[i]->y,0,ST_UNIQUE);
          sprXTptr[ext]->aimask|=AI_GAVEWARNING;
          break;
     }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebp
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x2098e
leaq 0x6ff4e(%rip), %rdi     # 0x908d5
xorl %eax, %eax
callq 0x2eb88
movzwl %bp, %r14d
cmpl $0x3fff, %r14d          # imm = 0x3FFF
ja 0x20a4c
leaq 0xb0fd2(%rip), %rax     # 0xd1978
cmpb $0x0, 0x4(%rax)
jne 0x20a4c
leaq 0x1b8879(%rip), %r15    # 0x1d9230
movq (%r15,%r14,8), %rax
testb $0x40, 0x6(%rax)
jne 0x20a4c
leaq 0xc3a92(%rip), %rcx     # 0xe445e
movswq (%rcx), %rcx
leaq 0xc3af9(%rip), %rdx     # 0xe44d0
movl (%rdx,%rcx,4), %edx
movswq %bx, %rbx
leaq 0x11084b(%rip), %r12    # 0x131230
movq (%r12,%rbx,8), %rsi
subl (%rsi), %edx
movl %edx, %edi
negl %edi
cmovsl %edx, %edi
leaq 0xc3b17(%rip), %rdx     # 0xe4510
movl (%rdx,%rcx,4), %ecx
subl 0x4(%rsi), %ecx
movl %ecx, %edx
negl %edx
cmovsl %ecx, %edx
addl %edi, %edx
cmpl $0x1388, %edx           # imm = 0x1388
ja 0x20a4c
cmpw $0x45b, 0xa(%rax)       # imm = 0x45B
jne 0x20a4c
leaq 0x6fed0(%rip), %rdi     # 0x908ef
callq 0x2d112
andl $0x4, %eax
leal 0xc5(%rax), %edi
movq (%r12,%rbx,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
xorl %ecx, %ecx
movl $0x8, %r8d
callq 0x1c370
movq (%r15,%r14,8), %rax
orw $0x40, 0x6(%rax)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: isanandroid
int
isanandroid(int i)
{
	int	ext=sprptr[i]->extra;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(i) ) {
          crashgame("messing w plrsprite at 22");
     }
    #endif

     if( validext(ext) ) {
          if( ((sprXTptr[ext]->fxmask)&FX_ANDROID) != 0 ) {
               return(1);
          }
     }

     return(0);
}

// Assembly:
pushq %rbx
movslq %edi, %rdi
leaq 0x1103a3(%rip), %rax    # 0x131230
movq (%rax,%rdi,8), %rax
movzwl 0x2a(%rax), %ebx
callq 0x1eb81
testl %eax, %eax
je 0x20eac
leaq 0x6f9b5(%rip), %rdi     # 0x9085a
xorl %eax, %eax
callq 0x2eb88
cmpl $0x3fff, %ebx           # imm = 0x3FFF
ja 0x20eca
leaq 0x1b8375(%rip), %rax    # 0x1d9230
movq (%rax,%rbx,8), %rcx
movl $0x1, %eax
testb $0x4, 0x4(%rcx)
jne 0x20ecc
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: isahologram
int
isahologram(int i)
{
	int	ext=sprptr[i]->extra;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(i) ) {
          crashgame("messing w plrsprite at 21");
     }
    #endif

     if( validext(ext) ) {
          if( ((sprXTptr[ext]->fxmask)&FX_HOLOGRAM) != 0 ) {
               return(1);
          }
     }

     return(0);
}

// Assembly:
pushq %rbx
movslq %edi, %rdi
leaq 0x110357(%rip), %rax    # 0x131230
movq (%rax,%rdi,8), %rax
movzwl 0x2a(%rax), %ebx
callq 0x1eb81
testl %eax, %eax
je 0x20ef8
leaq 0x6f94f(%rip), %rdi     # 0x90840
xorl %eax, %eax
callq 0x2eb88
cmpl $0x3fff, %ebx           # imm = 0x3FFF
ja 0x20f16
leaq 0x1b8329(%rip), %rax    # 0x1d9230
movq (%rax,%rbx,8), %rcx
movl $0x1, %eax
testb $0x8, 0x4(%rcx)
jne 0x20f18
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: playervirus
int
playervirus(short pnum, int pic)
{
     int       j,nextj;

     if( !validplayer(pnum) ) {
          crashgame("plrvrus: bad plrnum");
     }

	j=headspritestat[PLRVIRUS];
	while( j >= 0 ) {
		nextj = nextspritestat[j];
          // already hosting ?
          if( sprptr[j]->owner == pnum ) {
               return(0);
          }
		j = nextj;
	}

     j=jsinsertsprite(cursectnum[pnum], PLRVIRUS);
     if( j == -1 ) {
          return(0);
     }

     sprptr[j]->extra=-1;
     sprptr[j]->x=posx[pnum];
     sprptr[j]->y=posy[pnum];
     sprptr[j]->z=posz[pnum];
     sprptr[j]->xrepeat=18;
     sprptr[j]->yrepeat=40;
     sprptr[j]->cstat=0x0000;
     sprptr[j]->shade=-28;
     sprptr[j]->picnum=pic;
     sprptr[j]->lotag=(krand_intercept("STAT1172")&512)+128;
     sprptr[j]->hitag=0;
     sprptr[j]->owner=pnum;  // host

     playsound(S_FIRELOOP,sprptr[j]->x,sprptr[j]->y,0,ST_UPDATE);

     return(1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebx
movl %edi, %ebp
callq 0xf230
testl %eax, %eax
jne 0x20f3d
leaq 0x6f6e3(%rip), %rdi     # 0x90619
xorl %eax, %eax
callq 0x2eb88
leaq 0x54e45c(%rip), %rax    # 0x56f3a0
movzwl 0x1fe(%rax), %edx
testw %dx, %dx
js 0x20f78
leaq 0x1102d9(%rip), %rax    # 0x131230
leaq 0x556c52(%rip), %rcx    # 0x577bb0
movzwl %dx, %edx
movq (%rax,%rdx,8), %rsi
cmpw %bp, 0x1e(%rsi)
je 0x21061
movzwl (%rcx,%rdx,2), %edx
testw %dx, %dx
jns 0x20f5e
movswq %bp, %r14
leaq 0xc479d(%rip), %rax     # 0xe5720
movswl (%rax,%r14,2), %edi
movl $0xff, %esi
callq 0x1eac8
cmpw $-0x1, %ax
je 0x21061
movswq %ax, %r15
leaq 0x110289(%rip), %r12    # 0x131230
movq (%r12,%r15,8), %rax
movw $0xffff, 0x2a(%rax)     # imm = 0xFFFF
leaq 0xc3518(%rip), %rax     # 0xe44d0
movl (%rax,%r14,4), %eax
movq (%r12,%r15,8), %rcx
movl %eax, (%rcx)
leaq 0xc3547(%rip), %rax     # 0xe4510
movl (%rax,%r14,4), %eax
movq (%r12,%r15,8), %rcx
movl %eax, 0x4(%rcx)
leaq 0xc3575(%rip), %rax     # 0xe4550
movl (%rax,%r14,4), %eax
movq (%r12,%r15,8), %rcx
movl %eax, 0x8(%rcx)
movq (%r12,%r15,8), %rax
movb $0x12, 0x14(%rax)
movq (%r12,%r15,8), %rax
movb $0x28, 0x15(%rax)
movq (%r12,%r15,8), %rax
xorl %ebp, %ebp
movw %bp, 0xc(%rax)
movq (%r12,%r15,8), %rax
movb $-0x1c, 0x10(%rax)
movq (%r12,%r15,8), %rax
movw %bx, 0xe(%rax)
leaq 0x6f616(%rip), %rdi     # 0x9062d
callq 0x2d112
andl $0x200, %eax            # imm = 0x200
orl $0x80, %eax
movq (%r12,%r15,8), %rcx
movw %ax, 0x26(%rcx)
movq (%r12,%r15,8), %rax
movw %bp, 0x28(%rax)
movq (%r12,%r15,8), %rax
movw %r14w, 0x1e(%rax)
movq (%r12,%r15,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
movl $0x24, %edi
xorl %ecx, %ecx
movl $0x2, %r8d
callq 0x1c370
movl $0x1, %eax
jmp 0x21063
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: hideplea
void
hideplea(short sn, short ext)
{
    #ifdef PLRSPRDEBUG
     if( isaplayersprite(sn) ) {
          crashgame("messing w plrsprite at 8");
     }
    #endif

     if( (sprXTptr[ext]->aimask&AI_DIDHIDEPLEA) && (krand_intercept("STAT1383")&1) )
          return;

     switch( sprXTptr[ext]->basepic ) {
     case ERWALKPIC:
          playsound(S_MALE_DONTHURT+(krand_intercept("STAT1390")&5),sprptr[sn]->x,sprptr[sn]->y,0,ST_UNIQUE);
          if(krand_intercept("STAT1391")&1) {
               sprXTptr[ext]->aimask|=AI_DIDHIDEPLEA;
          }
          break;
     case SARAHWALKPIC:
     case SAMWALKPIC:
          playsound(S_DIANE_DONTSHOOTP+(krand_intercept("STAT1397")&5),sprptr[sn]->x,sprptr[sn]->y,0,ST_UNIQUE);
          if(krand_intercept("STAT1398")&1) {
               sprXTptr[ext]->aimask|=AI_DIDHIDEPLEA;
          }
          break;
     }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x21828
leaq 0x6ee64(%rip), %rdi     # 0x90685
xorl %eax, %eax
callq 0x2eb88
movswq %bp, %r14
leaq 0x1b79fd(%rip), %r15    # 0x1d9230
movq (%r15,%r14,8), %rax
testb $0x4, 0x7(%rax)
je 0x21855
leaq 0x6ee5a(%rip), %rdi     # 0x9069e
callq 0x2d112
testb $0x1, %al
jne 0x21901
movq (%r15,%r14,8), %rax
movzwl 0xa(%rax), %eax
cmpl $0x709, %eax            # imm = 0x709
je 0x218b1
cmpl $0x7d3, %eax            # imm = 0x7D3
je 0x218b1
cmpl $0x79e, %eax            # imm = 0x79E
jne 0x21901
leaq 0x6ee2e(%rip), %rdi     # 0x906a7
callq 0x2d112
andl $0x5, %eax
leal 0x9e(%rax), %edi
movswq %bx, %rax
leaq 0x10f99e(%rip), %rcx    # 0x131230
movq (%rcx,%rax,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
xorl %ecx, %ecx
movl $0x8, %r8d
callq 0x1c370
leaq 0x6ee01(%rip), %rdi     # 0x906b0
jmp 0x218ee
leaq 0x6ee01(%rip), %rdi     # 0x906b9
callq 0x2d112
andl $0x5, %eax
leal 0xbb(%rax), %edi
movswq %bx, %rax
leaq 0x10f95f(%rip), %rcx    # 0x131230
movq (%rcx,%rax,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
xorl %ecx, %ecx
movl $0x8, %r8d
callq 0x1c370
leaq 0x6ed85(%rip), %rdi     # 0x90673
callq 0x2d112
testb $0x1, %al
je 0x21901
movq (%r15,%r14,8), %rax
orw $0x400, 0x6(%rax)       # imm = 0x400
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: fleescream
void
fleescream(short sn, short ext)
{
    #ifdef PLRSPRDEBUG
     if( isaplayersprite(sn) ) {
          crashgame("messing w plrsprite at 9");
     }
    #endif

     if( !validext(ext) ) {
          return;
     }

     if( (sprXTptr[ext]->aimask&AI_DIDFLEESCREAM) && (krand_intercept("STAT1417")&1) )
          return;

     switch( sprXTptr[ext]->basepic ) {
     case ERWALKPIC:
          playsound(S_MALE_OHMYGOD+(krand_intercept("STAT1424")&5),sprptr[sn]->x,sprptr[sn]->y,0,ST_UNIQUE);
          if(krand_intercept("STAT1425")&1) {
               sprXTptr[ext]->aimask|=AI_DIDFLEESCREAM;
          }
          break;
     case SARAHWALKPIC:
     case SAMWALKPIC:
          switch( RMOD4("STAT1478") ) {
		case 0:
          case 2:
               playsound(S_FEM_RUNHEGOTGUN+(krand_intercept("STAT1434")&11),sprptr[sn]->x,sprptr[sn]->y,0,ST_UNIQUE);
               break;
          default:
              playsound(S_SCREAM1+RMOD3("STAT1484"),sprptr[sn]->x,sprptr[sn]->y,0,ST_UNIQUE);
               break;
          }
          if(krand_intercept("STAT1440")&1) {
               sprXTptr[ext]->aimask|=AI_DIDFLEESCREAM;
          }
          break;
     }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebp
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x2192f
leaq 0x6ed9a(%rip), %rdi     # 0x906c2
xorl %eax, %eax
callq 0x2eb88
movzwl %bp, %r15d
cmpl $0x3fff, %r15d          # imm = 0x3FFF
ja 0x21a56
leaq 0x1b78e9(%rip), %r12    # 0x1d9230
movq (%r12,%r15,8), %rax
testb $0x1, 0x7(%rax)
je 0x21969
leaq 0x6ed83(%rip), %rdi     # 0x906db
callq 0x2d112
testb $0x1, %al
jne 0x21a56
movq (%r12,%r15,8), %rax
movzwl 0xa(%rax), %eax
cmpl $0x709, %eax            # imm = 0x709
je 0x219c5
cmpl $0x7d3, %eax            # imm = 0x7D3
je 0x219c5
cmpl $0x79e, %eax            # imm = 0x79E
jne 0x21a56
leaq 0x6ed57(%rip), %rdi     # 0x906e4
callq 0x2d112
andl $0x5, %eax
leal 0xa3(%rax), %edi
movswq %bx, %rax
leaq 0x10f88a(%rip), %rcx    # 0x131230
movq (%rcx,%rax,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
xorl %ecx, %ecx
movl $0x8, %r8d
callq 0x1c370
leaq 0x6ed2a(%rip), %rdi     # 0x906ed
jmp 0x21a43
leaq 0x6ed2a(%rip), %rdi     # 0x906f6
callq 0x2d112
btl $0x3, %eax
jb 0x219f0
leaq 0x6ed21(%rip), %rdi     # 0x906ff
callq 0x2d112
movl %eax, %ebp
andl $0xb, %ebp
addl $0xaf, %ebp
jmp 0x21a19
leaq 0x6ed11(%rip), %r14     # 0x90708
movq %r14, %rdi
callq 0x2d112
xorl %ebp, %ebp
cmpl $0x8001, %eax           # imm = 0x8001
setge %bpl
movq %r14, %rdi
callq 0x2d112
btl $0x1, %eax
adcl $0x7d, %ebp
movswq %bx, %rax
leaq 0x10f80c(%rip), %rcx    # 0x131230
movq (%rcx,%rax,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
movl %ebp, %edi
xorl %ecx, %ecx
movl $0x8, %r8d
callq 0x1c370
leaq 0x6ecce(%rip), %rdi     # 0x90711
callq 0x2d112
testb $0x1, %al
je 0x21a56
movq (%r12,%r15,8), %rax
orw $0x100, 0x6(%rax)       # imm = 0x100
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: rubitinsound
void
rubitinsound(int p, int sn)
{
     int       ext=sprptr[sn]->extra;

     (void)p;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(sn) ) {
          crashgame("messing w plrsprite at 10");
     }
    #endif

     if( !validext(ext) ) {
          return;
     }

     if( sprXTptr[ext]->aimask&AI_DIDHIDEPLEA )
          return;

     switch( sprXTptr[ext]->basepic ) {
     case MAWALKPIC:
          playsound(S_MAR_THINKYOUTAKE+RMOD3("STAT1513"),sprptr[sn]->x,sprptr[sn]->y,0,ST_UPDATE);
     case DIWALKPIC:
          playsound(S_DIM_LAUGHTER+RMOD3("STAT1515"),sprptr[sn]->x,sprptr[sn]->y,0,ST_UPDATE);
          break;
     case ANTWALKPIC:
          playsound(S_MALE_YOULOSER+RMOD3("STAT1518"),sprptr[sn]->x,sprptr[sn]->y,0,ST_UPDATE);
          break;
     }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movslq %esi, %rbx
leaq 0x10f7c0(%rip), %r15    # 0x131230
movq (%r15,%rbx,8), %rax
movzwl 0x2a(%rax), %r14d
movl %ebx, %edi
callq 0x1eb81
testl %eax, %eax
je 0x21a92
leaq 0x6ec8f(%rip), %rdi     # 0x9071a
xorl %eax, %eax
callq 0x2eb88
cmpl $0x3fff, %r14d          # imm = 0x3FFF
ja 0x21b49
leaq 0x1b778a(%rip), %rax    # 0x1d9230
movq (%rax,%r14,8), %rax
testb $0x4, 0x7(%rax)
jne 0x21b49
movzwl 0xa(%rax), %eax
cmpl $0x6d7, %eax            # imm = 0x6D7
je 0x21b54
cmpl $0x75f, %eax            # imm = 0x75F
je 0x21b18
cmpl $0x72a, %eax            # imm = 0x72A
jne 0x21b49
leaq 0x6ec5c(%rip), %r14     # 0x90734
movq %r14, %rdi
callq 0x2d112
xorl %ebp, %ebp
cmpl $0x8001, %eax           # imm = 0x8001
setge %bpl
movq %r14, %rdi
callq 0x2d112
orl $0xc2, %ebp
btl $0x1, %eax
adcl $0x0, %ebp
movq (%r15,%rbx,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
movl %ebp, %edi
xorl %ecx, %ecx
movl $0x2, %r8d
callq 0x1c370
leaq 0x6ec1e(%rip), %r14     # 0x9073d
movq %r14, %rdi
callq 0x2d112
xorl %ebp, %ebp
cmpl $0x8001, %eax           # imm = 0x8001
setge %bpl
movq %r14, %rdi
callq 0x2d112
btl $0x1, %eax
adcl $0x0, %ebp
orl $0xcc, %ebp
jmp 0x21b80
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x6ebeb(%rip), %r14     # 0x90746
movq %r14, %rdi
callq 0x2d112
xorl %ebp, %ebp
cmpl $0x8001, %eax           # imm = 0x8001
setge %bpl
movq %r14, %rdi
callq 0x2d112
btl $0x1, %eax
adcl $0x99, %ebp
movq (%r15,%rbx,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
movl %ebp, %edi
xorl %ecx, %ecx
movl $0x2, %r8d
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1c370
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: genexplosion1
void
genexplosion1(int i)
{
     int       j;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(i) ) {
          crashgame("messing w plrsprite at 30");
     }
    #endif

     j=jsinsertsprite(sprptr[i]->sectnum, 5);
     if( j != -1 ) {
          fillsprite(j,sprptr[i]->x,sprptr[i]->y,sprptr[i]->z,0,
                     -16,0,0,64,64,0,0,GENEXP1PIC+1,sprptr[i]->ang,
	                sintable[(sprptr[i]->ang+2560)&2047]>>6,sintable[(sprptr[i]->ang+2048)&2047]>>6,
	                30L,i+4096,sprptr[i]->sectnum, 5,24,0,-1);
          playsound(S_SMALLGLASS1+RMOD2("STAT4534"), sprptr[i]->x,sprptr[i]->y,0,ST_NOUPDATE);
          return;
     }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x21d47
leaq 0x6ec87(%rip), %rdi     # 0x909c7
xorl %eax, %eax
callq 0x2eb88
movslq %ebx, %r14
leaq 0x10f4df(%rip), %r15    # 0x131230
movq (%r15,%r14,8), %rax
movswl 0x18(%rax), %edi
movl $0x5, %esi
callq 0x1eac8
cmpw $-0x1, %ax
je 0x21e65
movswq %ax, %rax
imulq $0x2c, %rax, %rcx
leaq 0x40bdb4(%rip), %rdx    # 0x42db30
leaq (%rdx,%rcx), %rdi
movq (%r15,%r14,8), %rsi
movl (%rsi), %r8d
movl %r8d, (%rdx,%rcx)
movl 0x4(%rsi), %r8d
movl %r8d, 0x4(%rdx,%rcx)
movl 0x8(%rsi), %r8d
movl %r8d, 0x8(%rdx,%rcx)
movl $0x3bd0000, 0xc(%rdx,%rcx) # imm = 0x3BD0000
movw $0xf0, 0x10(%rdx,%rcx)
movb $0x0, 0x12(%rdx,%rcx)
movl $0x4040, 0x14(%rdx,%rcx) # imm = 0x4040
movl 0x1c(%rsi), %r8d
movw %r8w, 0x1c(%rdx,%rcx)
addl $0x200, %r8d            # imm = 0x200
movl $0x7ff, %r9d            # imm = 0x7FF
andl %r9d, %r8d
leaq 0x55ddf6(%rip), %r10    # 0x57fbd0
movswl (%r10,%r8,2), %r8d
shrl $0x6, %r8d
movw %r8w, 0x20(%rdx,%rcx)
movzwl 0x1c(%rsi), %esi
andl %r9d, %esi
movswl (%r10,%rsi,2), %esi
shrl $0x6, %esi
movw %si, 0x22(%rdx,%rcx)
addl $0x1000, %ebx           # imm = 0x1000
movw %bx, 0x1e(%rdx,%rcx)
movabsq $-0xffffffe7ffe2, %rsi  # imm = 0xFFFF00000018001E
movq %rsi, 0x24(%rdx,%rcx)
leaq (%rax,%rax,2), %rsi
shlq $0x2, %rsi
addq 0xaf18a(%rip), %rsi     # 0xd0fb0
movl $0x3, %edx
callq 0x6110e
leaq 0x6ebaa(%rip), %rdi     # 0x909e1
callq 0x2d112
xorl %edi, %edi
cmpl $0x8001, %eax           # imm = 0x8001
setge %dil
orl $0x74, %edi
movq (%r15,%r14,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
xorl %ecx, %ecx
movl $0x4, %r8d
popq %rbx
popq %r14
popq %r15
jmp 0x1c370
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: genexplosion2
void
genexplosion2(int i)
{
     int       j;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(i) ) {
          crashgame("messing w plrsprite at 31");
     }
    #endif

     sectorflash(sprptr[i]->sectnum);
     checkblastarea(i);

     j=jsinsertsprite(sprptr[i]->sectnum, 5);
     if( j != -1 ) {
          fillsprite(j,sprptr[i]->x,sprptr[i]->y,sprptr[i]->z-(tilesizy[sprptr[i]->picnum]<<3),0,
                     -16,0,0,64,64,0,0,GENEXP2PIC,sprptr[i]->ang,
	                sintable[(sprptr[i]->ang+2560)&2047]>>6,sintable[(sprptr[i]->ang+2048)&2047]>>6,
	                30L,i+4096,sprptr[i]->sectnum, 5,32,0,-1);
          playsound(S_EXPLODE1+RMOD2("STAT4559"), sprptr[i]->x,sprptr[i]->y,0,ST_NOUPDATE);
     }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x21e89
leaq 0x6eb68(%rip), %rdi     # 0x909ea
xorl %eax, %eax
callq 0x2eb88
movslq %ebx, %r14
cmpl $0x0, 0x214599(%rip)    # 0x23642c
jne 0x21eca
leaq 0x10f394(%rip), %rax    # 0x131230
movq (%rax,%r14,8), %rax
movswq 0x18(%rax), %rax
movw %ax, 0x21457c(%rip)     # 0x236428
movl $0x1, 0x214576(%rip)    # 0x23642c
leaq 0x1d7373(%rip), %rcx    # 0x1f9230
movq (%rcx,%rax,8), %rax
movb 0x20(%rax), %al
movb %al, 0x214566(%rip)     # 0x236430
movl %ebx, %edi
callq 0x274e6
leaq 0x10f358(%rip), %r15    # 0x131230
movq (%r15,%r14,8), %rax
movswl 0x18(%rax), %edi
movl $0x5, %esi
callq 0x1eac8
cmpw $-0x1, %ax
je 0x22004
movswq %ax, %rax
imulq $0x2c, %rax, %rcx
leaq 0x40bc2d(%rip), %rdx    # 0x42db30
leaq (%rdx,%rcx), %rdi
movq (%r15,%r14,8), %rsi
movl (%rsi), %r8d
movl %r8d, (%rdx,%rcx)
movl 0x4(%rsi), %r8d
movl %r8d, 0x4(%rdx,%rcx)
movl 0x8(%rsi), %r8d
movswq 0xe(%rsi), %r9
leaq 0x590735(%rip), %r10    # 0x5b2660
movswl (%r10,%r9,2), %r9d
shll $0x3, %r9d
subl %r9d, %r8d
movl %r8d, 0x8(%rdx,%rcx)
movl $0x3c50000, 0xc(%rdx,%rcx) # imm = 0x3C50000
movw $0xf0, 0x10(%rdx,%rcx)
movb $0x0, 0x12(%rdx,%rcx)
movl $0x4040, 0x14(%rdx,%rcx) # imm = 0x4040
movl 0x1c(%rsi), %r8d
movw %r8w, 0x1c(%rdx,%rcx)
addl $0x200, %r8d            # imm = 0x200
movl $0x7ff, %r9d            # imm = 0x7FF
andl %r9d, %r8d
leaq 0x55dc57(%rip), %r10    # 0x57fbd0
movswl (%r10,%r8,2), %r8d
shrl $0x6, %r8d
movw %r8w, 0x20(%rdx,%rcx)
movzwl 0x1c(%rsi), %esi
andl %r9d, %esi
movswl (%r10,%rsi,2), %esi
shrl $0x6, %esi
movw %si, 0x22(%rdx,%rcx)
addl $0x1000, %ebx           # imm = 0x1000
movw %bx, 0x1e(%rdx,%rcx)
movabsq $-0xffffffdfffe2, %rsi  # imm = 0xFFFF00000020001E
movq %rsi, 0x24(%rdx,%rcx)
leaq (%rax,%rax,2), %rsi
shlq $0x2, %rsi
addq 0xaefeb(%rip), %rsi     # 0xd0fb0
movl $0x3, %edx
callq 0x6110e
leaq 0x6ea2e(%rip), %rdi     # 0x90a04
callq 0x2d112
xorl %edi, %edi
cmpl $0x8001, %eax           # imm = 0x8001
setge %dil
orl $0x72, %edi
movq (%r15,%r14,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
xorl %ecx, %ecx
movl $0x4, %r8d
popq %rbx
popq %r14
popq %r15
jmp 0x1c370
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: enemywoundplayer
void
enemywoundplayer(short plrhit, short sprnum, char guntype)
{
     int       damage=0;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(sprnum) ) {
          crashgame("messing w plrsprite at 15");
     }
    #endif

     if( !validplayer(plrhit) ) {
          return;
     }

     switch( guntype ) {
     case 0:
          damage=64;
          break;
     case 1:
     case 2:
     case 3:
     case 4:
     case 5:
          damage=128;
          break;
     case 6:
     default:
          damage=256;
          break;
     }
     switch( difficulty ) {
     case 0:
     case 1:
          damage>>=4;
          break;
     case 2:
          damage>>=3;
          break;
     case 3:
          damage>>=2;
          break;
     }

     changehealth(plrhit,-damage);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %edx, %ebp
movl %edi, %ebx
movl %esi, %edi
callq 0x1eb81
testl %eax, %eax
je 0x225b3
leaq 0x6e249(%rip), %rdi     # 0x907f5
xorl %eax, %eax
callq 0x2eb88
movswl %bx, %ebx
movl %ebx, %edi
callq 0xf230
testl %eax, %eax
je 0x225f7
movw $0x100, %ax             # imm = 0x100
cmpb $0x5, %bpl
ja 0x225da
movzbl %bpl, %eax
leaq 0x6deba(%rip), %rcx     # 0x90490
movzwl (%rcx,%rax,2), %eax
leaq 0x10ea43(%rip), %rcx    # 0x131024
movl (%rcx), %ecx
cmpl $0x2, %ecx
jb 0x225fe
je 0x22606
cmpl $0x3, %ecx
jne 0x2260c
movzwl %ax, %eax
shrl $0x2, %eax
jmp 0x2260c
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
movzwl %ax, %eax
shrl $0x4, %eax
jmp 0x2260c
movzwl %ax, %eax
shrl $0x3, %eax
negl %eax
movswl %ax, %esi
movl %ebx, %edi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0xa5e8
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: androidexplosion
void
androidexplosion(int i)
{
     int       j;

     j=jsinsertsprite(sprptr[i]->sectnum, 5);
     if( j != -1 ) {
          fillsprite(j,sprptr[i]->x,sprptr[i]->y,sprptr[i]->z,0,
                     -16,0,0,34,34,0,0,456,sprptr[i]->ang,
	                sintable[(sprptr[i]->ang+2560)&2047]>>6,sintable[(sprptr[i]->ang+2048)&2047]>>6,
	                30L,i+4096,sprptr[i]->sectnum, 5,32,0,-1);
     }
     playsound(S_ANDROID_DIE, sprptr[i]->x,sprptr[i]->y,0,ST_NOUPDATE);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movslq %edi, %rbx
leaq 0x10e548(%rip), %r14    # 0x131230
movq (%r14,%rbx,8), %rax
movswl 0x18(%rax), %edi
movl $0x5, %esi
callq 0x1eac8
cmpw $-0x1, %ax
je 0x22dc7
movswq %ax, %rax
imulq $0x2c, %rax, %rcx
leaq 0x40ae1d(%rip), %rdx    # 0x42db30
leaq (%rdx,%rcx), %rdi
movq (%r14,%rbx,8), %rsi
movl (%rsi), %r8d
movl %r8d, (%rdx,%rcx)
movl 0x4(%rsi), %r8d
movl %r8d, 0x4(%rdx,%rcx)
movl 0x8(%rsi), %r8d
movl %r8d, 0x8(%rdx,%rcx)
movl $0x1c80000, 0xc(%rdx,%rcx) # imm = 0x1C80000
movw $0xf0, 0x10(%rdx,%rcx)
movb $0x0, 0x12(%rdx,%rcx)
movl $0x2222, 0x14(%rdx,%rcx) # imm = 0x2222
movl 0x1c(%rsi), %r8d
movw %r8w, 0x1c(%rdx,%rcx)
addl $0x200, %r8d            # imm = 0x200
movl $0x7ff, %r9d            # imm = 0x7FF
andl %r9d, %r8d
leaq 0x55ce5f(%rip), %r10    # 0x57fbd0
movswl (%r10,%r8,2), %r8d
shrl $0x6, %r8d
movw %r8w, 0x20(%rdx,%rcx)
movzwl 0x1c(%rsi), %esi
andl %r9d, %esi
movswl (%r10,%rsi,2), %esi
shrl $0x6, %esi
movw %si, 0x22(%rdx,%rcx)
leal 0x1000(%rbx), %esi
movw %si, 0x1e(%rdx,%rcx)
movabsq $-0xffffffdfffe2, %rsi  # imm = 0xFFFF00000020001E
movq %rsi, 0x24(%rdx,%rcx)
leaq (%rax,%rax,2), %rsi
shlq $0x2, %rsi
addq 0xae1f3(%rip), %rsi     # 0xd0fb0
movl $0x3, %edx
callq 0x6110e
movq (%r14,%rbx,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
movl $0x91, %edi
xorl %ecx, %ecx
movl $0x4, %r8d
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x1c370
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: playerhit
int
playerhit(int hitsprite, int *pnum)
{
     int       j;

     for( j=connecthead ; j >= 0 ; j=connectpoint2[j] ) {
          if( playersprite[j] == hitsprite ) {
               if( sprptr[hitsprite]->statnum != 8 ) {
                    crashgame("plrhit: plrsprt lost sttnm 8");
               }
               *pnum=j;
               return(1);
          }
     }

     return(0);
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
leaq 0x782d3d(%rip), %rax    # 0x7a5b30
movl (%rax), %ebp
xorl %eax, %eax
testl %ebp, %ebp
js 0x22e4b
movq %rsi, %rbx
leaq 0xc294b(%rip), %rcx     # 0xe5750
leaq 0x782d34(%rip), %rdx    # 0x7a5b40
movl %ebp, %esi
movswl (%rcx,%rsi,2), %r8d
cmpl %edi, %r8d
je 0x22e21
movl (%rdx,%rsi,4), %ebp
testl %ebp, %ebp
jns 0x22e0c
jmp 0x22e4b
movslq %edi, %rax
leaq 0x10e405(%rip), %rcx    # 0x131230
movq (%rcx,%rax,8), %rax
cmpw $0x8, 0x1a(%rax)
je 0x22e44
leaq 0x6db53(%rip), %rdi     # 0x90990
xorl %eax, %eax
callq 0x2eb88
movl %ebp, (%rbx)
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: sectorflash
void
sectorflash(short s)
{
     if(  sectflash.step != 0 ) {
          return;
     }
     sectflash.sectnum=s;
     sectflash.step=1;
     sectflash.ovis=sectptr[s]->visibility;
}

// Assembly:
cmpl $0x0, 0x20ed37(%rip)    # 0x23642c
je 0x276f8
retq
movw %di, 0x20ed29(%rip)     # 0x236428
movl $0x1, 0x20ed23(%rip)    # 0x23642c
movswq %di, %rax
leaq 0x1d1b1c(%rip), %rcx    # 0x1f9230
movq (%rcx,%rax,8), %rax
movb 0x20(%rax), %al
movb %al, 0x20ed0f(%rip)     # 0x236430
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: bombexplosion
void
bombexplosion(int i)
{
     int       j;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(i) ) {
          crashgame("messing w plrsprite at 32");
     }
    #endif

     j=jsinsertsprite(sprptr[i]->sectnum, 5);
     if( j != -1 ) {
          fillsprite(j,sprptr[i]->x,sprptr[i]->y,sprptr[i]->z,0,
                     -16,0,0,34,34,0,0,BOMBEXP1PIC,sprptr[i]->ang,
	                sintable[(sprptr[i]->ang+2560)&2047]>>6,sintable[(sprptr[i]->ang+2048)&2047]>>6,
	                30L,i+4096,sprptr[i]->sectnum, 5,32,0,-1);
          playsound(S_RIC2, sprptr[i]->x,sprptr[i]->y,0,ST_NOUPDATE);
     }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x27740
leaq 0x692d4(%rip), %rdi     # 0x90a0d
xorl %eax, %eax
callq 0x2eb88
movslq %ebx, %r14
leaq 0x109ae6(%rip), %r15    # 0x131230
movq (%r15,%r14,8), %rax
movswl 0x18(%rax), %edi
movl $0x5, %esi
callq 0x1eac8
cmpw $-0x1, %ax
je 0x27849
movswq %ax, %rax
imulq $0x2c, %rax, %rcx
leaq 0x4063bb(%rip), %rdx    # 0x42db30
leaq (%rdx,%rcx), %rdi
movq (%r15,%r14,8), %rsi
movl (%rsi), %r8d
movl %r8d, (%rdx,%rcx)
movl 0x4(%rsi), %r8d
movl %r8d, 0x4(%rdx,%rcx)
movl 0x8(%rsi), %r8d
movl %r8d, 0x8(%rdx,%rcx)
movl $0x1cc0000, 0xc(%rdx,%rcx) # imm = 0x1CC0000
movw $0xf0, 0x10(%rdx,%rcx)
movb $0x0, 0x12(%rdx,%rcx)
movl $0x2222, 0x14(%rdx,%rcx) # imm = 0x2222
movl 0x1c(%rsi), %r8d
movw %r8w, 0x1c(%rdx,%rcx)
addl $0x200, %r8d            # imm = 0x200
movl $0x7ff, %r9d            # imm = 0x7FF
andl %r9d, %r8d
leaq 0x5583fd(%rip), %r10    # 0x57fbd0
movswl (%r10,%r8,2), %r8d
shrl $0x6, %r8d
movw %r8w, 0x20(%rdx,%rcx)
movzwl 0x1c(%rsi), %esi
andl %r9d, %esi
movswl (%r10,%rsi,2), %esi
shrl $0x6, %esi
movw %si, 0x22(%rdx,%rcx)
addl $0x1000, %ebx           # imm = 0x1000
movw %bx, 0x1e(%rdx,%rcx)
movabsq $-0xffffffdfffe2, %rsi  # imm = 0xFFFF00000020001E
movq %rsi, 0x24(%rdx,%rcx)
leaq (%rax,%rax,2), %rsi
shlq $0x2, %rsi
addq 0xa9791(%rip), %rsi     # 0xd0fb0
movl $0x3, %edx
callq 0x6110e
movq (%r15,%r14,8), %rax
movl (%rax), %esi
movl 0x4(%rax), %edx
movl $0x56, %edi
xorl %ecx, %ecx
movl $0x4, %r8d
popq %rbx
popq %r14
popq %r15
jmp 0x1c370
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: blastmark
void
blastmark(int i)
{
     int       j;

    #ifdef PLRSPRDEBUG
     if( isaplayersprite(i) ) {
          crashgame("messing w plrsprite at 33");
     }
    #endif

     switch( sprptr[i]->statnum ) {
     case GENEXPLODE2:
          break;
     default:
          return;
     }
     switch( sprptr[i]->picnum ) {
     case BARRELL:
     case 175:
          break;
     default:
          return;
     }

     j=jsinsertsprite(sprptr[i]->sectnum, 100);
     if( j != -1 ) {
          fillsprite(j,sprptr[i]->x,sprptr[i]->y,sectptr[sprptr[i]->sectnum]->floorz,0x00A2,
                     4,0,0,34,34,0,0,465,sprptr[i]->ang,0,0,
                 30L,i+4096,sprptr[i]->sectnum,100,0,0,-1);
     }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %edi, %ebx
callq 0x1eb81
testl %eax, %eax
je 0x2786d
leaq 0x691c1(%rip), %rdi     # 0x90a27
xorl %eax, %eax
callq 0x2eb88
movslq %ebx, %r14
leaq 0x1099b9(%rip), %r15    # 0x131230
movq (%r15,%r14,8), %rax
cmpw $0x321, 0x1a(%rax)      # imm = 0x321
jne 0x2795c
movzwl 0xe(%rax), %ecx
cmpl $0x383, %ecx            # imm = 0x383
je 0x2789f
cmpl $0xaf, %ecx
jne 0x2795c
movswl 0x18(%rax), %edi
movl $0x64, %esi
callq 0x1eac8
cmpw $-0x1, %ax
je 0x2795c
movswq %ax, %rcx
imulq $0x2c, %rcx, %rax
leaq 0x40626a(%rip), %rdx    # 0x42db30
leaq (%rdx,%rax), %rdi
movq (%r15,%r14,8), %rsi
movl (%rsi), %r8d
movl %r8d, (%rdx,%rax)
movl 0x4(%rsi), %r8d
movl %r8d, 0x4(%rdx,%rax)
movswq 0x18(%rsi), %r8
leaq 0x1d1946(%rip), %r9     # 0x1f9230
movq (%r9,%r8,8), %r8
movl 0x8(%r8), %r8d
movl %r8d, 0x8(%rdx,%rax)
movl $0x1d100a2, 0xc(%rdx,%rax) # imm = 0x1D100A2
movw $0x4, 0x10(%rdx,%rax)
movb $0x0, 0x12(%rdx,%rax)
movl $0x2222, 0x14(%rdx,%rax) # imm = 0x2222
movzwl 0x1c(%rsi), %esi
movw %si, 0x1c(%rdx,%rax)
addl $0x1000, %ebx           # imm = 0x1000
movw %bx, 0x1e(%rdx,%rax)
movabsq $0x1e00000000, %rsi     # imm = 0x1E00000000
movq %rsi, 0x20(%rdx,%rax)
leaq (%rcx,%rcx,2), %rsi
shlq $0x2, %rsi
addq 0xa966b(%rip), %rsi     # 0xd0fb0
movl $0xffff0000, 0x28(%rdx,%rax) # imm = 0xFFFF0000
movl $0x3, %edx
popq %rbx
popq %r14
popq %r15
jmp 0x6110e
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tekstat.c
// Function: dosectorflash
void
dosectorflash()
{
     switch( sectflash.step ) {
     case 0:
          break;
     case 1:
          sectptr[sectflash.sectnum]->visibility=0;
          sectflash.step=2;
          break;
     case 2:
          sectptr[sectflash.sectnum]->visibility=128;
          sectflash.step=3;
          break;
     case 3:
          sectptr[sectflash.sectnum]->visibility=0;
          sectflash.step=4;
          break;
     case 4:
          sectptr[sectflash.sectnum]->visibility=sectflash.ovis;
          sectflash.sectnum=0;
          sectflash.ovis=0;
          sectflash.step=0;
     }
}

// Assembly:
movl 0x20e8b5(%rip), %eax    # 0x23642c
decl %eax
cmpl $0x3, %eax
ja 0x27c20
leaq 0x688f7(%rip), %rcx     # 0x90480
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movswq 0x20e88e(%rip), %rax    # 0x236428
leaq 0x1d168f(%rip), %rcx    # 0x1f9230
movq (%rcx,%rax,8), %rax
movb $0x0, 0x20(%rax)
movl $0x2, %eax
jmp 0x27c1a
movswq 0x20e870(%rip), %rax    # 0x236428
leaq 0x1d1671(%rip), %rcx    # 0x1f9230
movq (%rcx,%rax,8), %rax
movb $0x0, 0x20(%rax)
movl $0x4, %eax
jmp 0x27c1a
movb 0x20e85c(%rip), %al     # 0x236430
movswq 0x20e84c(%rip), %rcx    # 0x236428
leaq 0x1d164d(%rip), %rdx    # 0x1f9230
movq (%rdx,%rcx,8), %rcx
movb %al, 0x20(%rcx)
movw $0x0, 0x20e835(%rip)    # 0x236428
movb $0x0, 0x20e836(%rip)    # 0x236430
xorl %eax, %eax
jmp 0x27c1a
movswq 0x20e822(%rip), %rax    # 0x236428
leaq 0x1d1623(%rip), %rcx    # 0x1f9230
movq (%rcx,%rax,8), %rax
movb $-0x80, 0x20(%rax)
movl $0x3, %eax
movl %eax, 0x20e80c(%rip)    # 0x23642c
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: tekoperatesector
void
tekoperatesector(short dasector)
{
     short          s;
     int            datag,i;

     s=dasector;
     datag=sectptr[s]->lotag;

     switch (datag) {
     case BOXELEVTAG:
     case PLATFORMELEVTAG:
     case BOXDELAYTAG:
     case PLATFORMDELAYTAG:
     case DOORUPTAG:          // a door that opens up
     case DOORDOWNTAG:
     case DOORSPLITHOR:
     case DOORSPLITVER:
     case PLATFORMDROPTAG:
          i=doorxref[s];
          if (i == -1) {
               crashgame("operatesector: invalid door reference for sector %d",s);
          }
          switch (doorptr[i]->state) {
          case D_NOTHING:
          case D_CLOSING:
          case D_CLOSEDOOR:
          case D_SHUTSOUND:
               doorptr[i]->state=D_OPENDOOR;
               break;
          default:
               if (datag != PLATFORMDROPTAG) {
                    doorptr[i]->state=D_CLOSEDOOR;
               }
               break;
          }
          break;
     case DOORFLOORTAG:
          floordoorptr[fdxref[s]]->state=DOOROPENING;
          playsound(S_FLOOROPEN,0,0,0,ST_IMMEDIATE);
          break;
     }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movslq %edi, %rax
leaq 0x1d10dd(%rip), %rcx    # 0x1f9230
movq (%rcx,%rax,8), %rcx
movzwl 0x22(%rcx), %ebx
leal -0x3e8(%rbx), %ecx
cmpl $0x7, %ecx
ja 0x281ae
movl $0xb9, %edx
btl %ecx, %edx
jb 0x281b6
cmpl $0x6, %ecx
jne 0x281ae
leaq 0x2ed7f4(%rip), %rcx    # 0x315970
movslq (%rcx,%rax,4), %rax
leaq 0x2f1aa9(%rip), %rcx    # 0x319c30
movq (%rcx,%rax,8), %rax
movl $0x1, (%rax)
movl $0x3f, %edi
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
movl $0x1, %r8d
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x1c370
leal -0x6(%rbx), %ecx
cmpl $0x4, %ecx
jae 0x281fc
leaq 0x302263(%rip), %rcx    # 0x32a420
movslq (%rcx,%rax,4), %r14
cmpq $-0x1, %r14
jne 0x281d8
movswl %di, %esi
leaq 0x68a8b(%rip), %rdi     # 0x90c5c
xorl %eax, %eax
callq 0x2eb88
leaq 0x2ed141(%rip), %rax    # 0x315320
movq (%rax,%r14,8), %rax
movl 0x4(%rax), %ecx
cmpl $0x6, %ecx
ja 0x28204
movl $0x55, %edx
btl %ecx, %edx
jae 0x28204
movl $0x1, 0x4(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
cmpl $0x3ef, %ebx            # imm = 0x3EF
je 0x281fc
movl $0x2, 0x4(%rax)
jmp 0x281fc
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: warpsprite
void
warpsprite(short spritenum)
{
     short dasectnum;

     dasectnum = sprite[spritenum].sectnum;
     warp(&sprite[spritenum].x,&sprite[spritenum].y,&sprite[spritenum].z,
          &sprite[spritenum].ang,&dasectnum);
     copybuf(&sprite[spritenum].x,&osprite[spritenum].x,3);
     changespritesect(spritenum,dasectnum);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movslq %edi, %rbx
imulq $0x2c, %rbx, %rax
leaq 0x403d6a(%rip), %rcx    # 0x42db30
leaq (%rcx,%rax), %r14
leaq (%rcx,%rax), %rsi
addq $0x4, %rsi
movzwl 0x14(%rsi), %edx
leaq 0xe(%rsp), %r15
movw %dx, (%r15)
leaq (%rcx,%rax), %rdx
addq $0x8, %rdx
movq %r14, %rdi
movq %r15, %r8
callq 0x2b952
leaq (%rbx,%rbx,2), %rsi
shlq $0x2, %rsi
addq 0xa71af(%rip), %rsi     # 0xd0fb0
movq %r14, %rdi
movl $0x3, %edx
callq 0x6110e
movswl (%r15), %esi
movl %ebx, %edi
callq 0x48b21
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: testneighborsectors
int
testneighborsectors(short sect1, short sect2)
{
     short i, startwall, num1, num2;

     num1 = sector[sect1].wallnum;
     num2 = sector[sect2].wallnum;

     // traverse walls of sector with fewest walls (for speed)
     if( num1 < num2 ) {
          startwall = sector[sect1].wallptr;
          for(i=num1-1;i>=0;i--)
               if (wall[i+startwall].nextsector == sect2)
                    return(1);
     }
     else {
          startwall = sector[sect2].wallptr;
          for(i=num2-1;i>=0;i--)
               if (wall[i+startwall].nextsector == sect1)
                    return(1);
     }
     return(0);
}

// Assembly:
movslq %edi, %rax
leaq (%rax,%rax,4), %r8
leaq 0x3caaaf(%rip), %rdx    # 0x3f48e0
movzwl 0x2(%rdx,%r8,8), %eax
movslq %esi, %rcx
leaq (%rcx,%rcx,4), %r9
movzwl 0x2(%rdx,%r9,8), %ecx
cmpw %cx, %ax
jge 0x29e7b
leaq (%rdx,%r8,8), %rcx
movswq (%rcx), %rcx
decq %rax
leaq 0x33fa75(%rip), %rdx    # 0x3698d0
testw %ax, %ax
js 0x29eb1
movl %eax, %edi
andl $0x7fff, %edi           # imm = 0x7FFF
addq %rcx, %rdi
shlq $0x5, %rdi
decq %rax
cmpw %si, 0xc(%rdx,%rdi)
jne 0x29e5b
jmp 0x29eab
leaq (%rdx,%r9,8), %rax
movswq (%rax), %rax
decq %rcx
leaq 0x33fa43(%rip), %rdx    # 0x3698d0
testw %cx, %cx
js 0x29eb1
movl %ecx, %esi
andl $0x7fff, %esi           # imm = 0x7FFF
addq %rax, %rsi
shlq $0x5, %rsi
decq %rcx
cmpw %di, 0xc(%rdx,%rsi)
jne 0x29e8d
movl $0x1, %eax
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: warp
void
warp(int *x, int *y, int *z, short *daang, short *dasector)
{
     short          startwall, endwall, s;
     int           i, j, dax, day;

     (void)daang;

     for( i=0; i<warpsectorcnt; i++ ) {
          if( warpsectorlist[i] == *dasector ) {
               j = sector[*dasector].hitag;
               do {
                    i++;
                    if (i >= warpsectorcnt) i = 0;
               } while( sector[warpsectorlist[i]].hitag != j );
               *dasector = warpsectorlist[i];
               break;
          }
     }

     // find center of sector
     startwall = sector[*dasector].wallptr;
     endwall = startwall+sector[*dasector].wallnum-1;
     dax = 0L, day = 0L;
     for( s=startwall; s<=endwall; s++ ) {
          dax += wall[s].x, day += wall[s].y;
          if( wall[s].nextsector >= 0 ) {
               i = s;
          }
     }
     *x = dax / (endwall-startwall+1);
     *y = day / (endwall-startwall+1);
     *z = sector[*dasector].floorz-(42<<8);

     updatesector(*x,*y,dasector);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rcx
leaq 0x10233e(%rip), %rax    # 0x12dca0
movswl (%rax), %eax
movzwl (%r8), %edx
testl %eax, %eax
jle 0x2b9c3
movswq %dx, %r11
movl %eax, %ebx
xorl %r9d, %r9d
leaq 0x1022a3(%rip), %r10    # 0x12dc20
cmpw %dx, (%r10,%r9,2)
je 0x2b98e
incq %r9
cmpq %r9, %rbx
jne 0x2b97d
jmp 0x2b9c3
leaq (%r11,%r11,4), %rdx
leaq 0x3c8f47(%rip), %r11    # 0x3f48e0
movzwl 0x24(%r11,%rdx,8), %ebx
xorl %ebp, %ebp
incl %r9d
cmpl %eax, %r9d
cmovgel %ebp, %r9d
movslq %r9d, %rdx
movswq (%r10,%rdx,2), %rdx
leaq (%rdx,%rdx,4), %r14
cmpw %bx, 0x24(%r11,%r14,8)
jne 0x2b9a1
movw %dx, (%r8)
movswq %dx, %rax
leaq (%rax,%rax,4), %rax
leaq 0x3c8f0e(%rip), %r10    # 0x3f48e0
movzwl (%r10,%rax,8), %ebx
movswl %bx, %edx
movzwl 0x2(%r10,%rax,8), %r11d
addw %dx, %r11w
decl %r11d
xorl %eax, %eax
movl $0x0, %r9d
cmpw %r11w, %dx
jg 0x2ba1a
xorl %r9d, %r9d
leaq 0x33ded1(%rip), %r14    # 0x3698d0
xorl %eax, %eax
movswq %bx, %r15
shlq $0x5, %r15
addl (%r14,%r15), %eax
addl 0x4(%r14,%r15), %r9d
incl %ebx
cmpw %r11w, %bx
jle 0x2ba01
movswl %r11w, %r11d
subl %edx, %r11d
incl %r11d
cltd
idivl %r11d
movl %eax, (%rdi)
movl %r9d, %eax
cltd
idivl %r11d
movl %eax, (%rsi)
movswq (%r8), %rax
leaq (%rax,%rax,4), %rax
movl $0xffffd600, %edx       # imm = 0xFFFFD600
addl 0x8(%r10,%rax,8), %edx
movl %edx, (%rcx)
movl (%rdi), %edi
movl (%rsi), %esi
movq %r8, %rdx
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x3873d
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: tekwarp
void
tekwarp(int *x, int *y, int *z, short *dasector)
{
     short          startwall, endwall, s;
     int           i, dax, day;

     // find center of sector
     startwall = sector[*dasector].wallptr;
     endwall = startwall+sector[*dasector].wallnum-1;
     dax = 0L, day = 0L;
     for( s=startwall; s<=endwall; s++ ) {
          dax += wall[s].x, day += wall[s].y;
          if( wall[s].nextsector >= 0 ) {
               i = s;
          }
     }
     *x = dax / (endwall-startwall+1);
     *y = day / (endwall-startwall+1);
     *z = sector[*dasector].floorz-(42<<8);

     updatesector(*x,*y,dasector);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r8
movswq (%rcx), %rax
leaq (%rax,%rax,4), %rax
leaq 0x3c8e70(%rip), %r10    # 0x3f48e0
movzwl (%r10,%rax,8), %ebx
movswl %bx, %edx
movzwl 0x2(%r10,%rax,8), %r11d
addw %dx, %r11w
decl %r11d
xorl %eax, %eax
movl $0x0, %r9d
cmpw %r11w, %dx
jg 0x2bab8
xorl %r9d, %r9d
leaq 0x33de33(%rip), %r14    # 0x3698d0
xorl %eax, %eax
movswq %bx, %r15
shlq $0x5, %r15
addl (%r14,%r15), %eax
addl 0x4(%r14,%r15), %r9d
incl %ebx
cmpw %r11w, %bx
jle 0x2ba9f
movswl %r11w, %r11d
subl %edx, %r11d
incl %r11d
cltd
idivl %r11d
movl %eax, (%rdi)
movl %r9d, %eax
cltd
idivl %r11d
movl %eax, (%rsi)
movswq (%rcx), %rax
leaq (%rax,%rax,4), %rax
movl $0xffffd600, %edx       # imm = 0xFFFFD600
addl 0x8(%r10,%rax,8), %edx
movl %edx, (%r8)
movl (%rdi), %edi
movl (%rsi), %esi
movq %rcx, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x3873d
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: krand_intercept
int
krand_intercept(char *stg)
{
     if (dbgflag) {
          if (dbgcolumn > 80) {
               fprintf(dbgfp,"\n");
               dbgcolumn=0;
          }
          else {
               fprintf(dbgfp,"%s(%-9d) ",stg,randomseed);
               dbgcolumn+=20;
          }
     }
     return(krand());
}

// Assembly:
leaq 0xb74cb(%rip), %rax     # 0xe45e4
cmpl $0x0, (%rax)
je 0x4d1e8
pushq %rbx
leaq 0xb734e(%rip), %rbx     # 0xe4478
cmpl $0x51, (%rbx)
leaq 0xb734c(%rip), %rax     # 0xe4480
movq (%rax), %rax
jl 0x2d14a
movl $0xa, %edi
movq %rax, %rsi
callq 0x8cb0
xorl %eax, %eax
jmp 0x2d16c
movq %rdi, %rdx
leaq 0x5ba2b4(%rip), %rcx    # 0x5e7408
movl (%rcx), %ecx
leaq 0x63bc1(%rip), %rsi     # 0x90d1e
movq %rax, %rdi
xorl %eax, %eax
callq 0x8290
movl (%rbx), %eax
addl $0x14, %eax
movl %eax, (%rbx)
popq %rbx
jmp 0x4d1e8
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: tekdoanimpic
void
tekdoanimpic(void)
{
     short pic;
     int  i,n;

     n=numanimates;
     for (i=0 ; i < n ; i++) {
          if (lockclock < animpicptr[i]->nextclock) {
               continue;
          }
          if (animpicptr[i]->frames > 0) {
               if (--animpicptr[i]->frames > 0) {
                    pic=*animpicptr[i]->pic;
                    pic++;
                    *animpicptr[i]->pic=pic;
                    animpicptr[i]->nextclock=lockclock+animpicptr[i]->tics;
               }
          }
          else if (animpicptr[i]->frames < 0) {
               if (++animpicptr[i]->frames < 0) {
                    pic=*animpicptr[i]->pic;
                    pic--;
                    *animpicptr[i]->pic=pic;
                    animpicptr[i]->nextclock=lockclock+animpicptr[i]->tics;
               }
          }
          else {
               numanimates--;
               if (numanimates > 0) {
                    memmove(animpicptr[i],animpicptr[numanimates],
                         sizeof(struct animpic));
                    memset(animpicptr[numanimates],0,sizeof(struct animpic));
               }
          }
     }
}

// Assembly:
movslq 0x30060c(%rip), %rax    # 0x32e424
testq %rax, %rax
jle 0x2dee6
shlq $0x3, %rax
xorl %ecx, %ecx
leaq 0xb665a(%rip), %rdx     # 0xe4488
leaq 0x3008fb(%rip), %rsi    # 0x32e730
xorps %xmm0, %xmm0
movl (%rdx), %r8d
movq (%rcx,%rsi), %rdi
cmpl 0x14(%rdi), %r8d
jl 0x2deca
movzwl (%rdi), %r8d
testw %r8w, %r8w
jle 0x2de7f
leal -0x1(%r8), %r9d
movw %r9w, (%rdi)
cmpw $0x1, %r8w
je 0x2deca
movq (%rcx,%rsi), %rdi
movq 0x8(%rdi), %rdi
incw (%rdi)
movq (%rcx,%rsi), %rdi
movswl 0x10(%rdi), %r8d
addl (%rdx), %r8d
movl %r8d, 0x14(%rdi)
jmp 0x2deca
js 0x2dec0
movl 0x30059c(%rip), %r9d    # 0x32e424
leal -0x1(%r9), %r8d
movl %r8d, 0x300591(%rip)    # 0x32e424
cmpl $0x2, %r9d
jl 0x2deca
movl %r8d, %r8d
movq (%rsi,%r8,8), %r9
movups (%r9), %xmm1
movq 0x10(%r9), %r9
movq %r9, 0x10(%rdi)
movups %xmm1, (%rdi)
movq (%rsi,%r8,8), %rdi
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
jmp 0x2deca
incw %r8w
movw %r8w, (%rdi)
jne 0x2ded9
addq $0x8, %rcx
cmpq %rcx, %rax
jne 0x2de38
jmp 0x2dee6
movq (%rcx,%rsi), %rdi
movq 0x8(%rdi), %rdi
decw (%rdi)
jmp 0x2de6d
retq
// File: /workspace/github_c_makefile_star2_O3/jonof[P]jftekwar/src/tektag.c
// Function: tekdodelayfuncs
void
tekdodelayfuncs(void)
{
     int  i,n,p;

     n=numdelayfuncs;
     for (i=0 ; i < n ; i++) {
          if (delayfuncptr[i]->func == NULL) {
               continue;
          }
          delayfuncptr[i]->tics-=TICSPERFRAME;
          if (delayfuncptr[i]->tics <= 0) {
               p=delayfuncptr[i]->parm;
               (*delayfuncptr[i]->func)(p);
               memmove(delayfuncptr[i],delayfuncptr[numdelayfuncs-1],
                    sizeof(struct delayfunc));
                    memset(delayfuncptr[numdelayfuncs-1],0,
                    sizeof(struct delayfunc));
               numdelayfuncs--;
          }
     }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movswq 0x30093c(%rip), %rbx    # 0x32e830
testq %rbx, %rbx
jle 0x2df5a
shlq $0x3, %rbx
xorl %r14d, %r14d
leaq 0x300b39(%rip), %r15    # 0x32ea40
movq (%r14,%r15), %rax
cmpq $0x0, (%rax)
je 0x2df51
addl $-0x3, 0x8(%rax)
movq (%r14,%r15), %rax
cmpl $0x0, 0x8(%rax)
jg 0x2df51
movswl 0xc(%rax), %edi
callq *(%rax)
movq (%r14,%r15), %rax
movswq 0x3008ff(%rip), %rcx    # 0x32e830
movq -0x8(%r15,%rcx,8), %rdx
movups (%rdx), %xmm0
movups %xmm0, (%rax)
movq -0x8(%r15,%rcx,8), %rax
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
leal -0x1(%rcx), %eax
movw %ax, 0x3008df(%rip)     # 0x32e830
addq $0x8, %r14
cmpq %r14, %rbx
jne 0x2df07
popq %rbx
popq %r14
popq %r15
retq