// File: Unreality3D[P]Unreality3D/indie-studio/source/MapGenerator/MapGenerator.cpp
// Function: Map::draw_better_walls()
void		Map::draw_better_walls()
{
  for (size_t i = 1;i < _map.size() - 1;i++)
    {
      for (size_t x = 1;x < _map[i].length()- 1;x++)
	{
	  if (_map[i][x] == '#' && _map[i][x + 1] == '#' && _map[i + 1][x] == '#')
	    _map[i][x] = 'X';
	  else if (_map[i][x] == '#' && _map[i][x - 1] == '-' && _map[i + 1][x] == '#')
	    _map[i][x] = 'X';
	  else if ((_map[i][x] == '#' && _map[i][x - 1] == '-' && _map[i - 1][x] == '|')
		   || (_map[i][x] == '#' && _map[i][x - 1] == 'X' && _map[i - 1][x] == '|')
		   || (_map[i][x] == '#' && _map[i][x - 1] == '-' && _map[i - 1][x] == 'X'))
	    _map[i][x] = 'X';
	  else if (_map[i][x] == '#' && _map[i - 1][x] == '|' && _map[i][x + 1] == '#')
	    _map[i][x] = 'X';
	  else if (_map[i][x] == '#' && _map[i][x + 1] == '#')
	    _map[i][x] = '-';
	  else if (_map[i][x] == '#' && _map[i + 1][x] == '#')
	    _map[i][x] = '|';
	}
    }
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x18(%rsp)
movq $0x1, 0x28(%rsp)
movq 0x18(%rsp), %rdi
movq 0x28(%rsp), %rax
movq %rax, 0x10(%rsp)
addq $0x58, %rdi
callq 0x6a70
movq %rax, %rcx
movq 0x10(%rsp), %rax
subq $0x1, %rcx
cmpq %rcx, %rax
jae 0x7bb8
movq $0x1, 0x20(%rsp)
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
callq 0x67c0
movq %rax, %rcx
movq 0x8(%rsp), %rax
subq $0x1, %rcx
cmpq %rcx, %rax
jae 0x7ba3
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7788
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
addq $0x1, %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7788
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
addq $0x1, %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7788
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movb $0x58, (%rax)
jmp 0x7b8e
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7834
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
subq $0x1, %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x2d, %eax
jne 0x7834
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
addq $0x1, %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7834
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movb $0x58, (%rax)
jmp 0x7b8c
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x78b8
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
subq $0x1, %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x2d, %eax
jne 0x78b8
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
subq $0x1, %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x7c, %eax
je 0x79c0
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x793c
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
subq $0x1, %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x58, %eax
jne 0x793c
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
subq $0x1, %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x7c, %eax
je 0x79c0
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x79e8
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
subq $0x1, %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x2d, %eax
jne 0x79e8
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
subq $0x1, %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x58, %eax
jne 0x79e8
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movb $0x58, (%rax)
jmp 0x7b8a
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7a94
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
subq $0x1, %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x7c, %eax
jne 0x7a94
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
addq $0x1, %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7a94
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movb $0x58, (%rax)
jmp 0x7b88
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7b0d
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
addq $0x1, %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7b0d
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movb $0x2d, (%rax)
jmp 0x7b86
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7b84
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
addq $0x1, %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x7b84
movq 0x18(%rsp), %rdi
addq $0x58, %rdi
movq 0x28(%rsp), %rsi
callq 0x6a90
movq %rax, %rdi
movq 0x20(%rsp), %rsi
callq 0x6b10
movb $0x7c, (%rax)
jmp 0x7b86
jmp 0x7b88
jmp 0x7b8a
jmp 0x7b8c
jmp 0x7b8e
jmp 0x7b90
movq 0x20(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x20(%rsp)
jmp 0x76a2
jmp 0x7ba5
movq 0x28(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x28(%rsp)
jmp 0x766c
addq $0x38, %rsp
retq
nopl (%rax)