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

Disassembly:
sub esp, 0x7c
push ebx
push ebp
xor ebp, ebp
mov eax, 0x40
push esi
push edi
mov dword [esp + 0x30], 1
mov dword [esp + 0x34], 2
mov dword [esp + 0x38], 4
mov dword [esp + 0x3c], ebp
mov dword [esp + 0x40], 0x400
mov dword [esp + 0x44], eax
mov dword [esp + 0x64], 0x100
mov dword [esp + 0x68], 0x80
mov dword [esp + 0x6c], 0x60
mov dword [esp + 0x70], 0x48
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], 0x30
mov dword [esp + 0x7c], 0x20
mov dword [esp + 0x80], 0x18
mov dword [esp + 0x84], 0x10
mov dword [esp + 0x1c], ebp
mov ecx, dword [esp + 0x94]
xor esi, esi
cmp dword [ecx + ebp*4], esi
je 0x404ce5
mov edx, dword [esp + 0x90]
mov ebx, dword [esp + ebp*4 + 0x64]
lea eax, [ebp*8]
sub eax, ebp
lea edi, [edx + eax*8]
mov eax, dword [edi + 0x20]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x18], eax
cmp ebp, esi
jne 0x404b4b
cmp dword [ecx], 8
jge 0x404b4b
mov byte [esp + 0x14], 1
mov dword [edi + 0x1c], esi
jmp 0x404b5b
push eax
mov eax, ebx
mov byte [esp + 0x18], 0
call fcn.004043f0
add esp, 4
mov byte [esp + 0x15], 1
mov eax, dword [esp + esi*4 + 0x30]
mov ecx, dword [esp + 0x94]
test dword [ecx + ebp*4], eax
je 0x404cc7
cmp byte [esp + 0x14], 0
je 0x404c8e
test esi, esi
je 0x404c78
fld qword [0x462d78]
mov edx, ebx
fstp qword [esp + 0x48]
mov dword [esp + 0x20], edx
fld qword [0x460258]
fstp qword [esp + 0x50]
fld qword [0x462d50]
fstp qword [esp + 0x58]
fild dword [esp + 0x20]
test edx, edx
jge 0x404bb9
fadd qword [0x462da0]
fld qword [esp + esi*8 + 0x48]
xor ecx, ecx
fnstcw word [esp + 0x16]
mov edx, 4
movzx eax, word [esp + 0x16]
fmul st(1)
or eax, 0xc00
mov dword [esp + 0x20], eax
fmulp st(1)
fldcw word [esp + 0x20]
fistp qword [esp + 0x20]
mov eax, dword [esp + 0x20]
fldcw word [esp + 0x16]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00426b12
mov ebp, dword [esp + 0x1c]
add esp, 4
mov dword [edi + esi*4 + 0x24], eax
push esi
push edi
mov eax, ebx
mov ecx, ebp
call fcn.004103b0
push esi
push ebx
push ebp
push edi
call fcn.00410570
mov ecx, dword [edi + esi*4 + 0x2c]
mov ebp, 1
add esp, 0x18
cmp dword [ecx], ebp
jle 0x404c56
lea eax, [ecx + 0xb]
jmp 0x404c30
lea edx, [eax + 2]
cmp eax, edx
je 0x404c4e
movzx ebx, byte [eax]
mov byte [esp + 0x16], bl
movzx ebx, byte [edx]
mov byte [eax], bl
movzx ebx, byte [esp + 0x16]
mov byte [edx], bl
mov ebx, dword [esp + 0x2c]
inc ebp
add eax, 3
cmp ebp, dword [ecx]
jl 0x404c30
mov ebp, dword [edi + esi*4 + 0x24]
push esi
push ebp
push edi
call fcn.00417df0
add esp, 0xc
push ebp
call fcn.00427d2f
mov ebp, dword [esp + 0x20]
mov ecx, dword [edi + esi*4 + 0x10]
add esp, 4
jmp 0x404cb6
mov eax, dword [esp + 0x18]
push 0
push eax
push edi
call fcn.00417df0
mov ecx, dword [edi + esi*4 + 0x10]
add esp, 0xc
jmp 0x404cb6
test esi, esi
jne 0x404c97
mov byte [esp + 0x15], 0
mov ecx, dword [esp + 0x18]
push ebx
push edi
mov eax, esi
call fcn.004045a0
mov edx, dword [edi + esi*4 + 0x10]
mov eax, dword [edi + 0xc]
add esp, 8
add edx, dword [esp + esi*4 + 0x3c]
lea ecx, [edx + eax + 0x28]
mov eax, dword [esp + 0x90]
mov dword [edi + esi*4], ecx
inc word [eax + 0x1f8]
inc esi
cmp esi, 3
jl 0x404b60
cmp byte [esp + 0x15], 0
je 0x404ce5
mov edx, dword [esp + 0x18]
push edx
call fcn.00427d2f
add esp, 4
inc ebp
cmp ebp, 9
mov dword [esp + 0x1c], ebp
jl 0x404b04
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x7c
ret