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

Disassembly:
push 0xffffffffffffffff
push 0x4725f0
mov eax, dword fs:[0]
push eax
sub esp, 0xb8
push ebx
push ebp
push esi
push edi
mov eax, dword [0x48a348]
xor eax, esp
push eax
lea eax, [esp + 0xcc]
mov dword fs:[0], eax
mov edi, ecx
mov ebp, dword [esp + 0xdc]
mov eax, dword [ebp + 0x54]
mov eax, dword [eax + 0xe098]
test eax, eax
je 0x40e927
cmp dword [ebp + 0x50], eax
je 0x40e927
mov eax, ebp
call fcn.0040e4e0
test eax, eax
je 0x40f1b4
mov ecx, dword [edi]
mov edx, dword [edi + 8]
xor eax, eax
mov dword [esp + 0xc0], edx
mov dword [esp + 0x84], eax
mov dword [esp + 0x88], eax
mov dword [esp + 0x8c], eax
mov dword [esp + 0x90], eax
mov eax, dword [edi + 4]
xor edx, edx
mov dword [esp + 0xb8], ecx
mov ecx, dword [ebp + 0x30]
div ecx
mov ebx, dword [edi + 0xc]
xor edx, edx
movzx esi, byte [ebp + 0xc]
shr esi, 3
mov dword [esp + 0x98], esi
mov edi, eax
mov eax, ebx
div ecx
xor edx, edx
mov ebx, eax
mov eax, dword [esp + 0xb8]
div ecx
xor edx, edx
mov dword [esp + 0x60], ebx
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0xc0]
div ecx
mov dword [esp + 0x5c], eax
cmp esi, 4
jae 0x40e9bd
mov eax, dword [esp + 0x54]
mov edx, eax
cmp esi, 1
jne 0x40e9b4
and edx, 3
jmp 0x40e9b7
and edx, 1
sub eax, edx
mov dword [esp + 0x54], eax
cmp ecx, 1
jne 0x40e9c7
mov edx, dword [ebp + 0x50]
jmp 0x40e9ca
mov edx, dword [ebp + 0x34]
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x54]
sub ecx, eax
cmp ecx, 0x10
mov dword [esp + 0x4c], edx
mov byte [esp + 0x17], 0
jge 0x40e9f1
mov dword [esp + 0x44], 8
mov byte [esp + 0x17], 1
jmp 0x40ea08
xor edx, edx
cmp ecx, 0x20
setge dl
dec edx
and edx, 0xffffffd0
add edx, 0x40
mov dword [esp + 0x44], edx
mov edx, dword [esp + 0x4c]
cmp dword [ebp + 0x20], 0
je 0x40eddc
mov ecx, dword [ebp + 0x54]
cmp byte [ecx + 0xa4], 0
jne 0x40eddc
cmp dword [ebp + 0x4c], 0
je 0x40eddc
mov ecx, dword [ebp + 4]
imul eax, esi
mov esi, dword [ebp + 0x4c]
imul ecx, edi
add ecx, eax
mov eax, dword [ebp + 0x44]
add eax, ecx
add esi, ecx
add ecx, edx
cmp edi, ebx
mov dword [esp + 0x34], eax
mov dword [esp + 0x40], esi
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x18], edi
jge 0x40f1b4
jmp 0x40ea64
mov eax, dword [esp + 0x34]
mov esi, dword [esp + 0x18]
mov ecx, dword [esp + 0x60]
mov edx, dword [esp + 0x54]
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x40]
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x44]
add eax, esi
cmp eax, ecx
mov dword [esp + 0x4c], eax
mov dword [esp + 0x1c], eax
jl 0x40ea9a
mov dword [esp + 0x1c], ecx
cmp edx, dword [esp + 0x5c]
mov dword [esp + 0x2c], edx
jge 0x40edb1
jmp 0x40eab0
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x44]
mov edi, dword [esp + 0x24]
mov esi, dword [esp + 0x68]
mov dword [esp + 0x50], ecx
mov ecx, dword [esp + 0x2c]
lea eax, [ecx + edx]
mov edx, dword [esp + 0x5c]
cmp eax, edx
mov dword [esp + 0x7c], edi
mov dword [esp + 0x74], esi
mov dword [esp + 0x94], eax
jge 0x40eae8
mov dword [esp + 0x30], eax
jmp 0x40eaee
mov eax, edx
mov dword [esp + 0x30], edx
mov ebx, eax
sub ebx, ecx
imul ebx, dword [esp + 0x98]
mov ecx, dword [ebp + 0x38]
xor edx, edx
mov eax, ebx
div ecx
mov dword [esp + 0x38], 1
mov dword [esp + 0x48], esi
mov dword [esp + 0x6c], edi
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x28]
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x20], eax
cmp eax, dword [esp + 0x1c]
jae 0x40ed90
mov ecx, dword [esp + 0x78]
mov eax, dword [ebp + 0x3c]
mov edx, dword [esp + 0x74]
imul eax, ecx
lea esi, [eax + edx]
mov edx, dword [esp + 0x7c]
lea edi, [eax + edx]
cmp ecx, 4
jb 0x40eb64
mov edi, edi
mov eax, dword [edi]
cmp eax, dword [esi]
jne 0x40ebb6
sub ecx, 4
add esi, 4
add edi, 4
cmp ecx, 4
jae 0x40eb50
test ecx, ecx
je 0x40eb88
mov dl, byte [esi]
cmp dl, byte [edi]
jne 0x40ebb6
cmp ecx, 1
jbe 0x40eb88
mov al, byte [esi + 1]
cmp al, byte [edi + 1]
jne 0x40ebb6
cmp ecx, 2
jbe 0x40eb88
mov cl, byte [esi + 2]
cmp cl, byte [edi + 2]
jne 0x40ebb6
mov eax, dword [ebp + 4]
add dword [esp + 0x7c], eax
add dword [esp + 0x74], eax
add dword [esp + 0x50], eax
mov eax, dword [ebp + 0x3c]
inc eax
cdq
idiv dword [ebp + 0x38]
mov eax, dword [esp + 0x20]
inc eax
mov dword [esp + 0x20], eax
mov dword [ebp + 0x3c], edx
cmp eax, dword [esp + 0x1c]
jb 0x40eb31
jmp 0x40ed90
cmp byte [esp + 0x17], 0
mov ecx, dword [ebp + 0x30]
mov esi, dword [esp + 0x20]
mov edi, dword [esp + 0x18]
je 0x40ebf2
mov edx, ecx
imul edx, esi
mov eax, esi
sub eax, edi
imul eax, dword [ebp + 4]
mov dword [esp + 0x88], edx
mov edx, dword [esp + 0x24]
add edx, eax
mov dword [esp + 0x6c], edx
mov edx, dword [esp + 0x68]
add eax, edx
mov dword [esp + 0x48], eax
jmp 0x40ebfe
mov eax, ecx
imul eax, edi
mov dword [esp + 0x88], eax
mov eax, ecx
imul eax, dword [esp + 0x30]
mov edx, ecx
imul edx, dword [esp + 0x2c]
mov dword [esp + 0x8c], eax
mov eax, dword [esp + 0x1c]
imul ecx, eax
cmp byte [esp + 0x17], 0
mov dword [esp + 0x84], edx
mov dword [esp + 0x90], ecx
jne 0x40ec31
mov esi, edi
cmp esi, eax
jae 0x40ecdd
sub eax, esi
mov dword [esp + 0x30], eax
nop
cmp dword [esp + 0x38], 0
je 0x40ec96
mov esi, dword [esp + 0x70]
mov edi, dword [esp + 0x6c]
mov eax, ebx
cmp ebx, 4
jb 0x40ec6a
mov ecx, dword [edi]
cmp ecx, dword [esi]
jne 0x40ec8e
sub eax, 4
add esi, 4
add edi, 4
cmp eax, 4
jae 0x40ec56
test eax, eax
je 0x40ec96
mov dl, byte [esi]
cmp dl, byte [edi]
jne 0x40ec8e
cmp eax, 1
jbe 0x40ec96
mov cl, byte [esi + 1]
cmp cl, byte [edi + 1]
jne 0x40ec8e
cmp eax, 2
jbe 0x40ec96
mov dl, byte [esi + 2]
cmp dl, byte [edi + 2]
je 0x40ec96
mov dword [esp + 0x38], 0
mov esi, dword [esp + 0x48]
mov eax, dword [esp + 0x70]
push ebx
push esi
push eax
call fcn.00463790
mov edi, dword [esp + 0x78]
add esp, 0xc
push ebx
push edi
push esi
call fcn.00463790
mov eax, dword [ebp + 4]
add dword [esp + 0x7c], eax
add edi, eax
add esi, eax
add esp, 0xc
sub dword [esp + 0x30], 1
mov dword [esp + 0x6c], edi
mov dword [esp + 0x48], esi
jne 0x40ec40
cmp dword [esp + 0x38], 0
je 0x40ed30
lea esi, [esp + 0x84]
lea edi, [esp + 0xb0]
call fcn.00406950
mov esi, dword [esp + 0xe4]
push eax
lea ecx, [esp + 0xb8]
push ecx
push esi
mov dword [esp + 0xe0], 0
call fcn.00406a80
mov edx, eax
mov byte [esp + 0xd4], 1
call fcn.004069c0
lea eax, [esp + 0xb4]
call fcn.004069a0
mov eax, edi
jmp 0x40ed80
lea esi, [esp + 0x84]
lea edi, [esp + 0x64]
call fcn.00406950
mov esi, dword [esp + 0xe0]
mov edx, edi
push edx
lea eax, [esp + 0x84]
push eax
push esi
mov dword [esp + 0xe0], 2
call fcn.00406a80
mov edx, eax
mov byte [esp + 0xd4], 3
call fcn.004069c0
lea eax, [esp + 0x80]
call fcn.004069a0
mov eax, edi
mov dword [esp + 0xd4], 0xffffffff
call fcn.004069a0
mov eax, dword [esp + 0x94]
add dword [esp + 0x68], ebx
add dword [esp + 0x24], ebx
add dword [esp + 0x28], ebx
cmp eax, dword [esp + 0x5c]
mov dword [esp + 0x2c], eax
jl 0x40eab0
mov eax, dword [ebp + 4]
imul eax, dword [esp + 0x44]
add dword [esp + 0x34], eax
add dword [esp + 0x3c], eax
add dword [esp + 0x40], eax
mov eax, dword [esp + 0x4c]
cmp eax, dword [esp + 0x60]
mov dword [esp + 0x18], eax
jl 0x40ea60
jmp 0x40f1b4
mov ecx, dword [ebp + 4]
imul eax, esi
imul ecx, edi
add eax, ecx
mov ecx, dword [ebp + 0x44]
add ecx, eax
add eax, edx
cmp edi, ebx
mov dword [esp + 0x34], ecx
mov dword [esp + 0x38], eax
mov dword [esp + 0x18], edi
jge 0x40f1b4
jmp 0x40ee0c
mov ecx, dword [esp + 0x34]
mov ebx, dword [esp + 0x60]
mov eax, dword [esp + 0x38]
mov edx, dword [esp + 0x54]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x28], ecx
mov ecx, dword [esp + 0x44]
add eax, ecx
cmp eax, ebx
mov dword [esp + 0x4c], eax
mov dword [esp + 0x1c], eax
jl 0x40ee36
mov dword [esp + 0x1c], ebx
cmp edx, dword [esp + 0x5c]
mov dword [esp + 0x2c], edx
jge 0x40f187
mov ecx, dword [esp + 0x2c]
mov eax, dword [esp + 0x44]
mov edi, dword [esp + 0x5c]
mov esi, dword [esp + 0x24]
mov edx, dword [esp + 0x28]
add eax, ecx
cmp eax, edi
mov dword [esp + 0x40], esi
mov dword [esp + 0x3c], edx
mov dword [esp + 0x94], eax
jge 0x40ee73
mov dword [esp + 0x64], eax
jmp 0x40ee79
mov eax, edi
mov dword [esp + 0x64], edi
sub eax, ecx
imul eax, dword [esp + 0x98]
mov ecx, dword [ebp + 0x38]
mov dword [esp + 0x50], edx
xor edx, edx
mov dword [esp + 0x48], eax
div ecx
mov dword [esp + 0x30], esi
mov edi, eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x20], eax
cmp eax, dword [esp + 0x1c]
jae 0x40f15b
lea ebx, [ebx]
mov ebx, dword [ebp + 0x3c]
mov edx, dword [esp + 0x3c]
mov esi, dword [esp + 0x40]
mov eax, ebx
imul eax, edi
add edx, eax
add esi, eax
mov ecx, edi
cmp edi, 4
jb 0x40eee4
jmp 0x40eed0
mov eax, dword [esi]
cmp eax, dword [edx]
jne 0x40ef3e
sub ecx, 4
add edx, 4
add esi, 4
cmp ecx, 4
jae 0x40eed0
test ecx, ecx
je 0x40ef08
mov al, byte [edx]
cmp al, byte [esi]
jne 0x40ef3e
cmp ecx, 1
jbe 0x40ef08
mov al, byte [edx + 1]
cmp al, byte [esi + 1]
jne 0x40ef3e
cmp ecx, 2
jbe 0x40ef08
mov cl, byte [edx + 2]
cmp cl, byte [esi + 2]
jne 0x40ef3e
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
dec edx
cmp ecx, edx
je 0x40ef2a
mov eax, dword [ebp + 4]
add dword [esp + 0x40], eax
add dword [esp + 0x3c], eax
lea eax, [ebx + 1]
cdq
idiv dword [ebp + 0x38]
mov dword [ebp + 0x3c], edx
inc ecx
mov dword [esp + 0x20], ecx
cmp ecx, dword [esp + 0x1c]
jb 0x40eeb0
jmp 0x40f15b
cmp byte [esp + 0x17], 0
mov eax, dword [ebp + 0x30]
mov ebx, eax
je 0x40ef6f
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
imul ebx, ecx
sub ecx, dword [esp + 0x18]
imul ecx, dword [ebp + 4]
add edx, ecx
mov dword [esp + 0x30], edx
mov edx, dword [esp + 0x28]
add ecx, edx
mov dword [esp + 0x50], ecx
jmp 0x40ef74
imul ebx, dword [esp + 0x18]
mov ecx, eax
imul ecx, dword [esp + 0x2c]
mov edi, eax
imul eax, dword [esp + 0x1c]
imul edi, dword [esp + 0x64]
push 0x14
mov dword [esp + 0x88], ecx
mov dword [esp + 0x94], eax
call fcn.0045edb3
mov esi, eax
add esp, 4
test esi, esi
je 0x40efe6
push 8
call fcn.0045edb3
add esp, 4
mov dword [esi + 8], eax
test eax, eax
jne 0x40efc3
push esi
call fcn.0045ecd6
add esp, 4
xor esi, esi
jmp 0x40efe6
xor eax, eax
xor ecx, ecx
xor edx, edx
mov dword [esi + 4], 0
mov word [esi + 0xc], ax
mov word [esi + 0x10], cx
mov word [esi + 0xe], dx
mov word [esi + 0x12], ax
mov dword [esi], 1
sub edi, dword [esp + 0x84]
mov eax, dword [esp + 0x90]
sub eax, ebx
mov dword [esp + 0x80], esi
mov dword [esi + 4], 0
mov word [esp + 0xbc], di
mov word [esp + 0xbe], ax
test di, di
je 0x40f088
test ax, ax
je 0x40f088
mov eax, dword [esp + 0x84]
mov edx, dword [esp + 0xbc]
mov word [esp + 0xa8], ax
add eax, edx
mov word [esp + 0xaa], ax
mov eax, dword [esp + 0xbe]
lea ecx, [esp + 0xa8]
mov dword [esp + 0xa4], ecx
mov word [esp + 0xac], bx
add ebx, eax
mov ecx, 1
mov dword [esp + 0xa0], ecx
mov word [esp + 0xae], bx
mov dword [esp + 0x9c], ecx
mov eax, esi
mov ecx, esi
lea ebx, [esp + 0x9c]
call fcn.0045c7d0
mov edi, dword [esp + 0xe0]
lea ecx, [esp + 0x80]
push ecx
lea edx, [esp + 0x7c]
push edx
push edi
mov dword [esp + 0xe0], 4
call fcn.00406a80
mov ecx, eax
mov byte [esp + 0xd4], 5
mov edx, dword [edi]
xor eax, eax
mov dword [edx + 4], eax
mov ecx, dword [ecx]
mov dword [esp + 0xa4], eax
mov dword [esp + 0xa0], eax
mov dword [esp + 0x9c], eax
mov eax, dword [edi]
lea ebx, [esp + 0x9c]
call fcn.0045c7d0
mov eax, dword [esp + 0x78]
mov edi, eax
mov eax, dword [eax + 8]
push eax
call fcn.0045ecd6
add esp, 4
push edi
call fcn.0045ecd6
mov dword [esp + 0xd8], 0xffffffff
mov ecx, dword [esi + 8]
add esp, 4
push ecx
call fcn.0045ecd6
add esp, 4
push esi
call fcn.0045ecd6
mov eax, dword [esp + 0x24]
add esp, 4
cmp byte [esp + 0x17], 0
jne 0x40f12d
mov eax, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
cmp eax, ebx
jae 0x40f15b
mov esi, dword [esp + 0x30]
mov edi, dword [esp + 0x50]
sub ebx, eax
nop
mov edx, dword [esp + 0x48]
push edx
push esi
push edi
call fcn.00463790
mov eax, dword [ebp + 4]
add esp, 0xc
add esi, eax
add edi, eax
sub ebx, 1
jne 0x40f140
mov ecx, dword [esp + 0x5c]
lea eax, [ecx - 1]
cmp dword [esp + 0x2c], eax
je 0x40f174
mov eax, dword [esp + 0x48]
add dword [esp + 0x28], eax
add dword [esp + 0x24], eax
mov eax, dword [esp + 0x94]
cmp eax, ecx
mov dword [esp + 0x2c], eax
jl 0x40ee44
mov ecx, dword [esp + 0x60]
lea eax, [ecx - 1]
cmp dword [esp + 0x18], eax
je 0x40f1a4
mov eax, dword [ebp + 4]
imul eax, dword [esp + 0x44]
add dword [esp + 0x34], eax
add dword [esp + 0x38], eax
mov eax, dword [esp + 0x4c]
cmp eax, ecx
mov dword [esp + 0x18], eax
jl 0x40ee04
mov ecx, dword [esp + 0xcc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc4
ret 0xc