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

Disassembly:
sub esp, 0x500
mov eax, dword [esp + 0x504]
push ebp
push esi
mov esi, ecx
push eax
call fcn.00408ed6
mov ecx, dword [esp + 0x514]
mov dword [esp + 0x38], eax
push ecx
call fcn.00408ed6
mov edx, dword [esp + 0x51c]
mov dword [esp + 0x44], eax
push edx
call fcn.00408ed6
mov dword [esp + 0x3c], eax
mov eax, dword [esi + 0xc]
imul eax, dword [esi + 8]
add esp, 0xc
xor ebp, ebp
lea ecx, [eax + eax*2]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 5
mov eax, edx
mov dword [esp + 0x2c], ebp
shr eax, 0x1f
add edx, eax
mov dword [esp + 0x44], ebp
mov dword [esp + 0x58], ebp
mov dword [esp + 0x18], ebp
mov dword [esp + 0x14], ebp
je 0x4023e9
push ebx
push edi
mov dword [esp + 0x40], edx
mov eax, dword [esp + 0x3c]
mov dl, 1
mov bl, dl
cmp ebp, eax
mov byte [esp + 0x13], bl
mov byte [esp + 0x12], dl
jae 0x4022cc
jmp 0x401fff
mov dl, byte [esp + 0x1b]
mov ebp, dword [esp + 0x28]
mov edi, dword [esp + 0x514]
xor eax, eax
lea ecx, [esp + 0x110]
add edi, ebp
xor ebx, ebx
add ecx, 4
mov bl, byte [edi + eax]
sub ebx, 0x80
inc eax
mov dword [esp + 0x14], ebx
cmp eax, 0x40
fild dword [esp + 0x14]
fstp dword [ecx - 4]
jb 0x402011
test dl, dl
jbe 0x4022c8
lea ecx, [esp + 0x110]
dec dl
add ebp, 0x40
push ecx
mov ecx, esi
mov byte [esp + 0x1f], dl
mov dword [esp + 0x2c], ebp
mov byte [esp + 0x28], 0
call fcn.00402910
mov ebx, 0x4215d0
lea ebp, [esp + 0x110]
lea edi, [esi + 0x109c]
mov dword [esp + 0x14], 0x40
fld dword [edi]
fmul dword [ebp]
fadd qword [0x421830]
fsub qword [0x421828]
call fcn.00408f6c
xor edx, edx
add edi, 4
mov dl, byte [ebx]
add ebp, 4
inc ebx
mov word [esp + edx*2 + 0x90], ax
mov eax, dword [esp + 0x14]
dec eax
mov dword [esp + 0x14], eax
jne 0x402073
mov eax, dword [esp + 0x90]
mov ecx, dword [esp + 0x34]
mov edi, eax
mov dword [esp + 0x34], eax
sub edi, ecx
test di, di
jne 0x4020e3
mov eax, dword [esi + 0x129c]
mov cx, word [esi + 0x12a0]
mov dword [esp + 0x7c], eax
mov word [esp + 0x80], cx
mov edx, dword [esp + 0x7e]
push edx
push eax
jmp 0x40216a
mov ecx, dword [esi + 0x1018]
xor edx, edx
movsx eax, di
mov dl, byte [ecx + eax]
mov eax, edx
lea ecx, [eax + eax*2]
lea eax, [esi + 0x129c]
lea edx, [eax + ecx*2]
mov eax, dword [eax + ecx*2]
mov dword [esp + 0x74], eax
mov cx, word [edx + 4]
mov word [esp + 0x78], cx
mov edx, dword [esp + 0x76]
push edx
push eax
mov ecx, esi
call fcn.00402b80
push edi
mov ecx, esi
call fcn.00402eb0
mov byte [esp + 0x2e], al
mov ebx, dword [esp + 0x2e]
test di, di
jl 0x402138
mov word [esp + 0x2c], di
jmp 0x402164
fld qword [0x421820]
mov eax, ebx
and eax, 0xff
mov dword [esp + 0x14], eax
fild dword [esp + 0x14]
call fcn.00408fa0
fsub qword [0x421810]
call fcn.00408f6c
add eax, edi
mov word [esp + 0x2c], ax
mov ecx, dword [esp + 0x2c]
push ebx
push ecx
mov ecx, esi
call fcn.00402b80
mov bl, 0x3f
mov byte [esp + 0x48], bl
mov edx, dword [esp + 0x48]
and edx, 0xff
cmp word [esp + edx*2 + 0x90], 0
jne 0x402194
dec bl
mov byte [esp + 0x48], bl
jne 0x402177
test bl, bl
jne 0x4021b7
mov eax, dword [esi + 0x132c]
mov cx, word [esi + 0x1330]
mov dword [esp + 0x64], eax
mov word [esp + 0x68], cx
mov edx, dword [esp + 0x66]
jmp 0x4022a7
lea eax, [esp + 0x24]
lea ecx, [esp + 0x310]
push eax
lea edx, [esp + 0x94]
push ecx
push edx
mov ecx, esi
call fcn.00402c40
mov al, byte [esp + 0x24]
xor ebp, ebp
test al, al
jbe 0x402288
lea edi, [esp + 0x311]
mov cl, byte [edi]
test cl, cl
jne 0x40220b
lea eax, [esi + 0x18cc]
mov ecx, eax
mov eax, dword [ecx]
mov dword [esp + 0x6c], eax
mov dx, word [ecx + 4]
mov word [esp + 0x70], dx
mov ecx, dword [esp + 0x6e]
jmp 0x402269
xor eax, eax
and ecx, 0xff
mov al, byte [edi - 1]
shl eax, 4
add eax, ecx
lea edx, [eax + eax*2]
lea eax, [esi + 0x132c]
lea eax, [eax + edx*2]
mov ecx, eax
mov eax, dword [ecx]
mov dword [esp + 0x50], eax
mov dx, word [ecx + 4]
mov word [esp + 0x54], dx
mov ecx, dword [esp + 0x52]
push ecx
push eax
mov ecx, esi
call fcn.00402b80
mov dx, word [edi + 1]
lea eax, [esp + 0x8c]
push edx
push eax
mov ecx, esi
call fcn.00402d80
mov eax, dword [eax]
mov dword [esp + 0x84], eax
mov ecx, dword [esp + 0x86]
push ecx
push eax
mov ecx, esi
call fcn.00402b80
mov edx, dword [esp + 0x24]
inc ebp
and edx, 0xff
add edi, 4
cmp ebp, edx
jb 0x4021e8
cmp bl, 0x3f
je 0x4022b0
mov eax, dword [esi + 0x132c]
mov cx, word [esi + 0x1330]
mov dword [esp + 0x58], eax
mov word [esp + 0x5c], cx
mov edx, dword [esp + 0x5a]
push edx
push eax
mov ecx, esi
call fcn.00402b80
mov eax, dword [esp + 0x3c]
mov ecx, dword [esp + 0x28]
cmp ecx, eax
jb 0x401ff7
mov bl, byte [esp + 0x13]
mov ebp, ecx
jmp 0x4022cc
mov bl, byte [esp + 0x13]
mov ecx, dword [esp + 0x44]
mov eax, dword [esp + 0x20]
cmp eax, ecx
jae 0x40234d
mov edx, dword [esp + 0x20]
mov edi, dword [esp + 0x518]
xor eax, eax
lea ecx, [esp + 0x210]
add edi, edx
xor edx, edx
add ecx, 4
mov dl, byte [edi + eax]
sub edx, 0x80
inc eax
mov dword [esp + 0x14], edx
cmp eax, 0x40
fild dword [esp + 0x14]
fstp dword [ecx - 4]
jb 0x4022ee
test bl, bl
jbe 0x40234d
mov edi, dword [esp + 0x20]
lea eax, [esp + 0x4c]
lea ecx, [esi + 0x192c]
push eax
lea edx, [esi + 0x12e4]
push ecx
lea eax, [esi + 0x119c]
push edx
lea ecx, [esp + 0x21c]
push eax
add edi, 0x40
push ecx
mov ecx, esi
dec bl
mov dword [esp + 0x34], edi
call fcn.00402400
cmp edi, dword [esp + 0x44]
jb 0x4022d8
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x1c]
cmp eax, edx
jae 0x4023d8
mov edx, dword [esp + 0x1c]
mov edi, dword [esp + 0x51c]
xor eax, eax
lea ecx, [esp + 0x410]
add edi, edx
xor edx, edx
add ecx, 4
mov dl, byte [edi + eax]
sub edx, 0x80
inc eax
mov dword [esp + 0x14], edx
cmp eax, 0x40
fild dword [esp + 0x14]
fstp dword [ecx - 4]
jb 0x40236f
mov al, byte [esp + 0x12]
test al, al
jbe 0x4023d8
mov cl, al
mov edi, dword [esp + 0x1c]
dec cl
lea eax, [esp + 0x60]
mov byte [esp + 0x12], cl
lea ecx, [esi + 0x192c]
push eax
lea edx, [esi + 0x12e4]
push ecx
lea eax, [esi + 0x119c]
push edx
lea ecx, [esp + 0x41c]
push eax
add edi, 0x40
push ecx
mov ecx, esi
mov dword [esp + 0x30], edi
call fcn.00402400
cmp edi, dword [esp + 0x38]
jb 0x402359
mov eax, dword [esp + 0x40]
dec eax
mov dword [esp + 0x40], eax
jne 0x401fdd
pop edi
pop ebx
pop esi
pop ebp
add esp, 0x500
ret 0xc