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

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x4618cd
push eax
mov dword fs:[0], esp
sub esp, 0x10c
push ebx
push ebp
push esi
push edi
xor ebx, ebx
xor ebp, ebp
mov esi, ecx
xor edi, edi
mov eax, dword [esi + 0x68]
cmp eax, ebx
je 0x4059cb
mov ecx, dword [esi + 0x6c]
sub ecx, eax
mov eax, 0x2aaaaaab
imul ecx
mov eax, edx
shr eax, 0x1f
add edx, eax
cmp ebp, edx
jae 0x4059cb
mov eax, dword [esi + 0x78]
mov ecx, dword [esi + 0x18]
xor edx, edx
mov dx, word [edi + eax]
lea eax, [esp + 0x104]
shl edx, 4
add edx, ecx
push edx
push eax
call fcn.004042e0
mov ecx, dword [eax]
mov dword [esp + 0xac], ecx
mov ecx, dword [esi + 0x18]
mov edx, dword [eax + 4]
mov dword [esp + 0xb0], edx
xor edx, edx
mov eax, dword [eax + 8]
mov dword [esp + 0xb4], eax
mov eax, dword [esi + 0x78]
mov dx, word [edi + eax + 2]
lea eax, [esp + 0x100]
shl edx, 4
add edx, ecx
push edx
push eax
call fcn.004042e0
mov ecx, dword [eax]
mov dword [esp + 0xa8], ecx
lea ecx, [esp + 0xb4]
mov edx, dword [eax + 4]
push ecx
mov dword [esp + 0xb0], edx
lea edx, [esp + 0xac]
mov eax, dword [eax + 8]
push edx
mov dword [esp + 0xb8], eax
lea eax, [esp + 0x128]
push eax
call fcn.00404320
mov edx, eax
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov edx, dword [edx + 8]
mov dword [esp + 0xfc], eax
mov eax, dword [esi + 0x78]
mov dword [esp + 0x104], edx
xor edx, edx
mov dword [esp + 0x100], ecx
mov dx, word [edi + eax + 4]
mov ecx, dword [esi + 0x18]
shl edx, 4
add edx, ecx
lea eax, [esp + 0x108]
push edx
push eax
call fcn.004042e0
mov ecx, dword [eax]
mov dword [esp + 0xd4], ecx
mov ecx, dword [esi + 0x18]
mov edx, dword [eax + 4]
mov dword [esp + 0xd8], edx
xor edx, edx
mov eax, dword [eax + 8]
mov dword [esp + 0xdc], eax
mov eax, dword [esi + 0x78]
mov dx, word [edi + eax + 2]
lea eax, [esp + 0xa0]
shl edx, 4
add edx, ecx
push edx
push eax
call fcn.004042e0
mov ecx, dword [eax]
mov dword [esp + 0xf4], ecx
lea ecx, [esp + 0xdc]
mov edx, dword [eax + 4]
push ecx
mov dword [esp + 0xfc], edx
lea edx, [esp + 0xf8]
mov eax, dword [eax + 8]
mov dword [esp + 0x100], eax
lea eax, [esp + 0x80]
push edx
push eax
call fcn.00404320
mov edx, eax
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov edx, dword [edx + 8]
mov dword [esp + 0x10c], eax
mov dword [esp + 0x110], ecx
lea eax, [esp + 0x118]
mov dword [esp + 0x114], edx
lea ecx, [esp + 0x10c]
push eax
lea edx, [esp + 0x74]
push ecx
push edx
call fcn.00404420
mov ecx, dword [eax]
add esp, 0x44
mov dword [esp + 0xbc], ecx
lea ecx, [esp + 0xbc]
mov edx, dword [eax + 4]
push ecx
mov dword [esp + 0xc4], edx
lea edx, [esp + 0x64]
mov eax, dword [eax + 8]
push edx
mov dword [esp + 0xcc], eax
call fcn.004043a0
mov ebx, dword [esi + 0x78]
mov edx, eax
add esp, 8
inc ebp
mov eax, dword [edx]
lea ebx, [edi + ebx + 0xc]
add edi, 0x34
mov ecx, dword [edx + 4]
mov edx, dword [edx + 8]
mov dword [ebx], eax
mov dword [ebx + 4], ecx
mov dword [ebx + 8], edx
xor ebx, ebx
jmp 0x4057c7
mov al, byte [esp + 0x13]
mov dword [esp + 0x24], ebx
mov byte [esp + 0x20], al
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
mov cl, byte [esp + 0x13]
mov dword [esp + 0x124], ebx
mov byte [esp + 0x60], cl
mov dword [esp + 0x64], ebx
mov dword [esp + 0x68], ebx
mov dword [esp + 0x6c], ebx
mov eax, dword [esi + 0x18]
mov byte [esp + 0x124], 1
cmp eax, ebx
jne 0x405a0d
xor edi, edi
jmp 0x405a15
mov edi, dword [esi + 0x1c]
sub edi, eax
sar edi, 4
lea ecx, [esp + 0x20]
call fcn.00409880
cmp eax, edi
jae 0x405a43
mov ebp, dword [esp + 0x28]
lea edx, [esp + 0x60]
push edx
lea ecx, [esp + 0x24]
call fcn.00409880
sub edi, eax
lea ecx, [esp + 0x24]
push edi
push ebp
call fcn.0040ac50
jmp 0x405a68
lea ecx, [esp + 0x20]
call fcn.00409880
cmp edi, eax
jae 0x405a68
mov ecx, dword [esp + 0x24]
mov eax, dword [esp + 0x28]
shl edi, 4
add edi, ecx
push eax
push edi
lea ecx, [esp + 0x28]
call fcn.0040aee0
mov ecx, dword [esp + 0x68]
mov edx, dword [esp + 0x64]
push ecx
push edx
lea ecx, [esp + 0x68]
mov byte [esp + 0x12c], 0
call fcn.00409620
mov eax, dword [esp + 0x64]
push eax
call fcn.004273b2
add esp, 4
xor edi, edi
xor ebp, ebp
mov eax, dword [esi + 0x68]
cmp eax, ebx
je 0x405b2f
mov ecx, dword [esi + 0x6c]
sub ecx, eax
mov eax, 0x2aaaaaab
imul ecx
mov ecx, edx
shr ecx, 0x1f
add edx, ecx
cmp edi, edx
jae 0x405b2f
mov edx, dword [esi + 0x78]
mov eax, dword [esp + 0x24]
xor ecx, ecx
mov dword [esp + 0x18], edi
mov cx, word [edx + ebp]
shl ecx, 4
add ecx, eax
lea eax, [esp + 0x18]
push eax
mov edx, dword [ecx + 8]
push edx
call fcn.0040af90
mov eax, dword [esi + 0x78]
mov edx, dword [esp + 0x24]
xor ecx, ecx
mov dword [esp + 0x18], edi
mov cx, word [eax + ebp + 2]
shl ecx, 4
add ecx, edx
lea edx, [esp + 0x18]
push edx
mov eax, dword [ecx + 8]
push eax
call fcn.0040af90
mov ecx, dword [esi + 0x78]
mov eax, dword [esp + 0x24]
xor edx, edx
mov dword [esp + 0x18], edi
mov dx, word [ecx + ebp + 4]
mov ecx, edx
shl ecx, 4
add ecx, eax
lea eax, [esp + 0x18]
push eax
mov edx, dword [ecx + 8]
push edx
call fcn.0040af90
inc edi
add ebp, 0x34
jmp 0x405a94
mov al, byte [esp + 0x12c]
test al, al
jne 0x405c47
mov dword [esp + 0x14], ebx
mov dword [esp + 0x48], ebx
xor edi, edi
mov eax, dword [esi + 0x18]
cmp eax, ebx
je 0x4064ff
mov ecx, dword [esi + 0x1c]
sub ecx, eax
mov eax, dword [esp + 0x14]
sar ecx, 4
cmp eax, ecx
jae 0x4064ff
mov edx, dword [0x475b40]
mov eax, dword [0x475b44]
mov ecx, dword [0x475b48]
mov dword [esp + 0x70], edx
mov edx, dword [esp + 0x24]
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], ecx
mov eax, dword [edx + edi + 4]
cmp eax, ebx
jne 0x405b94
xor ecx, ecx
jmp 0x405b9d
mov ecx, dword [edx + edi + 8]
sub ecx, eax
sar ecx, 2
xor eax, eax
cmp ecx, ebx
mov dword [esp + 0x30], ecx
jle 0x405bff
mov ebp, dword [esi + 0x78]
mov ecx, dword [edx + edi + 4]
inc eax
fld dword [esp + 0x70]
mov ecx, dword [ecx + eax*4 - 4]
lea ebx, [ecx + ecx*2]
lea ecx, [ecx + ebx*4]
fadd dword [ebp + ecx*4 + 0xc]
fstp dword [esp + 0x70]
mov ecx, dword [edx + edi + 4]
fld dword [esp + 0x74]
mov ecx, dword [ecx + eax*4 - 4]
lea ebx, [ecx + ecx*2]
lea ecx, [ecx + ebx*4]
fadd dword [ebp + ecx*4 + 0x10]
fstp dword [esp + 0x74]
mov ecx, dword [edx + edi + 4]
fld dword [esp + 0x78]
mov ecx, dword [ecx + eax*4 - 4]
lea ebx, [ecx + ecx*2]
lea ecx, [ecx + ebx*4]
fadd dword [ebp + ecx*4 + 0x14]
cmp eax, dword [esp + 0x30]
fstp dword [esp + 0x78]
jl 0x405baa
lea edx, [esp + 0x70]
lea eax, [esp + 0x60]
push edx
push eax
call fcn.004043a0
mov ebp, dword [esi + 0x28]
mov ebx, dword [esp + 0x50]
mov edx, eax
add ebp, ebx
add esp, 8
add ebx, 0xc
mov eax, dword [edx]
add edi, 0x10
mov dword [esp + 0x48], ebx
mov ecx, dword [edx + 4]
mov edx, dword [edx + 8]
mov dword [ebp], eax
mov dword [ebp + 4], ecx
mov dword [ebp + 8], edx
mov edx, dword [esp + 0x14]
inc edx
xor ebx, ebx
mov dword [esp + 0x14], edx
jmp 0x405b48
mov al, byte [esp + 0x13]
xor edx, edx
mov byte [esp + 0x50], al
mov dword [esp + 0x54], edx
mov dword [esp + 0x58], ebx
mov dword [esp + 0x5c], ebx
mov cl, byte [esp + 0x13]
mov dword [esp + 0x3c], ebx
mov byte [esp + 0x38], cl
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
mov ecx, dword [esi + 0x18]
mov byte [esp + 0x124], 3
cmp ecx, ebx
jne 0x405c84
xor eax, eax
jmp 0x405c8c
mov eax, dword [esi + 0x1c]
sub eax, ecx
sar eax, 4
cmp eax, ebx
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], ebx
jbe 0x4061d5
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x48], ebx
mov dword [esp + 0x1c], ebx
mov eax, dword [esp + 0x1c]
mov eax, dword [ecx + eax + 4]
cmp eax, ebx
je 0x4061a8
mov edi, dword [esp + 0x1c]
mov ebp, dword [ecx + edi + 8]
sub ebp, eax
sar ebp, 2
mov dword [esp + 0x4c], ebp
je 0x4061a8
mov ecx, dword [esp + 0x58]
push ecx
push edx
lea ecx, [esp + 0x58]
call fcn.0040b130
mov edx, dword [esp + 0x40]
mov eax, dword [esp + 0x3c]
push edx
push eax
lea ecx, [esp + 0x40]
call fcn.0040aee0
mov ecx, dword [esp + 0x24]
mov edx, edi
mov eax, dword [ecx + edx + 4]
mov ecx, dword [esi + 0x78]
mov eax, dword [eax]
lea edx, [eax + eax*2]
lea eax, [eax + edx*4]
lea eax, [ecx + eax*4 + 8]
mov ecx, dword [esp + 0x58]
push eax
push ecx
lea ecx, [esp + 0x58]
call fcn.0040af90
mov dl, byte [esp + 0x13]
mov dword [esp + 0x64], ebx
mov byte [esp + 0x60], dl
mov dword [esp + 0x68], ebx
mov dword [esp + 0x6c], ebx
mov eax, dword [esp + 0x54]
mov byte [esp + 0x124], 4
cmp eax, ebx
jne 0x405d41
xor edi, edi
jmp 0x405d4a
mov edi, dword [esp + 0x58]
sub edi, eax
sar edi, 2
lea ecx, [esp + 0x38]
call fcn.00409880
cmp eax, edi
jae 0x405d80
mov eax, dword [esp + 0x40]
lea ecx, [esp + 0x60]
push ecx
lea ecx, [esp + 0x3c]
mov dword [esp + 0x38], eax
call fcn.00409880
mov edx, dword [esp + 0x38]
sub edi, eax
push edi
push edx
lea ecx, [esp + 0x44]
call fcn.0040b170
jmp 0x405da5
lea ecx, [esp + 0x38]
call fcn.00409880
cmp edi, eax
jae 0x405da5
mov ecx, dword [esp + 0x3c]
mov eax, dword [esp + 0x40]
shl edi, 4
add edi, ecx
push eax
push edi
lea ecx, [esp + 0x40]
call fcn.0040aee0
mov ecx, dword [esp + 0x68]
mov edx, dword [esp + 0x64]
push ecx
push edx
lea ecx, [esp + 0x68]
mov byte [esp + 0x12c], 3
call fcn.00409620
mov eax, dword [esp + 0x64]
push eax
call fcn.004273b2
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x20]
add esp, 4
mov dword [esp + 0x64], ebx
mov eax, dword [ecx + edx + 4]
mov ecx, dword [esp + 0x54]
cmp ecx, ebx
mov dword [esp + 0x68], ebx
mov eax, dword [eax]
mov dword [esp + 0x6c], ebx
mov dword [esp + 0x94], eax
jne 0x405dfa
xor eax, eax
jmp 0x405e03
mov eax, dword [esp + 0x58]
sub eax, ecx
sar eax, 2
mov ecx, dword [esp + 0x3c]
lea edx, [esp + 0x94]
shl eax, 4
push edx
lea eax, [eax + ecx - 0x10]
mov ecx, dword [eax + 8]
push ecx
mov ecx, eax
call fcn.0040af90
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x54]
xor edi, edi
cmp ebp, ebx
jle 0x406028
mov byte [esp + 0x13], 0
xor ebp, ebp
mov dword [esp + 0x30], ebx
cmp edx, ebx
je 0x405eb9
mov eax, dword [esp + 0x58]
sub eax, edx
sar eax, 2
cmp ebp, eax
jae 0x405eb9
mov eax, dword [esp + 0x1c]
mov eax, dword [ecx + eax + 4]
mov eax, dword [eax + edi*4]
lea ebx, [eax + eax*2]
lea eax, [eax + ebx*4]
mov ebx, dword [esi + 0x78]
mov eax, dword [ebx + eax*4 + 8]
mov ebx, dword [edx + ebp*4]
cmp eax, ebx
jne 0x405ea9
mov edx, dword [esp + 0x1c]
mov eax, dword [ecx + edx + 4]
mov edx, dword [esp + 0x3c]
mov ecx, dword [eax + edi*4]
mov eax, dword [esp + 0x30]
mov dword [esp + 0x8c], ecx
lea ecx, [edx + eax]
lea edx, [esp + 0x8c]
push edx
mov eax, dword [ecx + 8]
push eax
call fcn.0040af90
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x54]
mov byte [esp + 0x13], 1
mov eax, dword [esp + 0x30]
inc ebp
add eax, 0x10
xor ebx, ebx
mov dword [esp + 0x30], eax
jmp 0x405e3e
mov al, byte [esp + 0x13]
test al, al
jne 0x40601b
mov edx, dword [esp + 0x1c]
mov ecx, dword [ecx + edx + 4]
mov edx, dword [esi + 0x78]
mov eax, dword [ecx + edi*4]
lea ecx, [eax + eax*2]
lea eax, [eax + ecx*4]
mov ecx, dword [esp + 0x58]
lea eax, [edx + eax*4 + 8]
push eax
push ecx
lea ecx, [esp + 0x58]
call fcn.0040af90
mov dl, byte [esp + 0x13]
mov dword [esp + 0x80], ebx
mov byte [esp + 0x7c], dl
mov dword [esp + 0x84], ebx
mov dword [esp + 0x88], ebx
mov eax, dword [esp + 0x54]
mov byte [esp + 0x124], 5
cmp eax, ebx
jne 0x405f1d
xor ebp, ebp
jmp 0x405f26
mov ebp, dword [esp + 0x58]
sub ebp, eax
sar ebp, 2
lea ecx, [esp + 0x38]
call fcn.00409880
cmp eax, ebp
jae 0x405f5c
mov eax, dword [esp + 0x40]
lea ecx, [esp + 0x7c]
push ecx
lea ecx, [esp + 0x3c]
mov dword [esp + 0x38], eax
call fcn.00409880
mov edx, dword [esp + 0x38]
sub ebp, eax
push ebp
push edx
lea ecx, [esp + 0x44]
call fcn.0040b170
jmp 0x405f81
lea ecx, [esp + 0x38]
call fcn.00409880
cmp ebp, eax
jae 0x405f81
mov ecx, dword [esp + 0x3c]
mov eax, dword [esp + 0x40]
shl ebp, 4
add ebp, ecx
push eax
push ebp
lea ecx, [esp + 0x40]
call fcn.0040aee0
mov ecx, dword [esp + 0x84]
mov edx, dword [esp + 0x80]
push ecx
push edx
lea ecx, [esp + 0x84]
mov byte [esp + 0x12c], 3
call fcn.00409620
mov eax, dword [esp + 0x80]
push eax
call fcn.004273b2
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x20]
add esp, 4
mov dword [esp + 0x80], ebx
mov eax, dword [ecx + edx + 4]
mov ecx, dword [esp + 0x54]
cmp ecx, ebx
mov dword [esp + 0x84], ebx
mov eax, dword [eax + edi*4]
mov dword [esp + 0x88], ebx
mov dword [esp + 0x90], eax
jne 0x405fec
xor eax, eax
jmp 0x405ff5
mov eax, dword [esp + 0x58]
sub eax, ecx
sar eax, 2
mov ecx, dword [esp + 0x3c]
lea edx, [esp + 0x90]
shl eax, 4
push edx
lea eax, [eax + ecx - 0x10]
mov ecx, dword [eax + 8]
push ecx
mov ecx, eax
call fcn.0040af90
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x54]
mov eax, dword [esp + 0x4c]
inc edi
cmp edi, eax
jl 0x405e33
cmp edx, ebx
je 0x4061a8
mov eax, dword [esp + 0x58]
sub eax, edx
sar eax, 2
cmp eax, 1
jbe 0x4061a8
mov dword [esp + 0x30], 1
mov edi, 0x10
cmp edx, ebx
je 0x4061a8
mov eax, dword [esp + 0x58]
mov ebp, dword [esp + 0x30]
sub eax, edx
sar eax, 2
cmp ebp, eax
jae 0x4061a8
mov ecx, dword [esi + 0x18]
mov ebp, dword [esp + 0x1c]
mov edx, dword [esi + 0x1c]
add ecx, ebp
lea ebp, [esi + 0x14]
push ecx
push edx
mov ecx, ebp
call fcn.00409690
mov eax, dword [esi + 0x28]
mov edx, dword [esp + 0x48]
lea ecx, [esi + 0x24]
add eax, edx
push eax
mov edx, dword [ecx + 8]
push edx
call fcn.00409c20
mov eax, dword [esi + 0x58]
mov edx, dword [esp + 0x14]
lea ecx, [esi + 0x54]
lea eax, [eax + edx*8]
mov edx, dword [ecx + 8]
push eax
push edx
call fcn.0040a1c0
mov eax, dword [esi + 0x48]
mov edx, dword [esp + 0x48]
lea ecx, [esi + 0x44]
add eax, edx
push eax
mov edx, dword [ecx + 8]
push edx
call fcn.00409c20
mov eax, dword [esi + 0x38]
mov edx, dword [esp + 0x48]
lea ecx, [esi + 0x34]
add eax, edx
push eax
mov edx, dword [ecx + 8]
push edx
call fcn.00409c20
mov eax, dword [ebp + 4]
cmp eax, ebx
jne 0x4060e8
xor ebp, ebp
jmp 0x4060f0
mov ebp, dword [ebp + 8]
sub ebp, eax
sar ebp, 4
mov eax, dword [esp + 0x3c]
dec ebp
mov dword [esp + 0x34], ebp
xor edx, edx
mov ecx, dword [eax + edi + 4]
cmp ecx, ebx
je 0x40618f
mov ebp, dword [eax + edi + 8]
sub ebp, ecx
sar ebp, 2
cmp edx, ebp
jae 0x40618f
mov ecx, dword [ecx + edx*4]
mov ebp, dword [esp + 0x14]
lea ebx, [ecx + ecx*2]
lea ecx, [ecx + ebx*4]
mov ebx, dword [esi + 0x78]
lea ecx, [ebx + ecx*4]
xor ebx, ebx
mov bx, word [ecx]
cmp ebx, ebp
mov ebx, dword [esp + 0x34]
jne 0x40613b
mov word [ecx], bx
mov eax, dword [esp + 0x3c]
mov ecx, dword [eax + edi + 4]
mov ecx, dword [ecx + edx*4]
lea ebp, [ecx + ecx*2]
lea ecx, [ecx + ebp*4]
mov ebp, dword [esi + 0x78]
lea ecx, [ebp + ecx*4 + 2]
xor ebp, ebp
mov bp, word [ecx]
cmp ebp, dword [esp + 0x14]
jne 0x406161
mov word [ecx], bx
mov eax, dword [esp + 0x3c]
mov ecx, dword [eax + edi + 4]
mov ecx, dword [ecx + edx*4]
lea ebp, [ecx + ecx*2]
lea ecx, [ecx + ebp*4]
mov ebp, dword [esi + 0x78]
lea ecx, [ebp + ecx*4 + 4]
xor ebp, ebp
mov bp, word [ecx]
cmp ebp, dword [esp + 0x14]
jne 0x406187
mov word [ecx], bx
mov eax, dword [esp + 0x3c]
inc edx
xor ebx, ebx
jmp 0x4060fb
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x54]
inc ecx
add edi, 0x10
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x24]
jmp 0x40604f
mov edi, dword [esp + 0x1c]
mov eax, dword [esp + 0x14]
mov ebp, dword [esp + 0x48]
add edi, 0x10
mov dword [esp + 0x1c], edi
mov edi, dword [esp + 0x18]
inc eax
add ebp, 0xc
cmp eax, edi
mov dword [esp + 0x14], eax
mov dword [esp + 0x48], ebp
jb 0x405ca8
jmp 0x4061d9
mov ecx, dword [esp + 0x24]
xor ebp, ebp
xor ebx, ebx
mov dword [esp + 0x14], ebp
mov eax, dword [esp + 0x28]
cmp ecx, ebp
je 0x406233
mov edi, dword [esp + 0x14]
mov edx, eax
sub edx, ecx
sar edx, 4
cmp edi, edx
jae 0x406233
mov eax, dword [ecx + ebx + 8]
lea edi, [ecx + ebx]
mov ecx, dword [ecx + ebx + 4]
push ecx
push eax
push eax
call fcn.0040c560
add esp, 0xc
mov ebp, eax
mov eax, dword [edi + 8]
mov ecx, edi
push eax
push ebp
call fcn.00409620
mov ecx, dword [esp + 0x14]
mov dword [edi + 8], ebp
inc ecx
add ebx, 0x10
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0x24]
xor ebp, ebp
jmp 0x4061e1
push ecx
push eax
push eax
call fcn.0040c3d0
mov ecx, dword [esp + 0x34]
add esp, 0xc
mov ebx, eax
push ecx
push ebx
lea ecx, [esp + 0x28]
call fcn.0040af50
mov dl, byte [esp + 0x13]
mov dword [esp + 0x28], ebx
mov byte [esp + 0x60], dl
mov dword [esp + 0x64], ebp
mov dword [esp + 0x68], ebp
mov dword [esp + 0x6c], ebp
mov eax, dword [esi + 0x18]
mov byte [esp + 0x124], 6
cmp eax, ebp
jne 0x40627a
xor edi, edi
jmp 0x406282
mov edi, dword [esi + 0x1c]
sub edi, eax
sar edi, 4
mov ecx, dword [esp + 0x24]
cmp ecx, ebp
jne 0x40628e
xor eax, eax
jmp 0x406295
mov eax, ebx
sub eax, ecx
sar eax, 4
cmp eax, edi
jae 0x4062b6
lea eax, [esp + 0x60]
lea ecx, [esp + 0x20]
push eax
call fcn.00409880
sub edi, eax
lea ecx, [esp + 0x24]
push edi
push ebx
call fcn.0040ac50
jmp 0x4062db
lea ecx, [esp + 0x20]
call fcn.00409880
cmp edi, eax
jae 0x4062db
mov ecx, dword [esp + 0x28]
push ecx
mov ecx, dword [esp + 0x28]
shl edi, 4
add edi, ecx
lea ecx, [esp + 0x24]
push edi
call fcn.0040aee0
mov edx, dword [esp + 0x64]
mov byte [esp + 0x124], 3
push edx
call fcn.004273b2
add esp, 4
xor ebx, ebx
xor edi, edi
xor ebp, ebp
mov eax, dword [esi + 0x68]
cmp eax, ebx
je 0x40639d
mov ecx, dword [esi + 0x6c]
sub ecx, eax
mov eax, 0x2aaaaaab
imul ecx
mov eax, edx
shr eax, 0x1f
add edx, eax
cmp edi, edx
jae 0x40639d
mov ecx, dword [esi + 0x78]
mov eax, dword [esp + 0x24]
xor edx, edx
mov dword [esp + 0x4c], edi
mov dx, word [ecx + ebp]
mov ecx, edx
shl ecx, 4
add ecx, eax
lea eax, [esp + 0x4c]
push eax
push 1
mov edx, dword [ecx + 8]
push edx
call fcn.00409410
mov eax, dword [esi + 0x78]
mov edx, dword [esp + 0x24]
xor ecx, ecx
mov dword [esp + 0x4c], edi
mov cx, word [eax + ebp + 2]
shl ecx, 4
add ecx, edx
lea edx, [esp + 0x4c]
push edx
push 1
mov eax, dword [ecx + 8]
push eax
call fcn.00409410
mov ecx, dword [esi + 0x78]
mov eax, dword [esp + 0x24]
xor edx, edx
mov dword [esp + 0x4c], edi
mov dx, word [ecx + ebp + 4]
mov ecx, edx
shl ecx, 4
add ecx, eax
lea eax, [esp + 0x4c]
push eax
push 1
mov edx, dword [ecx + 8]
push edx
call fcn.00409410
inc edi
add ebp, 0x34
jmp 0x4062f6
mov dword [esp + 0x14], ebx
mov dword [esp + 0x34], ebx
xor edi, edi
mov eax, dword [esi + 0x18]
cmp eax, ebx
je 0x4064a6
mov ecx, dword [esi + 0x1c]
sub ecx, eax
mov eax, dword [esp + 0x14]
sar ecx, 4
cmp eax, ecx
jae 0x4064a6
mov edx, dword [0x475b40]
mov eax, dword [0x475b44]
mov ecx, dword [0x475b48]
mov dword [esp + 0x70], edx
mov edx, dword [esp + 0x24]
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], ecx
mov eax, dword [edx + edi + 4]
cmp eax, ebx
jne 0x4063f3
xor ecx, ecx
jmp 0x4063fc
mov ecx, dword [edx + edi + 8]
sub ecx, eax
sar ecx, 2
xor eax, eax
cmp ecx, ebx
mov dword [esp + 0x18], ecx
jle 0x40645e
mov ebp, dword [esi + 0x78]
mov ecx, dword [edx + edi + 4]
inc eax
fld dword [esp + 0x70]
mov ecx, dword [ecx + eax*4 - 4]
lea ebx, [ecx + ecx*2]
lea ecx, [ecx + ebx*4]
fadd dword [ebp + ecx*4 + 0xc]
fstp dword [esp + 0x70]
mov ecx, dword [edx + edi + 4]
fld dword [esp + 0x74]
mov ecx, dword [ecx + eax*4 - 4]
lea ebx, [ecx + ecx*2]
lea ecx, [ecx + ebx*4]
fadd dword [ebp + ecx*4 + 0x10]
fstp dword [esp + 0x74]
mov ecx, dword [edx + edi + 4]
fld dword [esp + 0x78]
mov ecx, dword [ecx + eax*4 - 4]
lea ebx, [ecx + ecx*2]
lea ecx, [ecx + ebx*4]
fadd dword [ebp + ecx*4 + 0x14]
cmp eax, dword [esp + 0x18]
fstp dword [esp + 0x78]
jl 0x406409
lea edx, [esp + 0x70]
lea eax, [esp + 0x60]
push edx
push eax
call fcn.004043a0
mov ebp, dword [esi + 0x28]
mov ebx, dword [esp + 0x3c]
mov edx, eax
add ebp, ebx
add esp, 8
add ebx, 0xc
mov eax, dword [edx]
add edi, 0x10
mov dword [esp + 0x34], ebx
mov ecx, dword [edx + 4]
mov edx, dword [edx + 8]
mov dword [ebp], eax
mov dword [ebp + 4], ecx
mov dword [ebp + 8], edx
mov edx, dword [esp + 0x14]
inc edx
xor ebx, ebx
mov dword [esp + 0x14], edx
jmp 0x4063a7
mov ebp, dword [esp + 0x40]
mov edi, dword [esp + 0x3c]
cmp edi, ebp
mov byte [esp + 0x124], 2
je 0x4064cc
mov ecx, edi
call fcn.00409200
add edi, 0x10
cmp edi, ebp
jne 0x4064ba
mov edi, dword [esp + 0x3c]
push edi
call fcn.004273b2
mov eax, dword [esp + 0x58]
mov dword [esp + 0x40], ebx
push eax
mov dword [esp + 0x48], ebx
mov dword [esp + 0x4c], ebx
mov byte [esp + 0x12c], 0
call fcn.004273b2
add esp, 8
mov dword [esp + 0x54], ebx
mov dword [esp + 0x58], ebx
mov dword [esp + 0x5c], ebx
xor ebx, ebx
xor ebp, ebp
xor edi, edi
mov eax, dword [esi + 0x68]
test eax, eax
je 0x40655a
mov ecx, dword [esi + 0x6c]
sub ecx, eax
mov eax, 0x2aaaaaab
imul ecx
mov ecx, edx
shr ecx, 0x1f
add edx, ecx
cmp ebx, edx
jae 0x40655a
mov edx, dword [esi + 0x78]
mov eax, dword [esi + 0x68]
inc ebx
mov cx, word [edx + edi]
add edi, 0x34
mov word [eax + ebp], cx
mov edx, dword [esi + 0x78]
mov eax, dword [esi + 0x68]
add ebp, 6
mov cx, word [edx + edi - 0x32]
mov word [eax + ebp - 4], cx
mov edx, dword [esi + 0x78]
mov eax, dword [esi + 0x68]
mov cx, word [edx + edi - 0x30]
mov word [eax + ebp - 2], cx
jmp 0x406505
mov eax, dword [esp + 0x28]
mov esi, dword [esp + 0x24]
cmp esi, eax
mov dword [esp + 0x124], 0xffffffff
mov ebp, eax
je 0x4065b2
add esi, 4
mov ebx, dword [esi + 4]
mov edi, dword [esi]
cmp edi, ebx
je 0x40658f
push edi
call fcn.00403b20
add edi, 4
add esp, 4
cmp edi, ebx
jne 0x40657f
mov edx, dword [esi]
push edx
call fcn.004273b2
xor eax, eax
add esp, 4
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
add esi, 0x10
lea eax, [esi - 4]
cmp eax, ebp
jne 0x406576
mov esi, dword [esp + 0x24]
push esi
call fcn.004273b2
mov ecx, dword [esp + 0x120]
add esp, 4
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x118
ret 4