// File: /workspace/github_cpp_makefile_star2_O1/matallui[P]nibble-curses/src/CNibbles.cpp
// Function: CNibbles::PresentLevel()
void CNibbles::PresentLevel ( void )
{
  bkgd ( COLOR_PAIR (1) );
  attrset ( COLOR_PAIR(2) );
  for ( int j = 0; j < m_maxCols; j++ )
  {
    mvaddch ( 0, j, '*' );
    mvaddch ( m_maxLines-1, j, '*' );
  }
  for ( int i = 0; i < m_maxLines; i++ )
  {
    mvaddch ( i, 0, '*' );
    mvaddch ( i, m_maxCols-1, '*' );
  }
  
  attrset ( COLOR_PAIR(3) );
  move ( 15, 39 );
  attron ( A_BOLD );
  printw ( "LEVEL %d / 10", m_level );
  attroff ( A_BOLD );
  if ( m_mode == 3 )
  {
    char buffer[3];
    bzero ( buffer, 3 );
    if (  (m_master && m_snakes[0]->getLives() ) || ( !m_master && !m_snakes[0]->getLives() ) )
    {
      move ( 19, 32 );
      printw ( "* Press SPACE to continue... *" );
      refresh();
      nodelay( stdscr, false );
      while ( getch() != ' ' );
      nodelay( stdscr, true );
      sprintf ( buffer, "GO" );
      if ( ! m_socket->Send ( buffer, 3 ) )		throw CException( "Problems with communication." );
      bzero ( buffer, 3 );
      if ( ! m_socket->Recv ( buffer, 3 ) )		throw CException( "Problems with communication." );
      if ( buffer[0] != 'O' || buffer[1] != 'K' )	throw CException( "Problems with communication." );
    }
    else
    {
      move ( 21, 32 );
      printw ( "* Waiting for answer... *" );
      refresh();
      if ( ! m_socket->Recv ( buffer, 3 ) )		throw CException( "Problems with communication." );
      if ( buffer[0] !='G' || buffer[1] != 'O' )	throw CException( "Problems with communication." );
      sprintf ( buffer, "OK" );
      if ( ! m_socket->Send ( buffer, 3 ) )		throw CException( "Problems with communication." );
    }
    flushinp();
  }
  else
  {
    move ( 19, 32 );
    printw ( "* Press SPACE to continue... *" );
    refresh();
    nodelay( stdscr, false );
    while ( getch() != ' ' );
    nodelay( stdscr, true );
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
movq 0x58c7(%rip), %r15      # 0xcfd0
movq (%r15), %rdi
movl $0x100, %esi            # imm = 0x100
callq 0x33d0
movq (%r15), %rdi
movl $0x200, %esi            # imm = 0x200
callq 0x32a0
cmpl $0x0, 0x4(%rbx)
jle 0x7775
xorl %r14d, %r14d
movq (%r15), %rdi
xorl %esi, %esi
movl %r14d, %edx
callq 0x3290
cmpl $-0x1, %eax
je 0x774b
movq (%r15), %rdi
movl $0x2a, %esi
callq 0x30c0
movq (%r15), %rdi
movl (%rbx), %esi
decl %esi
movl %r14d, %edx
callq 0x3290
cmpl $-0x1, %eax
je 0x776c
movq (%r15), %rdi
movl $0x2a, %esi
callq 0x30c0
incl %r14d
cmpl 0x4(%rbx), %r14d
jl 0x772c
cmpl $0x0, (%rbx)
jle 0x77c6
xorl %r14d, %r14d
movq (%r15), %rdi
movl %r14d, %esi
xorl %edx, %edx
callq 0x3290
cmpl $-0x1, %eax
je 0x779c
movq (%r15), %rdi
movl $0x2a, %esi
callq 0x30c0
movq (%r15), %rdi
movl 0x4(%rbx), %edx
decl %edx
movl %r14d, %esi
callq 0x3290
cmpl $-0x1, %eax
je 0x77be
movq (%r15), %rdi
movl $0x2a, %esi
callq 0x30c0
incl %r14d
cmpl (%rbx), %r14d
jl 0x777d
movq (%r15), %rdi
movl $0x300, %esi            # imm = 0x300
callq 0x32a0
movl $0xf, %edi
movl $0x27, %esi
callq 0x31c0
movq (%r15), %rdi
movl $0x200000, %esi         # imm = 0x200000
xorl %edx, %edx
callq 0x3150
movl 0x8(%rbx), %esi
leaq 0x1bfd(%rip), %rdi      # 0x93f8
xorl %eax, %eax
callq 0x3270
movq (%r15), %rdi
movl $0x200000, %esi         # imm = 0x200000
xorl %edx, %edx
callq 0x3330
cmpl $0x3, 0x14(%rbx)
jne 0x7932
movb $0x0, -0x22(%rbp)
movw $0x0, -0x24(%rbp)
cmpb $0x1, 0x18(%rbx)
jne 0x783f
movq 0x30(%rbx), %rax
movq (%rax), %rdi
callq 0x3dc2
testl %eax, %eax
jne 0x7984
cmpb $0x0, 0x18(%rbx)
jne 0x7859
movq 0x30(%rbx), %rax
movq (%rax), %rdi
callq 0x3dc2
testl %eax, %eax
je 0x7984
movl $0x15, %edi
movl $0x20, %esi
callq 0x31c0
leaq 0x1bb9(%rip), %rdi      # 0x9428
xorl %eax, %eax
callq 0x3270
callq 0x33e0
movq 0x48(%rbx), %rdi
leaq -0x48(%rbp), %rdx
movl $0x3, (%rdx)
movq (%rdi), %rax
leaq -0x24(%rbp), %rsi
callq *0x28(%rax)
testb %al, %al
je 0x7a42
cmpb $0x47, -0x24(%rbp)
jne 0x7a9c
cmpb $0x4f, -0x23(%rbp)
jne 0x7a9c
leaq -0x24(%rbp), %rsi
movb $0x0, 0x2(%rsi)
movw $0x4b4f, (%rsi)         # imm = 0x4B4F
movq 0x48(%rbx), %rdi
leaq -0x48(%rbp), %rdx
movl $0x3, (%rdx)
movq (%rdi), %rax
callq *0x20(%rax)
testb %al, %al
jne 0x7a30
movl $0x20, %edi
callq 0x3160
movq %rax, %rbx
leaq -0x38(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x1ae6(%rip), %rsi      # 0x93db
leaq 0x1afb(%rip), %rdx      # 0x93f7
leaq -0x48(%rbp), %rdi
callq 0x376a
movb $0x1, %r15b
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x35f8
xorl %r15d, %r15d
leaq 0x545a(%rip), %rsi      # 0xcd78
leaq 0xc17(%rip), %rdx       # 0x853c
movq %rbx, %rdi
callq 0x33f0
jmp 0x7bfc
movl $0x13, %edi
movl $0x20, %esi
callq 0x31c0
leaq 0x1abe(%rip), %rdi      # 0x9406
xorl %eax, %eax
callq 0x3270
callq 0x33e0
movq (%r15), %rdi
xorl %esi, %esi
callq 0x3190
movq (%r15), %rdi
callq 0x3110
cmpl $0x20, %eax
jne 0x795e
movq (%r15), %rdi
movl $0x1, %esi
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x3190
movl $0x13, %edi
movl $0x20, %esi
callq 0x31c0
leaq 0x1a6c(%rip), %rdi      # 0x9406
xorl %eax, %eax
callq 0x3270
callq 0x33e0
movq (%r15), %rdi
xorl %esi, %esi
callq 0x3190
movq (%r15), %rdi
callq 0x3110
cmpl $0x20, %eax
jne 0x79b0
movq (%r15), %rdi
movl $0x1, %esi
callq 0x3190
leaq -0x24(%rbp), %rsi
movw $0x4f47, (%rsi)         # imm = 0x4F47
movb $0x0, 0x2(%rsi)
movq 0x48(%rbx), %rdi
leaq -0x48(%rbp), %rdx
movl $0x3, (%rdx)
movq (%rdi), %rax
callq *0x20(%rax)
testb %al, %al
je 0x7af6
leaq -0x24(%rbp), %rsi
movb $0x0, 0x2(%rsi)
movw $0x0, (%rsi)
movq 0x48(%rbx), %rdi
leaq -0x48(%rbp), %rdx
movl $0x3, (%rdx)
movq (%rdi), %rax
callq *0x28(%rax)
testb %al, %al
je 0x7b50
cmpb $0x4f, -0x24(%rbp)
jne 0x7ba7
cmpb $0x4b, -0x23(%rbp)
jne 0x7ba7
callq 0x3140
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl $0x20, %edi
callq 0x3160
movq %rax, %rbx
leaq -0x38(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x197c(%rip), %rsi      # 0x93db
leaq 0x1991(%rip), %rdx      # 0x93f7
leaq -0x48(%rbp), %rdi
callq 0x376a
movb $0x1, %r15b
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x35f8
xorl %r15d, %r15d
leaq 0x52f0(%rip), %rsi      # 0xcd78
leaq 0xaad(%rip), %rdx       # 0x853c
movq %rbx, %rdi
callq 0x33f0
jmp 0x7bfc
movl $0x20, %edi
callq 0x3160
movq %rax, %rbx
leaq -0x38(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x1922(%rip), %rsi      # 0x93db
leaq 0x1937(%rip), %rdx      # 0x93f7
leaq -0x48(%rbp), %rdi
callq 0x376a
movb $0x1, %r15b
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x35f8
xorl %r15d, %r15d
leaq 0x5296(%rip), %rsi      # 0xcd78
leaq 0xa53(%rip), %rdx       # 0x853c
movq %rbx, %rdi
callq 0x33f0
jmp 0x7bfc
movl $0x20, %edi
callq 0x3160
movq %rax, %rbx
leaq -0x38(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x18c8(%rip), %rsi      # 0x93db
leaq 0x18dd(%rip), %rdx      # 0x93f7
leaq -0x48(%rbp), %rdi
callq 0x376a
movb $0x1, %r15b
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x35f8
xorl %r15d, %r15d
leaq 0x523c(%rip), %rsi      # 0xcd78
leaq 0x9f9(%rip), %rdx       # 0x853c
movq %rbx, %rdi
callq 0x33f0
jmp 0x7bfc
movl $0x20, %edi
callq 0x3160
movq %rax, %rbx
leaq -0x38(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x186e(%rip), %rsi      # 0x93db
leaq 0x1883(%rip), %rdx      # 0x93f7
leaq -0x48(%rbp), %rdi
callq 0x376a
movb $0x1, %r15b
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x35f8
xorl %r15d, %r15d
leaq 0x51e2(%rip), %rsi      # 0xcd78
leaq 0x99f(%rip), %rdx       # 0x853c
movq %rbx, %rdi
callq 0x33f0
jmp 0x7bfc
movl $0x20, %edi
callq 0x3160
movq %rax, %rbx
leaq -0x38(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x1817(%rip), %rsi      # 0x93db
leaq 0x182c(%rip), %rdx      # 0x93f7
leaq -0x48(%rbp), %rdi
callq 0x376a
movb $0x1, %r15b
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x35f8
xorl %r15d, %r15d
leaq 0x518b(%rip), %rsi      # 0xcd78
leaq 0x948(%rip), %rdx       # 0x853c
movq %rbx, %rdi
callq 0x33f0
jmp 0x7c10
jmp 0x7c2a
jmp 0x7c10
jmp 0x7c2a
jmp 0x7c10
jmp 0x7c2a
jmp 0x7c10
jmp 0x7c2a
jmp 0x7c10
jmp 0x7c2a
movq %rax, %r14
movq -0x48(%rbp), %rdi
cmpq %r12, %rdi
je 0x7c30
movq -0x38(%rbp), %rsi
incq %rsi
callq 0x3280
jmp 0x7c30
movq %rax, %r14
movb $0x1, %r15b
testb %r15b, %r15b
je 0x7c3d
movq %rbx, %rdi
callq 0x31e0
movq %r14, %rdi
callq 0x3400
nop