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

Disassembly:
sub esp, 0x368
fldz
xor eax, eax
mov word [esp + 0x1c], ax
fst qword [esp + 0x48]
fldz
xor ecx, ecx
mov word [esp + 0x2c], cx
fst dword [esp + 0xc]
fst dword [esp + 0x28]
xor edx, edx
fxch st(1)
fst qword [esp + 0x50]
mov word [esp + 0x18], dx
mov word [esp + 0x1c], ax
mov word [esp + 0x20], cx
mov dx, word [esp + 0x1c]
movsx eax, dx
cmp eax, 0x2751d80e
jg 0x406323
fld dword [str.4ZP8p]
mov cx, word [esp + 0x20]
fadd qword [0x41f7a0]
movsx edx, cx
sub edx, 0x42a1f109
mov dword [esp], edx
fsub qword [0x41f798]
fild dword [esp]
fucompp
fnstsw ax
fld dword [str.4ZP8p]
fadd qword [0x41f350]
fstp dword [str.4ZP8p]
test ah, 0x44
jp 0x406317
fld qword [0x425f68]
fld dword [0x423980]
fsubr qword [0x41f790]
fsubp st(1)
fstp qword [0x425f68]
jmp 0x406323
fld dword [0x41f788]
fstp dword [0x4242bc]
fld qword [0x4243b0]
push ebx
fsub qword [0x41f780]
push edi
mov edi, dword [esp + 0x380]
mov ebx, 1
fstp qword [0x4243b0]
lea edx, [esp + 0x60]
fstp qword [esp + 8]
fstp dword [esp + 8]
mov ax, word [0x423958]
movsx ecx, ax
sub ecx, 0x1c17c860
mov dword [esp + 0x2c], ecx
lea eax, [esp + 0x64]
push eax
fild dword [esp + 0x30]
push edi
fmul dword [esp + 0x10]
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], ebx
mov dword [esp + 0x70], ebx
fstp dword [esp + 0x10]
mov dword [esp + 0x74], edx
call fcn.004017e0
add esp, 8
test eax, eax
jl 0x406b62
mov ecx, dword [edi + 8]
test byte [ecx], bl
je 0x406b62
fld qword [esp + 0x50]
lea edx, [esp + 0x1c]
fsub qword [0x41f778]
push edi
push edx
fsub qword [0x423a50]
fstp qword [esp + 0x58]
call fcn.004012a0
push 0
lea eax, [esp + 0x44]
push eax
lea ecx, [esp + 0x54]
push ecx
call fcn.00402f80
fld qword [0x4242c0]
fsub qword [0x41f350]
fstp qword [0x4242c0]
mov dx, word [esp + 0x3c]
movsx eax, dx
mov dword [esp + 0x1c], eax
fild dword [esp + 0x1c]
fsub qword [0x4242c0]
mov cx, word [esp + 0x48]
mov eax, dword [0x423b38]
movsx edx, cx
mov dword [esp + 0x1c], edx
fild dword [esp + 0x1c]
mov dword [esp + 0x1c], eax
faddp st(1)
fild dword [esp + 0x1c]
faddp st(1)
call fcn.0040b5b0
push 0x300
lea ecx, [esp + 0x88]
push 0
mov dword [0x423b38], eax
push ecx
call fcn.0040b530
fld dword [esp + 0x34]
fsub qword [0x41f770]
mov edx, dword [esp + 0x39c]
push edx
fstp dword [esp + 0x38]
call fcn.00401110
fld dword [esp + 0x54]
add esp, 0x24
cmp eax, 0x29f
fmul qword [esp + 0x58]
fstp qword [esp + 0x58]
jle 0x406475
mov dword [esp + 0x18], 6
jmp 0x4064a5
cmp eax, 0xef
jle 0x406486
mov dword [esp + 0x18], 5
jmp 0x4064a5
cmp eax, 0x4f
jle 0x406495
mov dword [esp + 0x18], 4
jmp 0x4064a5
xor ecx, ecx
cmp eax, 0x17
setg cl
lea ecx, [ecx + ecx + 1]
mov dword [esp + 0x18], ecx
push ebp
push esi
mov esi, dword [edi + 4]
add esi, ebx
mov ebx, dword [esp + 0x37c]
push esi
push ebx
call fcn.004011c0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a56
lea edx, [esp + 0x84]
push esi
push edx
call fcn.004011c0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a56
lea eax, [esi + esi]
push eax
lea ecx, [esp + 0x44]
push ecx
call fcn.004011c0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a56
mov ebp, dword [esp + 0x38c]
test ebp, ebp
je 0x40652a
cmp dword [ebp + 8], eax
je 0x40652a
mov edx, dword [ebp]
mov eax, dword [ebp + 4]
mov ecx, dword [ebp + 8]
mov dword [esp + 0x4c], edx
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], ecx
jmp 0x40659b
lea edx, [esp + 0x4c]
push 1
push edx
call fcn.004022c0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a5d
mov eax, dword [edi + 4]
shl eax, 6
push eax
lea ecx, [esp + 0x50]
push ecx
call fcn.00401ea0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a5d
lea edx, [esp + 0x4c]
push edi
push edx
mov eax, edx
push eax
call fcn.00405b10
add esp, 0xc
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a5d
test ebp, ebp
je 0x40659b
mov ecx, dword [esp + 0x4c]
mov edx, dword [esp + 0x50]
mov eax, dword [esp + 0x54]
mov dword [ebp], ecx
mov dword [ebp + 4], edx
mov dword [ebp + 8], eax
mov esi, dword [esp + 0x380]
push edi
push esi
call fcn.004017e0
add esp, 8
test eax, eax
jl 0x4065c4
push edi
lea ecx, [esp + 0x88]
push esi
push ecx
call fcn.00405b10
add esp, 0xc
jmp 0x4065d5
lea edx, [esp + 0x84]
push esi
push edx
call fcn.00402000
add esp, 8
mov ecx, dword [esp + 0x24]
lea eax, [esp + 0x40]
push eax
push ecx
push edi
lea edx, [esp + 0x58]
push edx
lea eax, [esp + 0x94]
push eax
call fcn.00403ec0
fld qword [0x423a20]
fadd qword [esp + 0x6c]
fadd dword [0x42356c]
mov cx, word [esp + 0x44]
movsx edx, cx
mov dword [esp + 0x24], edx
fild dword [esp + 0x24]
fmulp st(1)
call fcn.0040b5b0
mov word [esp + 0x44], ax
fld dword [0x42356c]
fsub qword [0x41f350]
lea eax, [esp + 0x60]
push eax
push ebx
fstp dword [0x42356c]
call fcn.00402000
add esp, 0x1c
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a5d
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0x40]
push ecx
push edx
push edi
push ebx
call fcn.00405680
mov ebp, dword [esp + 0x30]
add esp, 0x10
cmp ebp, 1
jle 0x40673f
mov eax, dword [edi + 4]
dec ebp
mov ecx, ebp
mov ebx, 1
shl ebx, cl
inc eax
push eax
lea esi, [ebx + ebx*2]
lea esi, [esp + esi*4 + 0x7c]
push esi
call fcn.004011c0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a56
lea ecx, [esp + 0x84]
push ecx
push esi
call fcn.00402000
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a56
test ebp, ebp
jle 0x4066d1
mov eax, dword [esp + 0x24]
lea edx, [esp + 0x40]
push edx
push eax
push edi
push esi
push esi
call fcn.00403ec0
add esp, 0x14
sub ebp, 1
jne 0x4066b7
mov ecx, dword [esp + 0x20]
mov ebp, 1
shl ebp, cl
inc ebx
cmp ebx, ebp
jge 0x40673f
lea esi, [ebx + ebx*2]
lea esi, [esp + esi*4 + 0x78]
mov ecx, dword [edi + 4]
inc ecx
push ecx
push esi
call fcn.004011c0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a56
lea edx, [esi - 0xc]
push edx
push esi
call fcn.00402000
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x406a56
mov ecx, dword [esp + 0x24]
lea eax, [esp + 0x40]
push eax
push ecx
push edi
lea edx, [esp + 0x90]
push edx
push esi
call fcn.00403ec0
inc ebx
add esp, 0x14
add esi, 0xc
cmp ebx, ebp
jl 0x4066e8
fld dword [esp + 0x38]
fadd qword [esp + 0x60]
mov eax, dword [0x424434]
mov ecx, dword [0x424424]
mov dword [esp + 0x10], eax
fild dword [esp + 0x10]
mov dword [esp + 0x10], ecx
faddp st(1)
fild dword [esp + 0x10]
faddp st(1)
call fcn.0040b5b0
mov edx, dword [esp + 0x384]
mov dword [0x424424], eax
inc dword [0x424434]
mov cx, word [esp + 0x2c]
mov eax, dword [edx + 4]
mov dword [esp + 0x10], eax
movsx edx, cx
mov eax, 0x1e5f1c87
sub eax, edx
add eax, dword [0x424278]
xor ebp, ebp
mov dword [esp + 0x1c], eax
mov dword [esp + 0x34], ebp
mov dword [esp + 0x2c], ebp
fild dword [esp + 0x1c]
fstp dword [esp + 0x1c]
dec dword [0x424278]
xor ebx, ebx
fld1
cmp dword [esp + 0x34], 0
jne 0x4067eb
movzx ecx, word [esp + 0x28]
mov eax, dword [esp + 0x10]
mov edx, eax
add ecx, 0xc664cd7
dec eax
mov word [esp + 0x30], cx
mov dword [esp + 0x10], eax
test edx, edx
je 0x40698e
mov dword [esp + 0x34], 0x20
mov eax, dword [esp + 0x384]
mov edx, dword [eax + 8]
mov ecx, dword [esp + 0x34]
mov eax, dword [esp + 0x10]
mov esi, dword [edx + eax*4]
dec ecx
shr esi, cl
mov dword [esp + 0x34], ecx
and esi, 1
jne 0x406812
cmp dword [esp + 0x2c], esi
je 0x4067b9
fld qword [0x4251f8]
fadd st(1)
fstp qword [0x4251f8]
fld qword [0x4251f8]
mov ecx, dword [0x4238f8]
fsub qword [0x41f768]
mov dword [esp + 0x1c], ecx
fild dword [esp + 0x1c]
fmulp st(1)
call fcn.0040b5b0
mov dword [0x4238f8], eax
test esi, esi
jne 0x406874
cmp dword [esp + 0x2c], 1
jne 0x406874
mov eax, dword [esp + 0x24]
fstp st(0)
lea edx, [esp + 0x40]
push edx
push eax
mov eax, dword [esp + 0x384]
push edi
push eax
push eax
call fcn.00403ec0
add esp, 0x14
jmp 0x4067b7
mov ecx, dword [0x425304]
inc dword [0x425304]
mov edx, 0x7e08ca63
sub edx, ecx
mov dword [esp + 0x2c], 2
cmp edx, 0xf7b210b5
je 0x4068bd
fld qword [0x425f30]
fadd st(1)
fstp qword [0x425f30]
fld qword [0x425f30]
fsub qword [0x41f760]
call fcn.0040b5b0
mov dword [0x424350], eax
jmp 0x4068f7
fld dword [0x425f4c]
mov ax, word [esp + 0x3c]
fsubr qword [0x41f758]
movsx ecx, ax
mov dword [esp + 0x1c], ecx
fild dword [esp + 0x1c]
fsubp st(1)
call fcn.0040b5b0
mov dword [0x4252ec], eax
inc dword [esp + 0x3c]
fld dword [0x425f4c]
fadd st(1)
fstp dword [0x425f4c]
dec word [0x424430]
fld dword [esp + 0x38]
mov dx, word [0x424430]
movsx eax, dx
add eax, 0x6ae54de7
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x20]
inc ebp
fisub dword [esp + 0x1c]
mov ecx, eax
sub ecx, ebp
shl esi, cl
fstp dword [esp + 0x38]
or ebx, esi
cmp ebp, eax
jne 0x4067b9
mov esi, dword [esp + 0x24]
fstp st(0)
mov ebp, eax
test ebp, ebp
jle 0x40695d
mov edi, edi
mov eax, dword [esp + 0x37c]
lea ecx, [esp + 0x40]
push ecx
push esi
push edi
push eax
push eax
call fcn.00403ec0
add esp, 0x14
sub ebp, 1
jne 0x406940
lea edx, [esp + 0x40]
push edx
mov edx, dword [esp + 0x380]
push esi
lea eax, [ebx + ebx*2]
push edi
lea ecx, [esp + eax*4 + 0x84]
push ecx
push edx
call fcn.00403ec0
add esp, 0x14
mov dword [esp + 0x2c], 1
xor ebp, ebp
jmp 0x4067b5
mov ecx, dword [esp + 0x20]
fstp st(0)
mov esi, 1
rol esi, cl
test ebp, ebp
jle 0x4069f7
mov dword [esp + 0x10], ebp
jmp 0x4069b0
mov ecx, dword [esp + 0x24]
mov ebp, dword [esp + 0x37c]
lea eax, [esp + 0x40]
push eax
push ecx
push edi
push ebp
push ebp
call fcn.00403ec0
add ebx, ebx
add esp, 0x14
test ebx, esi
je 0x4069ee
mov eax, dword [esp + 0x24]
lea edx, [esp + 0x40]
push edx
push eax
push edi
lea ecx, [esp + 0x90]
push ecx
push ebp
call fcn.00403ec0
add esp, 0x14
sub dword [esp + 0x10], 1
jne 0x4069b0
jmp 0x4069fe
mov ebp, dword [esp + 0x37c]
mov eax, dword [esp + 0x24]
lea edx, [esp + 0x40]
push edx
push eax
push edi
push ebp
call fcn.00405680
mov cx, word [esp + 0x38]
mov ebp, dword [esp + 0x39c]
movsx edx, cx
add edx, 0x1dec6b3
mov dword [esp + 0x20], edx
add esp, 0x10
fild dword [esp + 0x10]
fld qword [esp + 0x60]
fucompp
fnstsw ax
fld qword [esp + 0x60]
fsub qword [0x41f350]
fstp qword [esp + 0x60]
test ah, 0x44
jnp 0x406a5d
mov eax, 0xffffa80e
mov word [esp + 0x2c], ax
jmp 0x406a5d
mov ebp, dword [esp + 0x38c]
mov esi, dword [esp + 0x20]
lea ecx, [esi - 1]
mov eax, 1
shl eax, cl
mov edx, 1
mov ecx, esi
shl edx, cl
cmp eax, edx
jge 0x406a96
lea esi, [eax + eax*2]
sub edx, eax
lea esi, [esp + esi*4 + 0x78]
mov edi, edx
push 0
push esi
call fcn.00402500
add esp, 8
add esi, 0xc
sub edi, 1
jne 0x406a83
fld qword [esp + 0x58]
mov ecx, dword [0x424280]
fsubr qword [0x41f750]
mov dword [esp + 0x10], ecx
fild dword [esp + 0x10]
mov esi, 1
add dword [0x424280], esi
fcompp
fnstsw ax
fld qword [esp + 0x58]
fsub qword [0x41f350]
fstp qword [esp + 0x58]
test ah, 1
jne 0x406b1c
dec dword [esp + 0x30]
movzx edx, word [esp + 0x30]
movsx eax, dx
mov dword [esp + 0x10], eax
fild dword [esp + 0x10]
fsub qword [0x4243b8]
mov ecx, dword [0x424420]
movzx edx, word [esp + 0x28]
mov dword [esp + 0x10], ecx
movsx eax, dx
fild dword [esp + 0x10]
mov dword [esp + 0x10], eax
fsubp st(1)
fild dword [esp + 0x10]
faddp st(1)
call fcn.0040b5b0
mov word [esp + 0x28], ax
add dword [0x424420], esi
pop esi
test ebp, ebp
pop ebp
push 0
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x80]
je 0x406b46
push ecx
push edx
call fcn.00402500
mov eax, dword [esp + 0x1c]
add esp, 0xc
pop edi
pop ebx
add esp, 0x368
ret
lea eax, [esp + 0x48]
push eax
push ecx
push edx
call fcn.00402500
mov eax, dword [esp + 0x20]
add esp, 0x10
pop edi
pop ebx
add esp, 0x368
ret
pop edi
mov eax, 0xfffffffc
pop ebx
add esp, 0x368
ret