// File: /workspace/github_cpp_makefile_star2_O3/therealgymmy[P]HelicopterGame/src/helicopter.cpp
// Function: Helicopter::draw(XInfo*)
void Helicopter::draw (XInfo *xinfo) {
    if (blink_ > 0) {
        --blink_;
        if (!(blink_ & 0x8)) {
            return;
        }
    }
    end_.draw<attr::BLACK>(xinfo,
                           x_ / Draw::ScaleX,
                           (y_ + (HeliHead::h() - HeliEnd::h()) / 2) / Draw::ScaleY);

    mid_.draw<attr::WHITE>(xinfo,
                           (x_ + HeliEnd::w()) / Draw::ScaleX,
                           (y_ + (HeliHead::h() - HeliMid::h()) / 2) / Draw::ScaleY);

    head_.draw<attr::WHITE>(xinfo,
                            (x_ + HeliEnd::w() + HeliMid::w()) / Draw::ScaleX,
                            y_ / Draw::ScaleY);

    top_.draw<attr::WHITE>(xinfo,
                           (x_ + HeliEnd::w() + HeliMid::w() - (HeliTop::w() - HeliHead::w()) / 2) / Draw::ScaleX,
                           (y_ - HeliTop::h()) / Draw::ScaleY);

    headin_.draw<attr::GREEN>(xinfo,
                              (x_ + HeliEnd::w() + HeliMid::w() + (HeliHead::w() - HeliHeadIn::w()) / 2) / Draw::ScaleX,
                              (y_ + (HeliHead::h() - HeliHeadIn::h()) / 2) / Draw::ScaleY);

    endin_.draw<attr::RED>(xinfo,
                           (x_ + (HeliEnd::w() - HeliEndIn::w()) / 2) / Draw::ScaleX,
                           (y_ + (HeliHead::h() - HeliEndIn::h()) / 2) / Draw::ScaleY);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movl 0x24(%rdi), %eax
testl %eax, %eax
jle 0x49a7
decl %eax
movl %eax, 0x24(%r14)
testb $0x8, %al
jne 0x49a7
addq $0x8, %rsp
jmp 0x4c95
cvtsi2sdl 0x14(%r14), %xmm0
leaq 0x4854(%rip), %r13      # 0x9208
movsd (%r13), %xmm1
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
movl 0x18(%r14), %eax
addl $0x3c, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
leaq 0x4839(%rip), %rbp      # 0x9210
movsd (%rbp), %xmm2
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %r8d
movq (%rbx), %rdi
movq 0xa0(%rbx), %rsi
movsd 0x18a9(%rip), %xmm0     # 0x62a0
movapd %xmm0, %xmm3
divsd %xmm1, %xmm3
cvttsd2si %xmm3, %r9
movq 0xa8(%rbx), %rdx
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %rax
subq $0x8, %rsp
movl $0x5a00, %r12d          # imm = 0x5A00
xorl %r15d, %r15d
pushq %r12
pushq %r15
pushq %rax
callq 0x2170
addq $0x20, %rsp
movl 0x14(%r14), %eax
addl $0x50, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%r13), %xmm1
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
movl 0x18(%r14), %eax
addl $0x5a, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%rbp), %xmm2
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %r8d
movq (%rbx), %rdi
movq 0xa0(%rbx), %rsi
movq 0xb0(%rbx), %rdx
movsd 0x1828(%rip), %xmm0     # 0x62a8
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %r9
movsd 0x181f(%rip), %xmm0     # 0x62b0
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %rax
subq $0x8, %rsp
pushq %rax
callq 0x20f0
addq $0x10, %rsp
movl $0xc8, %eax
addl 0x14(%r14), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%r13), %xmm1
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
xorps %xmm0, %xmm0
cvtsi2sdl 0x18(%r14), %xmm0
movsd (%rbp), %xmm2
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %r8d
movq (%rbx), %rdi
movq 0xa0(%rbx), %rsi
movq 0xb0(%rbx), %rdx
movsd 0x17c2(%rip), %xmm0     # 0x62b8
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %r9
movsd 0x17b9(%rip), %xmm0     # 0x62c0
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %rax
subq $0x8, %rsp
pushq %r12
pushq %r15
pushq %rax
callq 0x2170
addq $0x20, %rsp
movl $0x8c, %eax
addl 0x14(%r14), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%r13), %xmm1
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
movl 0x18(%r14), %eax
addl $-0x14, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%rbp), %xmm2
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %r8d
movq (%rbx), %rdi
movq 0xa0(%rbx), %rsi
movsd 0x175a(%rip), %xmm0     # 0x62c8
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %r9
movq 0xb0(%rbx), %rdx
movsd 0x172a(%rip), %xmm0     # 0x62b0
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %rax
subq $0x8, %rsp
pushq %rax
callq 0x20f0
addq $0x10, %rsp
movl $0xd2, %eax
addl 0x14(%r14), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%r13), %xmm1
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
movl 0x18(%r14), %eax
addl $0xa, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%rbp), %xmm2
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %r8d
movq (%rbx), %rdi
movq 0xa0(%rbx), %rsi
movq 0xc0(%rbx), %rdx
movsd 0x16e0(%rip), %xmm0     # 0x62d0
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %r9
movsd 0x16d7(%rip), %xmm0     # 0x62d8
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %rax
subq $0x8, %rsp
pushq %r12
pushq %r15
pushq %rax
callq 0x22e0
addq $0x20, %rsp
movl 0x14(%r14), %eax
addl $0xa, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%r13), %xmm1
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
movl 0x18(%r14), %eax
addl $0x46, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd (%rbp), %xmm2
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %r8d
movq (%rbx), %rdi
movq 0xa0(%rbx), %rsi
movsd 0x167a(%rip), %xmm0     # 0x62e0
movapd %xmm0, %xmm3
divsd %xmm1, %xmm3
cvttsd2si %xmm3, %r9
movq 0xd0(%rbx), %rdx
divsd %xmm2, %xmm0
cvttsd2si %xmm0, %rax
subq $0x8, %rsp
pushq %r12
pushq %r15
pushq %rax
callq 0x22e0
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq