// File: /workspace/github_cpp_makefile_star2_O2/hobbitsyfeet[P]Turn/chart.cc
// Function: Chart::displayRange(int, int, int)
void Chart::displayRange(int centrePosX,int centrePosY, int radius){

  vector<vector<container> >::iterator row;
  vector<container>::iterator col;
  int dist;
  for(row = world.begin(); row < world.end() ; row++){
    for(col = row->begin(); col < row->end(); col++){
      dist = sqrt( ( (col->getPosX() - centrePosX)*(col->getPosX() - centrePosX) )
		   + 	 ( col->getPosY() - centrePosY)*(col->getPosY() - centrePosY) );



      if(getFogOfWar()){
	if(dist <= radius){
	  if(centrePosX == col->getPosX() && centrePosY == col->getPosY()){
	    cout<<"P ";
    }
    else if(col->checkAvailable() == true && canEnter( col->getPosX(),col->getPosY() ) == true){
      cout<<"p ";
    }
	  else{
	    if(col->getGeoType()=='-' || col->getGeoType() =='O')
	      cout<<' ';
	    else
	      col->displayType();
	    cout<<' ';
	  }
	}
	else
	  cout<<"- ";
      }
      else{
	if(centrePosX == col->getPosX() && centrePosY == col->getPosY())
	  cout<<"P ";

	else{
	  if(col->getGeoType()=='-' || col->getGeoType() =='O')
	    cout<<"  ";
	  else{
	    col->displayType();
	    cout<<' ';
	  }
	}
      }
    }
    cout<<endl;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %ecx, -0x44(%rbp)
movl %edx, %r12d
movl %esi, %r13d
movq %rdi, -0x40(%rbp)
movq (%rdi), %r14
movq 0x7866(%rip), %r15      # 0xdfd0
movl %esi, -0x30(%rbp)
movl %edx, -0x2c(%rbp)
movq -0x40(%rbp), %rax
cmpq 0x8(%rax), %r14
jae 0x6915
movq (%r14), %rbx
movq %r14, -0x38(%rbp)
cmpq 0x8(%r14), %rbx
jae 0x6904
movq -0x40(%rbp), %rax
cmpb $0x1, 0x38(%rax)
jne 0x67dd
movslq 0x4(%rbx), %r14
movl %r14d, %eax
subl %r12d, %eax
imull %eax, %eax
movslq (%rbx), %r15
movl %r15d, %ecx
subl %r13d, %ecx
imull %ecx, %ecx
addl %eax, %ecx
cvtsi2sd %ecx, %xmm0
sqrtsd %xmm0, %xmm0
cvttsd2si %xmm0, %eax
cmpl -0x44(%rbp), %eax
jle 0x681a
movq 0x7804(%rip), %r15      # 0xdfd0
movq %r15, %rdi
leaq 0x2f4b(%rip), %rsi      # 0x9721
callq 0x21c0
jmp 0x6848
cmpl %r13d, (%rbx)
jne 0x67f4
cmpl %r12d, 0x4(%rbx)
jne 0x67f4
movq %r15, %rdi
leaq 0x2f2c(%rip), %rsi      # 0x971e
jmp 0x6810
movzbl 0x9(%rbx), %eax
cmpl $0x4f, %eax
je 0x6806
cmpl $0x2d, %eax
jne 0x688e
movq %r15, %rdi
leaq 0x2f0b(%rip), %rsi      # 0x971b
callq 0x21c0
jmp 0x68fb
movl %r15d, %eax
xorl %r13d, %eax
movl %r14d, %ecx
xorl %r12d, %ecx
orl %eax, %ecx
jne 0x6851
movq 0x779f(%rip), %r15      # 0xdfd0
movq %r15, %rdi
leaq 0x2ee3(%rip), %rsi      # 0x971e
callq 0x21c0
movl -0x2c(%rbp), %r12d
movl -0x30(%rbp), %r13d
movq -0x38(%rbp), %r14
jmp 0x68fb
movq %rbx, %rdi
callq 0x6664
testb %al, %al
je 0x68a3
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
negq %r14
imulq $0x18, %r14, %rcx
movq (%rax,%rcx), %rax
imulq $0x30, %r15, %rcx
cmpb $0x1, -0x28(%rax,%rcx)
jne 0x68a3
movq 0x774e(%rip), %r15      # 0xdfd0
movq %r15, %rdi
leaq 0x2a93(%rip), %rsi      # 0x931f
jmp 0x683b
movq %rbx, %rdi
callq 0x672c
movq %r15, %rdi
pushq $0x20
popq %rsi
callq 0x2200
jmp 0x68fb
movzbl 0x9(%rbx), %eax
cmpl $0x4f, %eax
je 0x68b1
cmpl $0x2d, %eax
jne 0x68d1
movq 0x7718(%rip), %r15      # 0xdfd0
movq %r15, %rdi
pushq $0x20
popq %r13
movl %r13d, %esi
callq 0x2200
movl -0x2c(%rbp), %r12d
movq -0x38(%rbp), %r14
jmp 0x68ec
movq %rbx, %rdi
callq 0x672c
movl -0x2c(%rbp), %r12d
movq -0x38(%rbp), %r14
movq 0x76e8(%rip), %r15      # 0xdfd0
pushq $0x20
popq %r13
movq %r15, %rdi
movl %r13d, %esi
callq 0x2200
movl -0x30(%rbp), %r13d
addq $0x30, %rbx
jmp 0x6785
movq %r15, %rdi
callq 0x2110
addq $0x18, %r14
jmp 0x6770
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq