Function at 0x40aaa0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x418a68
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x60
push ebx
push ebp
mov ebp, ecx
push esi
push edi
xor edi, edi
mov eax, dword [ebp + 0x14]
mov byte [esp + 0x13], 1
cmp eax, edi
ja 0x40aad8
mov dword [ebp + 8], 3
jmp 0x40b9c6
mov al, byte [esp + 0x84]
mov esi, dword [esp + 0x80]
mov byte [ebp + 0xa8], al
push edi
mov cl, byte [esi]
mov byte [esp + 0x34], cl
lea ecx, [esp + 0x34]
call fcn.00408770
mov edx, dword [0x419164]
lea ecx, [esp + 0x30]
push edx
push edi
push esi
call fcn.0040d120
mov eax, dword [esp + 0x34]
mov dword [esp + 0x78], edi
cmp eax, edi
jne 0x40ab1f
mov eax, 0x41916c
push 0x41c1ac
push eax
call fcn.0040ea09
add esp, 8
test eax, eax
jne 0x40ab75
push 0x41c1ac
call fcn.0040e065
add esp, 4
mov esi, eax
lea ecx, [esp + 0x30]
push 1
push esi
call fcn.004092e0
test al, al
je 0x40abd6
mov eax, dword [esp + 0x34]
push esi
push 0x41c1ac
push eax
call fcn.00402930
mov ecx, dword [esp + 0x40]
mov dword [esp + 0x44], esi
add esp, 0xc
mov word [ecx + esi*2], di
jmp 0x40abd6
mov eax, dword [esp + 0x34]
cmp eax, edi
jne 0x40ab82
mov eax, 0x41916c
push 0x41c1a0
push eax
call fcn.0040ea09
add esp, 8
test eax, eax
jne 0x40b999
push 0x41c1a0
call fcn.0040e065
add esp, 4
mov esi, eax
lea ecx, [esp + 0x30]
push 1
push esi
call fcn.004092e0
test al, al
je 0x40abd6
mov edx, dword [esp + 0x34]
push esi
push 0x41c1a0
push edx
call fcn.00402930
mov eax, dword [esp + 0x40]
mov dword [esp + 0x44], esi
add esp, 0xc
mov word [eax + esi*2], di
cmp dword [ebp + 4], edi
jne 0x40ac04
mov eax, dword [ebp + 0x20]
cmp eax, edi
jne 0x40abe7
mov eax, 0x41916c
push eax
mov ecx, ebp
call fcn.0040c610
cmp eax, edi
mov dword [ebp + 4], eax
jne 0x40ac04
call dword [0x419034]
mov dword [ebp + 8], eax
jmp 0x40b9a0
mov ecx, dword [ebp + 4]
push ecx
mov ecx, ebp
call fcn.0040c650
mov dl, byte [ebp + 0xc]
lea eax, [ebp + 0xc]
sub esp, 0x10
mov ecx, esp
mov dword [esp + 0x3c], esp
mov byte [ecx], dl
mov dword [ecx + 4], edi
mov dword [ecx + 8], edi
mov dword [ecx + 0xc], edi
mov edx, dword [0x419164]
push edx
push edi
push eax
call fcn.0040d120
mov ecx, ebp
call fcn.0040c6a0
test al, al
je 0x40b969
mov eax, dword [ebp + 0x30]
cmp eax, edi
jne 0x40ac52
mov eax, 0x41916c
mov ecx, dword [ebp + 0x50]
mov edx, dword [ebp + 4]
push ecx
push eax
push edx
mov ecx, ebp
call fcn.0040c890
mov ebx, eax
cmp ebx, edi
mov dword [esp + 0x2c], ebx
je 0x40b969
mov eax, dword [ebp + 0x40]
mov ecx, 0x41916c
cmp eax, edi
je 0x40ac7e
mov ecx, eax
mov eax, dword [esp + 0x80]
mov eax, dword [eax + 4]
cmp eax, edi
jne 0x40ac91
mov eax, 0x41916c
mov edx, dword [ebp + 0x4c]
push edx
push ecx
push eax
push ebx
mov ecx, ebp
call fcn.0040c8c0
mov esi, eax
cmp esi, edi
mov dword [esp + 0x14], esi
je 0x40b961
mov al, byte [ebp + 0x54]
test al, al
jne 0x40acd7
cmp dword [ebp + 0x4c], 4
jne 0x40acd7
lea eax, [esp + 0x80]
push 4
push eax
push esi
mov ecx, ebp
mov dword [esp + 0x8c], 0x3100
call fcn.0040c930
mov ebx, dword [0x419034]
mov dword [esp + 0x20], edi
mov eax, dword [esp + 0x20]
mov ecx, eax
inc eax
cmp ecx, 3
mov dword [esp + 0x20], eax
jae 0x40b94a
cmp dword [ebp + 0x60], edi
jbe 0x40ad36
mov dl, byte [ebp + 0x58]
lea eax, [ebp + 0x58]
sub esp, 0x10
mov ecx, esp
mov dword [esp + 0x90], esp
mov byte [ecx], dl
mov dword [ecx + 4], edi
mov dword [ecx + 8], edi
mov dword [ecx + 0xc], edi
mov edx, dword [0x419164]
push edx
push edi
push eax
call fcn.0040d120
push esi
mov ecx, ebp
call fcn.0040c950
cmp eax, edi
jne 0x40ad36
call ebx
mov dword [ebp + 8], eax
cmp dword [ebp + 0x70], edi
jbe 0x40ad4c
push esi
mov ecx, ebp
call fcn.0040c9b0
test eax, eax
jne 0x40ad4c
call ebx
mov dword [ebp + 8], eax
cmp dword [ebp + 0x80], edi
jbe 0x40ad65
push esi
mov ecx, ebp
call fcn.0040c9e0
test al, al
jne 0x40ad65
call ebx
mov dword [ebp + 8], eax
mov al, byte [esp + 0x84]
test al, al
je 0x40ad81
push esi
mov ecx, ebp
call fcn.0040cb60
test eax, eax
jne 0x40ad81
call ebx
mov dword [ebp + 8], eax
push esi
mov ecx, ebp
call fcn.0040cb70
test eax, eax
jne 0x40adad
push esi
mov ecx, ebp
call fcn.0040cb50
test al, al
je 0x40ace1
push esi
mov ecx, ebp
call fcn.0040cb70
test eax, eax
je 0x40ace1
mov eax, dword [ebp + 0xac]
cmp eax, edi
je 0x40addf
mov edx, dword [ebp + 0xb0]
lea ecx, [esp + 0x80]
push ecx
push edx
push eax
push esi
mov ecx, ebp
mov dword [esp + 0x90], edi
call fcn.0040cb90
test eax, eax
jne 0x40addf
call ebx
mov dword [ebp + 8], eax
push esi
mov ecx, ebp
call fcn.0040cbb0
test eax, eax
je 0x40b935
lea eax, [esp + 0x80]
mov ecx, ebp
push eax
push edi
push 0x16
push esi
mov dword [esp + 0x90], edi
call fcn.0040cbd0
cmp eax, edi
jne 0x40ae18
call ebx
cmp eax, 0x7a
jne 0x40b2cf
mov ecx, dword [esp + 0x80]
lea edx, [ecx + ecx]
push edx
call fcn.0040e005
mov ebx, eax
add esp, 4
cmp ebx, edi
mov dword [esp + 0x1c], ebx
je 0x40b2c9
mov eax, dword [esp + 0x80]
mov edi, ebx
lea ecx, [eax + eax]
xor eax, eax
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x80]
mov ecx, ebp
push eax
push ebx
push 0x16
push esi
call fcn.0040cbd0
test eax, eax
je 0x40b2be
mov ecx, dword [esp + 0x1c]
lea ebx, [ebp + 0xb4]
push ecx
call fcn.0040e065
add esp, 4
mov edi, eax
mov ecx, ebx
push 1
push edi
call fcn.004092e0
test al, al
je 0x40aec2
mov ecx, dword [ebx + 4]
mov eax, dword [esp + 0x1c]
test edi, edi
jbe 0x40aeaf
sub ecx, eax
mov edx, edi
mov si, word [eax]
mov word [ecx + eax], si
add eax, 2
dec edx
jne 0x40aea2
mov edx, dword [ebx + 4]
mov esi, dword [esp + 0x14]
mov dword [ebx + 8], edi
mov word [edx + edi*2], 0
lea edi, [edx + edi*2]
lea eax, [esp + 0x60]
push ebx
push eax
mov ecx, ebp
call fcn.0040cd70
lea ecx, [esp + 0x80]
xor edi, edi
push ecx
push edi
push 0x19
push esi
mov ecx, ebp
mov byte [esp + 0x88], 1
mov dword [esp + 0x90], edi
call fcn.0040cbd0
cmp eax, edi
jne 0x40af06
call dword [0x419034]
cmp eax, 0x7a
jne 0x40af93
mov edx, dword [esp + 0x80]
lea eax, [edx + edx]
push eax
call fcn.0040e005
add esp, 4
lea ecx, [esp + 0x80]
mov ebx, eax
push ecx
push ebx
push 0x19
push esi
mov ecx, ebp
call fcn.0040cbd0
test eax, eax
je 0x40af84
push ebx
lea esi, [ebp + 0xe0]
call fcn.0040e065
add esp, 4
mov edi, eax
mov ecx, esi
push 1
push edi
call fcn.004092e0
test al, al
je 0x40af84
mov ecx, dword [esi + 4]
mov eax, ebx
test edi, edi
jbe 0x40af75
sub ecx, ebx
mov dword [esp + 0x18], edi
mov dx, word [eax]
mov word [ecx + eax], dx
mov edx, dword [esp + 0x18]
add eax, 2
dec edx
mov dword [esp + 0x18], edx
jne 0x40af60
mov eax, dword [esi + 4]
mov dword [esi + 8], edi
mov word [eax + edi*2], 0
lea edi, [eax + edi*2]
push ebx
call fcn.0040d580
mov esi, dword [esp + 0x18]
add esp, 4
xor edi, edi
lea ecx, [esp + 0x80]
mov dword [esp + 0x80], edi
push ecx
push edi
push 5
push esi
mov ecx, ebp
call fcn.0040cbd0
cmp eax, edi
jne 0x40afc0
call dword [0x419034]
cmp eax, 0x7a
jne 0x40b09e
mov edx, dword [esp + 0x80]
lea eax, [edx + edx]
push eax
call fcn.0040e005
add esp, 4
lea ecx, [esp + 0x80]
mov ebx, eax
push ecx
push ebx
push 5
push esi
mov ecx, ebp
mov dword [esp + 0x38], ebx
call fcn.0040cbd0
test eax, eax
je 0x40b095
mov dl, byte [esp + 0x84]
xor eax, eax
mov byte [esp + 0x40], dl
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
push ebx
mov byte [esp + 0x7c], 2
call fcn.0040e065
add esp, 4
mov edi, eax
lea ecx, [esp + 0x40]
push 1
push edi
call fcn.004092e0
test al, al
je 0x40b05a
mov eax, dword [esp + 0x44]
mov ecx, ebx
test edi, edi
jbe 0x40b04c
mov edx, edi
mov bx, word [ecx]
add ecx, 2
mov word [eax], bx
add eax, 2
dec edx
jne 0x40b039
mov ebx, dword [esp + 0x28]
mov eax, dword [esp + 0x44]
mov dword [esp + 0x48], edi
mov word [eax + edi*2], 0
mov ecx, dword [esp + 0x44]
mov byte [esp + 0x78], 1
test ecx, ecx
je 0x40b085
mov al, byte [ecx - 1]
test al, al
je 0x40b079
cmp al, 0xff
je 0x40b079
dec al
mov byte [ecx - 1], al
jmp 0x40b085
lea eax, [ecx - 2]
push eax
call fcn.0040d580
add esp, 4
xor eax, eax
xor edi, edi
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
push ebx
call fcn.0040d580
add esp, 4
lea ecx, [esp + 0x80]
mov dword [esp + 0x80], edi
push ecx
push edi
push 0x21
push esi
mov ecx, ebp
call fcn.0040cbd0
cmp eax, edi
jne 0x40b0cb
call dword [0x419034]
cmp eax, 0x7a
jne 0x40b158
mov edx, dword [esp + 0x80]
lea eax, [edx + edx]
push eax
call fcn.0040e005
add esp, 4
lea ecx, [esp + 0x80]
mov ebx, eax
push ecx
push ebx
push 0x21
push esi
mov ecx, ebp
call fcn.0040cbd0
test eax, eax
je 0x40b149
push ebx
lea esi, [ebp + 0x114]
call fcn.0040e065
add esp, 4
mov edi, eax
mov ecx, esi
push 1
push edi
call fcn.004092e0
test al, al
je 0x40b149
mov ecx, dword [esi + 4]
mov eax, ebx
test edi, edi
jbe 0x40b13a
sub ecx, ebx
mov dword [esp + 0x18], edi
mov dx, word [eax]
mov word [ecx + eax], dx
mov edx, dword [esp + 0x18]
add eax, 2
dec edx
mov dword [esp + 0x18], edx
jne 0x40b125
mov eax, dword [esi + 4]
mov dword [esi + 8], edi
mov word [eax + edi*2], 0
lea edi, [eax + edi*2]
push ebx
call fcn.0040d580
mov esi, dword [esp + 0x18]
add esp, 4
xor edi, edi
lea ecx, [esp + 0x80]
mov dword [esp + 0x80], edi
push ecx
push edi
push 0x2b
push esi
mov ecx, ebp
call fcn.0040cbd0
cmp eax, edi
jne 0x40b185
call dword [0x419034]
cmp eax, 0x7a
jne 0x40b285
mov edx, dword [esp + 0x80]
lea eax, [edx + edx]
push eax
call fcn.0040e005
add esp, 4
lea ecx, [esp + 0x80]
mov ebx, eax
push ecx
push ebx
push 0x2b
push esi
mov ecx, ebp
mov dword [esp + 0x28], ebx
call fcn.0040cbd0
test eax, eax
je 0x40b27c
mov edx, dword [esp + 0x18]
lea ebx, [ebp + 0x104]
push edx
call fcn.0040e065
add esp, 4
mov edi, eax
mov ecx, ebx
push 1
push edi
call fcn.004092e0
test al, al
je 0x40b20b
mov ecx, dword [ebx + 4]
mov eax, dword [esp + 0x18]
test edi, edi
jbe 0x40b1f8
sub ecx, eax
mov edx, edi
mov si, word [eax]
mov word [ecx + eax], si
add eax, 2
dec edx
jne 0x40b1eb
mov eax, dword [ebx + 4]
mov esi, dword [esp + 0x14]
mov dword [ebx + 8], edi
mov word [eax + edi*2], 0
lea edi, [eax + edi*2]
push 0x41c62c
lea ecx, [esp + 0x54]
push ebx
push ecx
call fcn.0040d420
mov eax, dword [esp + 0x60]
xor edi, edi
add esp, 0xc
cmp eax, edi
mov ecx, 0x41916c
je 0x40b22f
mov ecx, eax
mov eax, dword [ebp + 0x10]
cmp eax, edi
jne 0x40b23b
mov eax, 0x41916c
push ecx
push edi
push eax
call dword [0x419110]
mov ecx, dword [esp + 0x54]
cmp ecx, edi
je 0x40b26a
mov al, byte [ecx - 1]
test al, al
je 0x40b25e
cmp al, 0xff
je 0x40b25e
dec al
mov byte [ecx - 1], al
jmp 0x40b26a
lea eax, [ecx - 2]
push eax
call fcn.0040d580
add esp, 4
mov ebx, dword [esp + 0x18]
mov dword [esp + 0x54], edi
mov dword [esp + 0x58], edi
mov dword [esp + 0x5c], edi
xor edi, edi
push ebx
call fcn.0040d580
add esp, 4
mov ecx, dword [esp + 0x64]
mov byte [esp + 0x78], 0
cmp ecx, edi
je 0x40b2ae
mov al, byte [ecx - 1]
test al, al
je 0x40b2a4
cmp al, 0xff
je 0x40b2a4
dec al
mov byte [ecx - 1], al
jmp 0x40b2ae
dec ecx
push ecx
call fcn.0040d580
add esp, 4
mov ebx, dword [esp + 0x1c]
mov dword [esp + 0x64], edi
mov dword [esp + 0x68], edi
mov dword [esp + 0x6c], edi
push ebx
call fcn.0040d580
add esp, 4
xor edi, edi
mov ebx, dword [0x419034]
lea edx, [esp + 0x80]
mov ecx, ebp
push edx
push edi
push 0x13
push esi
mov dword [esp + 0x90], edi
call fcn.0040cbd0
cmp eax, edi
jne 0x40b2f8
call ebx
cmp eax, 0x7a
jne 0x40b3e1
mov eax, dword [esp + 0x80]
lea ecx, [eax + eax]
push ecx
call fcn.0040e005
mov esi, eax
add esp, 4
test esi, esi
je 0x40b3e1
mov edx, dword [esp + 0x80]
xor eax, eax
mov edi, esi
lea ecx, [edx + edx]
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x80]
push eax
push esi
push 0x13
push ecx
mov ecx, ebp
call fcn.0040cbd0
test eax, eax
je 0x40b3d8
push esi
lea edi, [ebp + 0xc4]
call fcn.0040e065
add esp, 4
mov ecx, edi
mov ebx, eax
call fcn.0040d330
cmp eax, ebx
jae 0x40b371
call fcn.0040d58b
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x40b396
mov al, byte [ecx - 1]
test al, al
je 0x40b396
cmp al, 0xff
je 0x40b396
test ebx, ebx
jne 0x40b3ba
dec al
push ebx
mov byte [ecx - 1], al
mov ecx, edi
call fcn.00408770
jmp 0x40b3d8
test ebx, ebx
jne 0x40b3a5
push 1
mov ecx, edi
call fcn.00408770
jmp 0x40b3d8
mov eax, dword [edi + 0xc]
cmp eax, 0x1f
ja 0x40b3b1
cmp eax, ebx
jae 0x40b3c2
push 1
mov ecx, edi
call fcn.00408770
push ebx
mov ecx, edi
call fcn.00409410
mov edx, dword [edi + 4]
push ebx
push esi
push edx
call fcn.00402930
add esp, 0xc
mov ecx, edi
push ebx
call fcn.004092c0
push esi
call fcn.0040d580
add esp, 4
mov eax, dword [ebp + 0xd4]
xor ebx, ebx
cmp eax, ebx
mov dword [esp + 0x1c], 0x2800
je 0x40b404
push eax
call fcn.0040d580
add esp, 4
mov dword [ebp + 0xd4], ebx
push 0x2800
call fcn.0040e005
mov edi, eax
add esp, 4
cmp edi, ebx
mov dword [ebp + 0xd4], edi
je 0x40b93f
mov ecx, 0xa00
xor eax, eax
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x80]
push eax
push ecx
mov ecx, ebp
mov dword [esp + 0x88], 0
call fcn.0040cbf0
test eax, eax
je 0x40b566
push ebx
mov ecx, ebp
call fcn.0040bd20
mov edx, dword [esp + 0x80]
inc edx
push edx
call fcn.0040e005
mov esi, eax
add esp, 4
test esi, esi
mov dword [esp + 0x24], esi
je 0x40b56f
mov eax, dword [esp + 0x80]
mov edi, esi
mov dword [esp + 0x18], 0
lea ecx, [eax + 1]
xor eax, eax
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
mov edx, dword [esp + 0x14]
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, dword [esp + 0x80]
lea eax, [esp + 0x18]
push eax
push ecx
push esi
push edx
mov ecx, ebp
call fcn.0040cc10
test eax, eax
je 0x40b55b
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
add eax, ebx
cmp eax, ecx
jbe 0x40b531
mov edx, dword [esp + 0x1c]
mov ecx, dword [ebp + 0xd4]
mov dword [esp + 0x28], ecx
lea esi, [edx + edx]
push esi
call fcn.0040e005
mov edi, eax
add esp, 4
test edi, edi
mov dword [ebp + 0xd4], edi
je 0x40b57f
mov ecx, esi
xor eax, eax
mov dword [esp + 0x1c], ecx
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov eax, dword [esp + 0x28]
mov edi, dword [ebp + 0xd4]
mov ecx, ebx
mov esi, eax
mov edx, ecx
push eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.0040d580
add esp, 4
mov eax, dword [ebp + 0xd4]
mov ecx, dword [esp + 0x18]
mov esi, dword [esp + 0x24]
mov edi, ebx
add edi, eax
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x24]
add ebx, eax
push esi
call fcn.0040d580
add esp, 4
jmp 0x40b56f
call dword [0x419034]
mov dword [ebp + 8], eax
mov eax, dword [esp + 0x80]
test eax, eax
jbe 0x40b58e
jmp 0x40b42a
mov ecx, dword [esp + 0x28]
mov byte [esp + 0x13], 0
mov dword [ebp + 0xd4], ecx
push ebx
mov ecx, ebp
call fcn.0040bd20
mov dword [ebp + 0xdc], ebx
mov eax, dword [ebp + 0xe4]
xor esi, esi
mov dword [esp + 0x18], 1
test eax, eax
jne 0x40b5b5
mov eax, 0x41916c
push 5
push 0x41c620
push eax
call fcn.0040e973
add esp, 0xc
test eax, eax
jne 0x40b5d2
mov esi, 0xfde9
mov dword [esp + 0x18], eax
mov edx, dword [ebp + 0xdc]
mov eax, dword [ebp + 0xd4]
mov ecx, dword [esp + 0x18]
mov edi, dword [0x419030]
push 0
inc edx
push 0
push edx
push eax
push ecx
push esi
call edi
mov ebx, eax
test ebx, ebx
jg 0x40b623
mov edx, dword [ebp + 0xdc]
mov eax, dword [ebp + 0xd4]
xor esi, esi
inc edx
push esi
push esi
push edx
push eax
push 1
push esi
mov dword [esp + 0x30], 1
call edi
mov ebx, eax
test ebx, ebx
jle 0x40b70f
lea edi, [ebx + ebx]
push edi
call fcn.0040e005
mov edx, eax
add esp, 4
test edx, edx
mov dword [esp + 0x28], edx
je 0x40b70f
mov ecx, edi
mov edi, edx
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
mov edx, dword [esp + 0x18]
and ecx, 3
push ebx
mov ebx, dword [esp + 0x2c]
rep stosb byte es:[edi], al
mov eax, dword [ebp + 0xdc]
mov ecx, dword [ebp + 0xd4]
inc eax
push ebx
push eax
push ecx
push edx
push esi
call dword [0x419030]
test eax, eax
jle 0x40b706
push ebx
lea edi, [ebp + 0xf0]
call fcn.0040e065
add esp, 4
mov ecx, edi
mov esi, eax
call fcn.0040d330
cmp eax, esi
jae 0x40b69b
call fcn.0040d58b
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x40b6c0
mov al, byte [ecx - 1]
test al, al
je 0x40b6c0
cmp al, 0xff
je 0x40b6c0
test esi, esi
jne 0x40b6e4
dec al
push esi
mov byte [ecx - 1], al
mov ecx, edi
call fcn.00408770
jmp 0x40b706
test esi, esi
jne 0x40b6cf
push 1
mov ecx, edi
call fcn.00408770
jmp 0x40b706
mov eax, dword [edi + 0xc]
cmp eax, 0x1f
ja 0x40b6db
cmp eax, esi
jae 0x40b6ec
push 1
mov ecx, edi
call fcn.00408770
push esi
mov ecx, edi
call fcn.00409410
mov eax, dword [edi + 4]
push esi
push ebx
push eax
call fcn.00402930
mov ecx, dword [edi + 4]
mov dword [edi + 8], esi
add esp, 0xc
mov word [ecx + esi*2], 0
push ebx
call fcn.0040d580
add esp, 4
push 0x41c1ac
call fcn.0040e065
mov edi, dword [esp + 0x3c]
add esp, 4
cmp edi, eax
mov esi, edi
jb 0x40b728
mov esi, eax
mov ecx, dword [esp + 0x34]
mov edx, 0x41c1ac
test esi, esi
jbe 0x40b75c
mov bx, word [ecx]
cmp bx, word [edx]
jne 0x40b748
add ecx, 2
add edx, 2
dec esi
jne 0x40b735
jmp 0x40b75c
mov cx, word [ecx]
cmp cx, word [edx]
sbb ecx, ecx
and ecx, 0xfffffffe
inc ecx
test ecx, ecx
jne 0x40b94f
cmp edi, eax
jb 0x40b94f
xor ecx, ecx
cmp edi, eax
setne cl
test ecx, ecx
jne 0x40b94f
mov al, byte [esp + 0x84]
test al, al
jne 0x40b94f
push 0x41c610
call fcn.0040e065
add esp, 4
mov dword [esp + 0x24], eax
test eax, eax
je 0x40b84e
mov ecx, dword [ebp + 0xf8]
test ecx, ecx
jbe 0x40b83f
mov ebx, ecx
cmp eax, ebx
ja 0x40b83f
mov ecx, dword [ebp + 0xf4]
mov edx, 1
sub edx, eax
mov dword [esp + 0x1c], ecx
add ebx, edx
mov dword [esp + 0x28], ecx
mov si, word [0x41c610]
mov edx, ebx
test ebx, ebx
jbe 0x40b83f
cmp word [ecx], si
je 0x40b7e4
add ecx, 2
dec edx
je 0x40b83f
jmp 0x40b7d7
test ecx, ecx
je 0x40b83f
test eax, eax
mov esi, eax
mov edi, 0x41c610
mov edx, ecx
jbe 0x40b837
mov ax, word [edx]
cmp ax, word [edi]
jne 0x40b808
add edx, 2
add edi, 2
dec esi
je 0x40b837
jmp 0x40b7f5
mov dx, word [edx]
cmp dx, word [edi]
sbb eax, eax
and al, 0xfe
inc eax
mov dword [esp + 0x18], eax
je 0x40b837
mov eax, dword [esp + 0x28]
mov edx, ecx
sub edx, eax
or eax, 0xffffffff
sar edx, 1
sub eax, edx
add ebx, eax
mov eax, dword [esp + 0x24]
add ecx, 2
mov dword [esp + 0x28], ecx
jmp 0x40b7ca
sub ecx, dword [esp + 0x1c]
sar ecx, 1
jmp 0x40b845
mov ecx, dword [0x419164]
cmp ecx, 0xffffffff
je 0x40b94f
push 0x41c600
call fcn.0040e065
add esp, 4
mov dword [esp + 0x24], eax
test eax, eax
je 0x40b94f
mov ecx, dword [ebp + 0xf8]
test ecx, ecx
jbe 0x40b912
mov ebx, ecx
cmp eax, ebx
ja 0x40b912
mov si, word [0x41c600]
mov ecx, 1
sub ecx, eax
add ebx, ecx
mov ecx, dword [ebp + 0xf4]
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x28], ecx
test ebx, ebx
mov edx, ebx
jbe 0x40b912
cmp word [ecx], si
je 0x40b8b0
add ecx, 2
dec edx
je 0x40b912
jmp 0x40b8a3
test ecx, ecx
je 0x40b912
test eax, eax
mov esi, eax
mov edi, 0x41c600
mov edx, ecx
jbe 0x40b90a
mov ax, word [edx]
cmp ax, word [edi]
jne 0x40b8d4
add edx, 2
add edi, 2
dec esi
je 0x40b90a
jmp 0x40b8c1
mov dx, word [edx]
cmp dx, word [edi]
sbb eax, eax
and al, 0xfe
inc eax
mov dword [esp + 0x18], eax
je 0x40b90a
mov eax, dword [esp + 0x28]
mov edx, ecx
sub edx, eax
mov si, word [0x41c600]
sar edx, 1
or eax, 0xffffffff
sub eax, edx
add ebx, eax
mov eax, dword [esp + 0x24]
add ecx, 2
mov dword [esp + 0x28], ecx
jmp 0x40b89d
sub ecx, dword [esp + 0x1c]
sar ecx, 1
jmp 0x40b918
mov ecx, dword [0x419164]
cmp ecx, 0xffffffff
jne 0x40b94f
mov ebx, dword [0x419034]
mov esi, dword [esp + 0x14]
mov dword [ebp + 8], 0xd
xor edi, edi
jmp 0x40ace1
call ebx
mov dword [ebp + 8], eax
jmp 0x40ace1
xor al, al
mov byte [esp + 0x13], 0
test al, al
jne 0x40b94f
mov byte [esp + 0x13], 0
mov ecx, dword [esp + 0x14]
push ecx
mov ecx, ebp
call fcn.0040c630
mov ebx, dword [esp + 0x2c]
xor edi, edi
push ebx
mov ecx, ebp
call fcn.0040c630
mov ecx, dword [esp + 0x34]
cmp ecx, edi
je 0x40b993
mov al, byte [ecx - 1]
test al, al
je 0x40b987
cmp al, 0xff
je 0x40b987
dec al
mov byte [ecx - 1], al
mov al, byte [esp + 0x13]
jmp 0x40b9c8
add ecx, 0xfffffffe
push ecx
call fcn.0040d580
add esp, 4
mov al, byte [esp + 0x13]
jmp 0x40b9c8
mov dword [ebp + 8], 0x57
mov ecx, dword [esp + 0x34]
cmp ecx, edi
je 0x40b9c6
mov al, byte [ecx - 1]
test al, al
je 0x40b9ba
cmp al, 0xff
je 0x40b9ba
dec al
mov byte [ecx - 1], al
jmp 0x40b9c6
add ecx, 0xfffffffe
push ecx
call fcn.0040d580
add esp, 4
xor al, al
mov ecx, dword [esp + 0x70]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x6c
ret 8