// File: /workspace/github_c_makefile_star2_O3/hyc[P]trek73c/trekx.c
// Function: Druse
void Druse()
{
  int i, charge;

  sprintf(scrstr,"%s: Chekov, drop shields ...", Name);
  SEndln();
  if (Ct[0]) {
    sprintf(scrstr,"Spock: %s, the %ss are not that stupid.",
      Title, Enemy);
    SEndln();
    return;
  }
  waddstr(Cmdwin,"   Transfer power to [engines or phasers]: ");
  mygetstr(Cmdwin,scrstr,true);
  if (!scrstr[0]) {
    ChWhat();
    return;
  }
  charge = (-10);
  if (scrstr[0] == 'e' || scrstr[0] == 'E') {
    Objects[0]->Fuel+=10;
    if (Objects[0]->Fuel > Ships[0]->Fcap)
      Objects[0]->Fuel = Ships[0]->Fcap;
  } else if (scrstr[0] == 'p' || scrstr[0] == 'P')
    charge = 10;
  else {
    ChWhat();
    return;
  }
  for (i=0; i<4; i++)
    Ships[0]->Sdrns[i] = 0;
  for (i=0; i<Phasers; i++)
    Ships[0]->PCrts[i] = charge;
  Ct[0] = 1;
}

// Assembly:
pushq %rbx
movq 0x9e41(%rip), %rdx      # 0x135c8
leaq 0x9d22(%rip), %rbx      # 0x134b0
leaq 0x5826(%rip), %rsi      # 0xefbb
movq %rbx, %rdi
xorl %eax, %eax
callq 0x21a0
movq 0xa252(%rip), %rdi      # 0x139f8
movq %rbx, %rsi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x2210
callq 0x3d76
cmpb $0x0, 0x9e25(%rip)      # 0x135e4
je 0x9801
movq 0x9e10(%rip), %rdx      # 0x135d8
movq 0xa1b1(%rip), %rcx      # 0x13980
leaq 0x9cda(%rip), %rbx      # 0x134b0
leaq 0x57fb(%rip), %rsi      # 0xefd8
movq %rbx, %rdi
xorl %eax, %eax
callq 0x21a0
movq 0xa20a(%rip), %rdi      # 0x139f8
movq %rbx, %rsi
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x2210
popq %rbx
jmp 0x3d76
movq 0xa1f0(%rip), %rdi      # 0x139f8
leaq 0x57f1(%rip), %rsi      # 0xf000
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x2210
movq 0xa1d8(%rip), %rdi      # 0x139f8
leaq 0x9c89(%rip), %rsi      # 0x134b0
movl $0x1, %edx
callq 0x249f
movzbl 0x9c78(%rip), %eax      # 0x134b0
testl %eax, %eax
je 0x985a
andl $-0x21, %eax
cmpl $0x45, %eax
je 0x9860
cmpl $0x50, %eax
jne 0x985a
movsd 0x38df(%rip), %xmm0     # 0xd130
movq 0xa138(%rip), %rax      # 0x13990
jmp 0x989b
popq %rbx
jmp 0x7b97
movq 0x9d89(%rip), %rcx      # 0x135f0
movsd 0x20(%rcx), %xmm2
addsd 0x38bc(%rip), %xmm2     # 0xd130
movsd %xmm2, 0x20(%rcx)
movq 0xa110(%rip), %rax      # 0x13990
movzbl 0x18(%rax), %edx
cvtsi2sd %edx, %xmm1
movsd 0x3a08(%rip), %xmm0     # 0xd298
ucomisd %xmm1, %xmm2
jbe 0x989b
movsd %xmm1, 0x20(%rcx)
xorpd %xmm1, %xmm1
movupd %xmm1, 0x90(%rax)
movupd %xmm1, 0x80(%rax)
movzbl 0x990a(%rip), %ecx      # 0x131c0
testq %rcx, %rcx
je 0x9958
movq %rcx, %rdx
decq %rdx
movq %rdx, %xmm1
pshufd $0x44, %xmm1, %xmm1     # xmm1 = xmm1[0,1,0,1]
leal 0x8(,%rcx,8), %ecx
andl $-0x10, %ecx
movdqa 0x372f(%rip), %xmm2     # 0xd010
xorl %edx, %edx
movdqa 0x3735(%rip), %xmm3     # 0xd020
pxor %xmm3, %xmm1
pcmpeqd %xmm4, %xmm4
movdqa 0x3745(%rip), %xmm5     # 0xd040
movdqa %xmm2, %xmm6
pxor %xmm3, %xmm6
movdqa %xmm6, %xmm7
pcmpgtd %xmm1, %xmm7
pcmpeqd %xmm1, %xmm6
pshufd $0xf5, %xmm6, %xmm8     # xmm8 = xmm6[1,1,3,3]
pand %xmm7, %xmm8
pshufd $0xf5, %xmm7, %xmm6     # xmm6 = xmm7[1,1,3,3]
por %xmm8, %xmm6
movd %xmm6, %esi
notl %esi
testb $0x1, %sil
je 0x9936
movsd %xmm0, 0x40(%rax,%rdx)
pxor %xmm4, %xmm6
pextrw $0x4, %xmm6, %esi
testb $0x1, %sil
je 0x994b
movsd %xmm0, 0x48(%rax,%rdx)
paddq %xmm5, %xmm2
addq $0x10, %rdx
cmpq %rdx, %rcx
jne 0x98fb
movb $0x1, 0x9c85(%rip)      # 0x135e4
popq %rbx
retq