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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xd4
fldz
xor ecx, ecx
fst dword [esp + 8]
xor eax, eax
fldz
push ebx
fst qword [esp + 0xa0]
xor edx, edx
fxch st(1)
xor ebx, ebx
fst dword [esp + 0x4c]
push esi
fxch st(1)
push edi
mov word [esp + 0x38], ax
mov word [esp + 0x10], cx
fst qword [esp + 0x58]
mov edi, dword [ebp + 0x14]
fxch st(1)
fstp dword [esp + 0x24]
mov esi, 1
fst qword [esp + 0x90]
mov word [esp + 0x40], dx
mov word [esp + 0x2c], ax
mov dword [esp + 0x78], ebx
movzx ecx, word [esp + 0x2c]
movzx edx, word [esp + 0x38]
sub ecx, 0x2555a91e
imul ecx, edx
mov word [esp + 0x38], cx
lea ecx, [esp + 0xbc]
push ecx
fstp qword [esp + 0x34]
lea eax, [esp + 0xbc]
mov dword [esp + 0xbc], ebx
push edi
mov dword [esp + 0xc0], ebx
mov dword [esp + 0xc4], esi
mov dword [esp + 0xc8], esi
mov dword [esp + 0xcc], eax
call fcn.00401540
add esp, 8
test eax, eax
jne 0x404ec4
lea eax, [ebx - 0xc]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dx, word [0x425d1c]
movsx eax, dx
mov dword [esp + 0x30], eax
fild dword [esp + 0x30]
fsub qword [esp + 0x58]
fadd qword [esp + 0xa8]
mov cx, word [esp + 0x2c]
movsx edx, cx
mov dword [esp + 0x30], edx
fild dword [esp + 0x30]
fcompp
fnstsw ax
fld qword [esp + 0xa8]
fld1
fsub st(1), st(0)
fxch st(1)
fstp qword [esp + 0xa8]
fsubr qword [esp + 0x58]
fstp qword [esp + 0x58]
test ah, 0x41
jp 0x404f3c
add dword [esp + 0x10], esi
mov ax, word [esp + 0x10]
movsx ecx, ax
add ecx, 0x6a63a11b
mov dword [esp + 0x30], ecx
fild dword [esp + 0x30]
fmul dword [0x425e48]
fstp dword [0x425e48]
push ebx
lea edx, [esp + 0xa0]
push edx
lea eax, [esp + 0x68]
push eax
lea ecx, [esp + 0x90]
push ecx
lea edx, [esp + 0x7c]
push edx
lea eax, [esp + 0x5c]
push eax
call fcn.00402080
mov cx, word [esp + 0x28]
add dword [esp + 0x28], esi
movsx edx, cx
add esp, 0x18
cmp edx, 0xa683022
jge 0x404fea
fld qword [0x425820]
fcomp qword [0x41f630]
fnstsw ax
fld qword [0x425820]
fadd qword [0x41f348]
fstp qword [0x425820]
test ah, 0x44
jp 0x404fc6
mov ax, word [esp + 0x2c]
movsx ecx, ax
mov edx, 0x46b3d4ec
sub edx, ecx
mov dword [esp + 0x30], edx
fild dword [esp + 0x30]
fadd qword [0x423ca0]
fstp qword [0x423ca0]
add dword [esp + 0x2c], esi
jmp 0x404fea
mov ax, word [0x4247ac]
movsx ecx, ax
mov dword [esp + 0x30], ecx
fild dword [esp + 0x30]
fmul dword [0x424684]
fstp dword [0x424684]
add word [0x4247ac], si
mov ebx, dword [ebp + 0x10]
push edi
push ebx
call fcn.00401230
add esp, 8
test eax, eax
jge 0x405084
mov edi, dword [ebp + 8]
test edi, edi
je 0x405060
xor edx, edx
xor eax, eax
push esi
mov word [esp + 0x2c], dx
push edi
mov word [esp + 0x20], ax
call fcn.00401690
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
movzx ecx, word [esp + 0x28]
mov edx, dword [edi + 4]
imul ecx, ecx, 0xba38db52
add edx, edx
add edx, edx
push edx
push eax
mov eax, dword [edi + 8]
push eax
mov word [esp + 0x34], cx
call fcn.0040b690
mov ecx, dword [edi + 8]
add esp, 0xc
mov dword [ecx], esi
mov dword [edi], 1
test esi, esi
jne 0x405c33
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x40507b
push ebx
push eax
call fcn.00401840
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
add word [0x424694], si
mov dx, word [0x424694]
movsx eax, dx
sub eax, 0x54d5865a
cmp eax, 0x9d65e939
je 0x4050d0
mov cx, word [0x425924]
mov edx, dword [0x423dd0]
movsx eax, cx
sub eax, edx
mov dword [esp + 0x30], eax
fild dword [esp + 0x30]
fadd qword [0x423eb8]
fstp qword [0x423eb8]
dec word [0x425924]
jmp 0x4050e0
movzx eax, word [esp + 0x10]
imul eax, eax, 0x4165d9b8
mov word [esp + 0x10], ax
lea ecx, [esp + 0x48]
push ebx
push ecx
call fcn.00401840
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
lea edx, [esp + 0x6c]
push edi
push edx
call fcn.00401840
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
mov ax, word [esp + 0x38]
movsx ecx, ax
sub ecx, 0x556f326
mov dword [esp + 0x30], ecx
mov edi, 1
mov dword [esp + 0x6c], edi
fild dword [esp + 0x30]
mov dword [esp + 0x48], edi
lea eax, [esp + 0x84]
fmul qword [0x423148]
fstp qword [0x423148]
mov edx, dword [ebx + 4]
add edx, 2
push edx
push eax
call fcn.00401690
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
push eax
lea ecx, [esp + 0x88]
push ecx
call fcn.004030f0
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
lea edx, [esp + 0x60]
push 2
push edx
call fcn.00401690
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
lea eax, [esp + 0x9c]
push 3
push eax
call fcn.00401690
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
fld dword [0x423dec]
fsub qword [0x41f628]
fcomp qword [0x41f620]
fnstsw ax
test ah, 5
jp 0x40521a
mov ecx, dword [0x423e5c]
mov edx, 0x763859fa
sub edx, ecx
mov dword [esp + 0x30], edx
fild dword [esp + 0x30]
fld dword [esp + 0x14]
add dword [0x423e5c], edi
fsub qword [0x41f618]
fucompp
fnstsw ax
test ah, 0x44
jnp 0x40521a
mov ax, word [0x423df0]
movsx ecx, ax
sub ecx, 0x50d2f81f
mov dword [esp + 0x30], ecx
fild dword [esp + 0x30]
fadd dword [0x425800]
fstp dword [0x425800]
lea edx, [esp + 0x6c]
push edx
call fcn.00401c70
add esp, 4
and eax, 0x8000001f
jns 0x405233
dec eax
or eax, 0xffffffe0
inc eax
cmp eax, 0x1f
jge 0x405285
mov edi, 0x1f
sub edi, eax
movzx eax, word [esp + 0x2c]
imul eax, eax, 0x66a83865
lea ecx, [esp + 0x48]
push edi
push ecx
mov dword [esp + 0x38], edi
mov word [esp + 0x34], ax
call fcn.00401f40
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
lea edx, [esp + 0x6c]
push edi
push edx
call fcn.00401f40
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
jmp 0x40528d
mov dword [esp + 0x30], 0
fld qword [esp + 0x90]
mov edi, dword [esp + 0x4c]
mov eax, dword [esp + 0x70]
fsub qword [0x41f610]
dec eax
dec edi
mov dword [esp + 0x44], edi
fstp dword [esp + 0x24]
sub edi, eax
mov ebx, edi
mov dword [esp + 0x80], eax
shl ebx, 5
lea eax, [esp + 0x6c]
push ebx
push eax
call fcn.00401f40
add dword [0x424698], 0xaf9651a4
lea ecx, [esp + 0x74]
push ecx
lea edx, [esp + 0x54]
push edx
call fcn.00401540
add esp, 0x10
test eax, eax
jl 0x405322
jmp 0x4052f0
mov eax, dword [esp + 0x8c]
inc dword [eax + edi*4]
lea eax, [esp + 0x6c]
push eax
lea ecx, [esp + 0x4c]
push ecx
mov edx, ecx
push edx
call fcn.004047c0
lea eax, [esp + 0x78]
push eax
lea ecx, [esp + 0x58]
push ecx
call fcn.00401540
add esp, 0x14
test eax, eax
jge 0x4052f0
lea edx, [esp + 0x6c]
push ebx
push edx
call fcn.00401330
mov ax, word [esp + 0x18]
movsx ecx, ax
mov eax, dword [esp + 0x4c]
add ecx, 0x72b5e952
add esp, 8
cmp eax, dword [esp + 0x80]
mov dword [0x425dd4], ecx
mov dword [esp + 0x7c], eax
jle 0x405b58
fld1
lea edx, [edi*4]
add ebx, 0xffffffe0
mov dword [esp + 0x3c], edx
mov dword [esp + 0x44], ebx
mov eax, dword [esp + 0x50]
mov ecx, dword [esp + 0x7c]
mov edx, dword [esp + 0x74]
lea ebx, [eax + ecx*4]
mov eax, dword [esp + 0x80]
mov ecx, dword [ebx]
lea esi, [edx + eax*4]
mov dword [esp + 0x28], ebx
cmp ecx, dword [esi]
jb 0x4053ad
mov eax, dword [esp + 0x3c]
mov edx, dword [esp + 0x8c]
mov dword [eax + edx - 4], 0xffffffff
mov esi, eax
or edi, 0xffffffff
jmp 0x405675
fld dword [0x423130]
fadd qword [0x41f608]
fsub qword [0x41f600]
call fcn.0040b550
mov dword [0x425860], eax
fld qword [esp + 0x58]
mov esi, dword [esi]
fsub st(1)
fstp qword [esp + 0x58]
mov cx, word [esp + 0x10]
movsx edx, cx
mov dword [esp + 0x14], edx
fild dword [esp + 0x14]
fld qword [esp + 0x58]
fsubr qword [0x41f5f8]
fsubp st(1)
call fcn.0040b550
mov word [esp + 0x10], ax
fld dword [0x423130]
mov eax, dword [ebx]
fsub qword [0x41f5f0]
xor edx, edx
mov edi, esi
shr edi, 0x10
fstp dword [0x423130]
div edi
mov ecx, dword [ebx]
mov edx, eax
imul edx, edi
sub ecx, edx
movzx edx, word [esp + 0x10]
sub edx, 0x61c93477
mov word [0x424694], dx
mov edx, dword [esp + 0x78]
shl ecx, 0x10
mov dword [esp + 0x18], eax
cmp edx, 0x8ff47cfa
jne 0x4054b1
dec dword [esp + 0x10]
mov ax, word [esp + 0x10]
movsx edx, ax
mov eax, dword [0x423e70]
mov ebx, 0xc899c8d4
sub ebx, eax
add edx, 0x36d17543
cmp edx, ebx
mov ebx, dword [esp + 0x28]
jle 0x405490
dec dword [esp + 0x10]
mov dx, word [esp + 0x10]
movsx eax, dx
mov dword [esp + 0x14], eax
fild dword [esp + 0x14]
fadd qword [esp + 0xa8]
fstp qword [esp + 0xa8]
jmp 0x4054ad
movzx edx, word [esp + 0x10]
mov eax, dword [0x425dd0]
sub edx, eax
sub edx, 0x21e552c8
mov word [esp + 0x10], dx
dec dword [0x425dd0]
mov eax, dword [esp + 0x18]
movzx edx, word [ebx - 2]
fld qword [0x423ca0]
fadd qword [0x41f5e8]
or ecx, edx
movzx ebx, si
fstp qword [0x423ca0]
mov edx, eax
imul edx, ebx
cmp ecx, edx
jae 0x4054ef
dec eax
add ecx, esi
mov dword [esp + 0x18], eax
cmp ecx, esi
jb 0x4054ef
cmp ecx, edx
jae 0x4054eb
add ecx, esi
dec eax
cmp ecx, esi
jae 0x4054e0
mov dword [esp + 0x18], eax
sub ecx, edx
or edx, 0xffffffff
add dword [esp + 0x38], edx
movzx eax, word [esp + 0x2c]
mov bx, word [esp + 0x38]
cwde
movsx ebx, bx
sub ebx, eax
movzx eax, word [esp + 0x10]
inc dword [esp + 0x10]
cwde
sub ebx, 0x619678cc
add eax, 0x598c1c16
cmp eax, ebx
jle 0x405549
mov eax, dword [0x424698]
mov ebx, dword [0x4246a0]
add eax, 0xa0e89bdc
add ebx, eax
mov dword [esp + 0x14], ebx
fild dword [esp + 0x14]
fmul dword [esp + 0x54]
fstp dword [esp + 0x54]
add dword [0x424698], edx
xor edx, edx
fld dword [0x41f5e0]
mov eax, ecx
fstp dword [esp + 0x14]
div edi
mov ebx, eax
mov eax, dword [esp + 0x28]
mov edx, ebx
imul edx, edi
sub ecx, edx
movzx edx, word [eax - 4]
add dword [0x425860], 0xc5834bd6
shl ecx, 0x10
or ecx, edx
movzx edx, si
mov eax, ebx
imul eax, edx
cmp ecx, eax
jae 0x405597
add ecx, esi
dec ebx
cmp ecx, esi
jb 0x405597
cmp ecx, eax
jae 0x405597
add ecx, esi
dec ebx
cmp ecx, esi
jae 0x40558c
inc word [0x42581c]
mov ax, word [0x42581c]
movzx ecx, word [esp + 0x10]
cwde
lea edx, [ecx + eax - 0xba43e7c]
mov word [esp + 0x10], dx
mov eax, dword [esp + 0x78]
mov dword [esp + 0x28], eax
fild dword [esp + 0x28]
fadd qword [esp + 0x58]
fsub dword [esp + 0x24]
call fcn.0040b550
mov esi, dword [esp + 0x3c]
mov word [0x423d34], ax
fld qword [esp + 0x58]
mov eax, dword [esp + 0x18]
fadd st(1)
shl eax, 0x10
or edi, 0xffffffff
fstp qword [esp + 0x58]
add dword [esp + 0x78], edi
fld dword [esp + 0x14]
mov dx, word [esp + 0x2c]
mov ecx, dword [esp + 0x8c]
fsub qword [0x41f5d8]
or eax, ebx
mov dword [esi + ecx - 4], eax
movsx eax, dx
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
fsubp st(1)
fld dword [esp + 0x14]
fadd qword [0x41f5d0]
fcompp
fnstsw ax
fld dword [esp + 0x14]
fadd st(1)
fstp dword [esp + 0x14]
test ah, 5
jp 0x405675
mov cx, word [0x423f10]
movsx edx, cx
mov eax, 0x31af9b42
sub eax, edx
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
fadd dword [esp + 0x14]
mov ecx, dword [0x42467c]
mov dword [esp + 0x18], ecx
fild dword [esp + 0x18]
faddp st(1)
call fcn.0040b550
mov dword [0x42467c], eax
add word [0x423f10], di
fld qword [esp + 0x90]
mov eax, dword [esp + 0x8c]
inc dword [esi + eax - 4]
fsub st(1)
fstp qword [esp + 0x90]
mov dx, word [esp + 0x40]
movsx eax, dx
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
fadd qword [esp + 0x90]
fsub dword [esp + 0x24]
fcomp qword [0x41f5c8]
fnstsw ax
fld dword [esp + 0x24]
fadd st(1)
fstp dword [esp + 0x24]
add dword [esp + 0x40], edi
test ah, 0x44
jp 0x40570e
add dword [esp + 0x2c], edi
fld dword [0x42317c]
mov ecx, dword [0x423ef0]
mov dx, word [esp + 0x38]
mov dword [esp + 0x18], ecx
fisub dword [esp + 0x18]
mov cx, word [esp + 0x2c]
movsx eax, dx
mov dword [esp + 0x18], eax
movsx edx, cx
fild dword [esp + 0x18]
mov dword [esp + 0x18], edx
fild dword [esp + 0x18]
faddp st(2)
fsubrp st(1)
call fcn.0040b550
mov word [esp + 0x38], ax
jmp 0x405743
fld dword [esp + 0x24]
fstp st(0)
fld qword [esp + 0xa8]
mov eax, dword [0x425858]
fstp st(0)
fld qword [0x423e00]
fstp st(0)
fld qword [esp + 0x90]
fstp st(0)
fld dword [esp + 0x24]
fsub st(1)
fstp dword [esp + 0x24]
jmp 0x405743
mov esi, dword [esp + 0x3c]
fld dword [esp + 0x24]
mov eax, dword [esp + 0x8c]
add dword [esi + eax - 4], edi
fsub st(1)
xor ecx, ecx
lea eax, [esp + 0x60]
fstp dword [esp + 0x24]
xor edx, edx
push 1
fadd dword [esp + 0x18]
push eax
fstp dword [esp + 0x1c]
fld qword [esp + 0x60]
fsub dword [esp + 0x2c]
fadd dword [esp + 0x1c]
fstp qword [0x425fe0]
mov word [esp + 0x30], cx
mov word [esp + 0x20], dx
call fcn.00401690
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
movzx ecx, word [esp + 0x28]
mov edx, dword [esp + 0x64]
imul ecx, ecx, 0xba38db52
lea eax, [edx*4]
push eax
mov word [esp + 0x2c], cx
mov ecx, dword [esp + 0x6c]
push esi
push ecx
call fcn.0040b690
mov edx, dword [esp + 0x74]
add esp, 0xc
mov dword [edx], esi
mov dword [esp + 0x60], 1
test esi, esi
jne 0x405c33
mov ecx, dword [esp + 0x80]
cmp ecx, 1
jge 0x4057e9
xor eax, eax
jmp 0x4057f1
mov eax, dword [esp + 0x74]
mov eax, dword [eax + ecx*4 - 4]
mov edx, dword [esp + 0x68]
mov dword [edx], eax
mov eax, dword [esp + 0x74]
mov ecx, dword [eax + ecx*4]
mov edx, dword [esp + 0x68]
mov dword [edx + 4], ecx
mov eax, dword [esp + 0x8c]
mov ecx, dword [esp + 0x3c]
mov edx, dword [ecx + eax - 4]
push edx
lea eax, [esp + 0x64]
push eax
mov ecx, eax
push ecx
call fcn.00404b10
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x405c33
xor edx, edx
lea ecx, [esp + 0x9c]
push 1
mov word [esp + 0x2c], dx
push ecx
mov word [esp + 0x20], ax
call fcn.00401690
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
movzx edx, word [esp + 0x28]
mov eax, dword [esp + 0xa0]
imul edx, edx, 0xba38db52
lea ecx, [eax*4]
push ecx
mov word [esp + 0x2c], dx
mov edx, dword [esp + 0xa8]
push esi
push edx
call fcn.0040b690
mov eax, dword [esp + 0xb0]
add esp, 0xc
mov dword [eax], esi
mov dword [esp + 0x9c], 1
test esi, esi
jne 0x405c33
fld qword [esp + 0x90]
mov cx, word [esp + 0x40]
fsubr qword [0x41f5c0]
movsx edx, cx
mov dword [esp + 0x18], edx
or edi, 0xffffffff
add dword [esp + 0x40], edi
fild dword [esp + 0x18]
faddp st(1)
fcomp qword [0x41f5b8]
fnstsw ax
test ah, 0x44
jp 0x40593e
fld qword [0x4253c8]
fsub qword [0x423e48]
mov ax, word [0x423154]
movsx ecx, ax
mov dword [esp + 0x18], ecx
fild dword [esp + 0x18]
fucompp
fnstsw ax
fld qword [0x4253c8]
fld1
fadd st(1), st(0)
fxch st(1)
fstp qword [0x4253c8]
test ah, 0x44
jp 0x405940
fld dword [esp + 0x24]
fsub st(1)
fstp dword [esp + 0x24]
mov edx, dword [0x424698]
mov dword [esp + 0x18], edx
fild dword [esp + 0x18]
fstp dword [esp + 0x18]
fld dword [esp + 0x24]
fsubr dword [esp + 0x18]
call fcn.0040b550
mov dword [0x424698], eax
jmp 0x405940
fld1
mov eax, dword [esp + 0x7c]
cmp eax, 2
jge 0x40594d
xor ecx, ecx
jmp 0x405955
mov ecx, dword [esp + 0x50]
mov ecx, dword [ecx + eax*4 - 8]
cmp eax, 1
mov edx, dword [esp + 0xa4]
mov dword [edx], ecx
jge 0x405967
xor ecx, ecx
jmp 0x40596f
mov ecx, dword [esp + 0x50]
mov ecx, dword [ecx + eax*4 - 4]
mov edx, dword [esp + 0xa4]
mov dword [edx + 4], ecx
mov ecx, dword [esp + 0x50]
mov edx, dword [ecx + eax*4]
mov eax, dword [esp + 0xa4]
lea ecx, [esp + 0x9c]
mov dword [eax + 8], edx
push ecx
lea edx, [esp + 0x64]
push edx
call fcn.00401540
add esp, 8
test eax, eax
jg 0x40573f
mov ax, word [0x4245ec]
fstp st(0)
movzx ecx, word [esp + 0x10]
mov edx, dword [esp + 0x8c]
cwde
add ecx, eax
mov eax, dword [esp + 0x3c]
mov word [esp + 0x10], cx
mov ecx, dword [eax + edx - 4]
push ecx
lea edx, [esp + 0x70]
push edx
lea eax, [esp + 0x68]
push eax
call fcn.00404b10
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x405c33
fld qword [esp + 0x58]
mov cx, word [0x42580c]
mov eax, dword [esp + 0x44]
movsx edx, cx
add edx, 0x1a89d679
mov dword [esp + 0x18], edx
push eax
lea ecx, [esp + 0x64]
fild dword [esp + 0x1c]
push ecx
fsubp st(1)
fstp qword [esp + 0x60]
call fcn.00401f40
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
lea edx, [esp + 0x60]
push edx
lea eax, [esp + 0x4c]
push eax
mov ecx, eax
push ecx
call fcn.004047c0
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x405c33
mov dx, word [0x424738]
movsx eax, dx
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
fld dword [esp + 0x54]
fsub qword [0x41f5b0]
fsubp st(1)
call fcn.0040b550
mov word [0x424738], ax
fld dword [esp + 0x54]
fld1
mov eax, 1
fsub st(1), st(0)
lea edx, [esp + 0xc8]
fxch st(1)
mov dword [esp + 0xc8], eax
mov dword [esp + 0xcc], eax
xor edi, edi
fstp dword [esp + 0x54]
push edx
fldz
lea eax, [esp + 0x4c]
lea ecx, [esp + 0xb8]
fstp qword [esp + 0x1c]
mov dword [esp + 0xb8], edi
push eax
mov dword [esp + 0xbc], edi
mov dword [esp + 0xd8], ecx
call fcn.00401540
add esp, 8
test eax, eax
jge 0x405b36
lea ecx, [esp + 0x6c]
fstp st(0)
push ecx
lea edx, [esp + 0x64]
push edx
call fcn.00401840
mov esi, eax
add esp, 8
cmp esi, edi
jne 0x405c33
mov eax, dword [esp + 0x44]
push eax
lea ecx, [esp + 0x64]
push ecx
call fcn.00401f40
mov esi, eax
add esp, 8
test esi, esi
jne 0x405c33
lea edx, [esp + 0x60]
push edx
lea eax, [esp + 0x4c]
push eax
mov ecx, eax
push ecx
call fcn.004037c0
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x405c33
mov eax, dword [esp + 0x8c]
fld1
mov ecx, dword [esp + 0x3c]
dec dword [ecx + eax - 4]
mov eax, dword [esp + 0x7c]
sub dword [esp + 0x44], 0x20
sub dword [esp + 0x3c], 4
dec eax
cmp eax, dword [esp + 0x80]
mov dword [esp + 0x7c], eax
jg 0x40536d
fstp st(0)
mov edi, dword [ebp + 8]
mov ebx, 1
test edi, edi
je 0x405b82
lea edx, [esp + 0x84]
push edx
push edi
call fcn.00401840
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
mov edx, dword [ebp + 0x14]
add esp, 8
imul ecx, dword [edx]
mov dword [edi], ecx
mov edi, dword [ebp + 0xc]
test edi, edi
je 0x405c24
mov eax, dword [esp + 0x30]
push eax
lea ecx, [esp + 0x4c]
push ecx
call fcn.00401330
lea edx, [esp + 0x50]
push edx
push edi
call fcn.00401840
add dword [esp + 0x48], ebx
fld dword [esp + 0x34]
mov ax, word [esp + 0x48]
mov edx, dword [ebp + 0x10]
movsx ecx, ax
mov eax, dword [edx]
mov dword [esp + 0x40], ecx
mov dword [edi], eax
lea edx, [esp + 0xe4]
fild dword [esp + 0x40]
xor eax, eax
push edx
lea ecx, [esp + 0xc4]
fsubp st(1)
push edi
mov dword [esp + 0xec], ebx
mov dword [esp + 0xf0], ebx
fstp dword [esp + 0x3c]
mov dword [esp + 0xf4], ecx
fldz
fstp qword [esp + 0xa8]
mov dword [esp + 0xc8], eax
mov dword [esp + 0xc8], eax
call fcn.00401540
add esp, 0x18
test eax, eax
jne 0x405c18
mov dword [edi], ebx
fld dword [esp + 0x54]
fmul dword [esp + 0x14]
fstp dword [esp + 0x14]
movzx eax, word [esp + 0x10]
sub eax, 0xb5559
mov word [esp + 0x10], ax
push 0
lea ecx, [esp + 0xa0]
push ecx
lea edx, [esp + 0x68]
push edx
lea eax, [esp + 0x90]
push eax
lea ecx, [esp + 0x7c]
push ecx
lea edx, [esp + 0x5c]
push edx
call fcn.00401b40
add esp, 0x18
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret