// File: /workspace/github_cpp_makefile_star2_O2/Unreality3D[P]Unreality3D/indie-studio/source/MapGenerator/MapGenerator.cpp
// Function: Map::draw_rooms_pattern()
void		Map::draw_rooms_pattern()
{
  for(int i = 0; i < _rooms.size();i++)
    {
      if (_rooms[i]._size.y > _rooms[i]._size.x && _rooms[i]._size.y >= 12 && _rooms[i]._size.x >= 6)
	rand() % 100 > 50 ? _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'H' : _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'T';
      else if (_rooms[i]._size.y > _rooms[i]._size.x && _rooms[i]._size.y >= 6 && _rooms[i]._size.x >= 5)
	rand() % 100 > 50 ? _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'h' : _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 't';
      else if (_rooms[i]._size.y < _rooms[i]._size.x && _rooms[i]._size.x >= 12 && _rooms[i]._size.x >= 6)
	(rand() % 100) > 50 ? _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'B' : _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'G';
     else if (_rooms[i]._size.y < _rooms[i]._size.x && _rooms[i]._size.x >= 6 && _rooms[i]._size.x >= 5)
       (rand() % 100) > 50 ? _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'b' : _map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'g';
     else if (_rooms[i]._size.y == _rooms[i]._size.x
	      && (_rooms[i]._size.x >= 5 && _rooms[i]._size.y >= 5)
	      && (_rooms[i]._size.x <= 7 && _rooms[i]._size.y <= 7))
	_map[(_rooms[i]._size.y / 2) + _rooms[i]._pos.y + 2][(_rooms[i]._size.x / 2) + _rooms[i]._pos.x + 2] = 'C';
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
pushq $0xc
popq %r14
xorl %r15d, %r15d
pushq $0x14
popq %r12
pushq $0x64
popq %rbp
pushq $0x2
popq %r13
movq 0x40(%rbx), %rcx
movq 0x48(%rbx), %rax
subq %rcx, %rax
cqto
idivq %r12
cmpq %r15, %rax
jbe 0x41c2
movl -0x4(%rcx,%r14), %edx
movl (%rcx,%r14), %eax
cmpl %edx, %eax
jle 0x40a8
cmpl $0xc, %eax
jl 0x4048
cmpl $0x6, %edx
jl 0x40a3
callq 0x3080
cltd
idivl %ebp
movl %edx, %ecx
movq 0x40(%rbx), %rdi
movq 0x58(%rbx), %r8
movl -0x4(%rdi,%r14), %esi
movl (%rdi,%r14), %eax
cltd
idivl %r13d
movslq -0x8(%rdi,%r14), %rdx
movslq %eax, %r9
addq %rdx, %r9
shlq $0x5, %r9
movl %esi, %eax
cltd
idivl %r13d
movslq -0xc(%rdi,%r14), %rdx
cltq
addq %rdx, %rax
movq 0x40(%r8,%r9), %rdx
cmpl $0x33, %ecx
jl 0x41aa
movb $0x48, 0x2(%rdx,%rax)
jmp 0x41b6
cmpl $0x4, %edx
jle 0x40a8
callq 0x3080
cltd
idivl %ebp
movl %edx, %ecx
movq 0x40(%rbx), %rdi
movq 0x58(%rbx), %r8
movl -0x4(%rdi,%r14), %esi
movl (%rdi,%r14), %eax
cltd
idivl %r13d
movslq -0x8(%rdi,%r14), %rdx
movslq %eax, %r9
addq %rdx, %r9
shlq $0x5, %r9
movl %esi, %eax
cltd
idivl %r13d
movslq -0xc(%rdi,%r14), %rdx
cltq
addq %rdx, %rax
movq 0x40(%r8,%r9), %rdx
cmpl $0x33, %ecx
jl 0x419c
movb $0x68, 0x2(%rdx,%rax)
jmp 0x41b6
cmpl $0x5, %edx
je 0x404d
cmpl %edx, %eax
jge 0x415f
cmpl $0xc, %edx
jl 0x410b
callq 0x3080
cltd
idivl %ebp
movl %edx, %ecx
movq 0x40(%rbx), %rdi
movq 0x58(%rbx), %r8
movl -0x4(%rdi,%r14), %esi
movl (%rdi,%r14), %eax
cltd
idivl %r13d
movslq -0x8(%rdi,%r14), %rdx
movslq %eax, %r9
addq %rdx, %r9
shlq $0x5, %r9
movl %esi, %eax
cltd
idivl %r13d
movslq -0xc(%rdi,%r14), %rdx
cltq
addq %rdx, %rax
movq 0x40(%r8,%r9), %rdx
cmpl $0x33, %ecx
jl 0x41a3
movb $0x42, 0x2(%rdx,%rax)
jmp 0x41b6
cmpl $0x6, %edx
jl 0x415f
callq 0x3080
cltd
idivl %ebp
movl %edx, %ecx
movq 0x40(%rbx), %rdi
movq 0x58(%rbx), %r8
movl -0x4(%rdi,%r14), %esi
movl (%rdi,%r14), %eax
cltd
idivl %r13d
movslq -0x8(%rdi,%r14), %rdx
movslq %eax, %r9
addq %rdx, %r9
shlq $0x5, %r9
movl %esi, %eax
cltd
idivl %r13d
movslq -0xc(%rdi,%r14), %rdx
cltq
addq %rdx, %rax
movq 0x40(%r8,%r9), %rdx
cmpl $0x33, %ecx
jl 0x41b1
movb $0x62, 0x2(%rdx,%rax)
jmp 0x41b6
movl %edx, %esi
orl %eax, %esi
cmpl $0x7, %esi
ja 0x41b6
cmpl $0x5, %eax
jl 0x41b6
cmpl %edx, %eax
jne 0x41b6
cmpl $0x5, %edx
jl 0x41b6
shrl %eax
movslq -0x8(%rcx,%r14), %rdx
addq %rax, %rdx
movq 0x58(%rbx), %rsi
shlq $0x5, %rdx
movslq -0xc(%rcx,%r14), %rcx
addq %rax, %rcx
movq 0x40(%rsi,%rdx), %rax
movb $0x43, 0x2(%rax,%rcx)
jmp 0x41b6
movb $0x74, 0x2(%rdx,%rax)
jmp 0x41b6
movb $0x47, 0x2(%rdx,%rax)
jmp 0x41b6
movb $0x54, 0x2(%rdx,%rax)
jmp 0x41b6
movb $0x67, 0x2(%rdx,%rax)
incq %r15
addq $0x14, %r14
jmp 0x3fba
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop