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

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x58cf1b
push eax
mov dword fs:[0], esp
sub esp, 0x278
push ebx
push ebp
push esi
mov esi, ecx
xor ebx, ebx
push edi
cmp dword [esi + 4], ebx
jne 0x5090ef
xor al, al
jmp 0x509b09
fld qword [0xcaf1a8]
call sub.msvcrt.dll__CIacos
fld dword [esp + 0x298]
fchs
fmulp st(1)
lea edi, [esp + 0x84]
mov ebp, 4
fmul qword [0xcaf1b8]
fld st(0)
fcos
fstp dword [esp + 0x54]
fsin
fstp dword [esp + 0x50]
mov ecx, edi
call fcn.00527b70
add edi, 8
dec ebp
jne 0x509125
push 0xbf000000
push 0xbf000000
lea ecx, [esp + 0x18]
call fcn.00527b80
mov ecx, dword [eax]
push 0xbf000000
mov dword [esp + 0x88], ecx
mov ecx, esi
mov edx, dword [eax + 4]
mov dword [esp + 0x8c], edx
call fcn.005182f0
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], ebx
fild qword [esp + 0x14]
push ecx
lea ecx, [esp + 0x78]
fsub dword [0xcaf198]
fstp dword [esp]
call fcn.00527b80
mov ecx, dword [eax]
mov dword [esp + 0x8c], ecx
mov ecx, esi
mov edx, dword [eax + 4]
mov dword [esp + 0x90], edx
call fcn.005182e0
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], ebx
fild qword [esp + 0x10]
push ecx
lea ecx, [esp + 0x74]
fsub dword [0xcaf198]
fstp dword [esp]
push 0xbf000000
call fcn.00527b80
mov ecx, dword [eax]
mov dword [esp + 0x94], ecx
mov ecx, esi
mov edx, dword [eax + 4]
mov dword [esp + 0x98], edx
call fcn.005182e0
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], ebx
fild qword [esp + 0x10]
push ecx
mov ecx, esi
fsub dword [0xcaf198]
fstp dword [esp]
call fcn.005182f0
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], ebx
fild qword [esp + 0x14]
push ecx
lea ecx, [esp + 0x78]
fsub dword [0xcaf198]
fstp dword [esp]
call fcn.00527b80
mov ecx, dword [eax]
lea edi, [esp + 0x28]
mov dword [esp + 0x9c], ecx
mov ebp, 4
mov edx, dword [eax + 4]
mov dword [esp + 0xa0], edx
mov ecx, edi
call fcn.00527b70
add edi, 8
dec ebp
jne 0x509233
mov al, byte [esp + 0x2b0]
test al, al
je 0x509287
xor eax, eax
mov ecx, dword [esp + eax + 0x84]
mov edx, dword [esp + eax + 0x88]
mov dword [esp + eax + 0x28], ecx
mov dword [esp + eax + 0x2c], edx
add eax, 8
cmp eax, 0x20
jl 0x50924d
fld dword [esp + 0x28]
fcomp dword [esp + 0x30]
fnstsw ax
test ah, 1
je 0x509495
fld dword [esp + 0x28]
jmp 0x509499
xor eax, eax
fld dword [esp + 0x54]
fmul dword [esp + eax + 0x84]
fld dword [esp + 0x50]
fmul dword [esp + eax + 0x88]
add eax, 8
cmp eax, 0x20
fsubp st(1)
fstp dword [esp + eax + 0x20]
fld dword [esp + 0x50]
fmul dword [esp + eax + 0x7c]
fld dword [esp + 0x54]
fmul dword [esp + eax + 0x80]
faddp st(1)
fstp dword [esp + eax + 0x24]
jl 0x509289
mov al, byte [esp + 0x2ac]
test al, al
je 0x50926b
mov ecx, esi
call fcn.005182f0
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], ebx
fild qword [esp + 0x10]
push ecx
mov ecx, esi
fsubr dword [0xcaf198]
fstp dword [esp]
call fcn.005182e0
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], ebx
fild qword [esp + 0x14]
push ecx
lea ecx, [esp + 0x78]
fsub dword [0xcaf198]
fstp dword [esp]
call fcn.00527b80
sub esp, 8
mov ecx, esp
mov dword [esp + 0x18], esp
push eax
call fcn.00527ba0
lea ecx, [esp + 0x48]
call fcn.00527bc0
fcomp qword [0xcaf1c8]
fnstsw ax
test ah, 1
je 0x50934d
mov eax, dword [esp + 0x29c]
mov ecx, esi
push eax
call fcn.00508480
jmp 0x509b09
mov ecx, esi
call fcn.005182f0
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], ebx
fild qword [esp + 0x10]
push ecx
mov ecx, esi
fsub dword [0xcaf198]
fstp dword [esp]
call fcn.005182e0
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], ebx
fild qword [esp + 0x14]
push ecx
lea ecx, [esp + 0x78]
fsubr dword [0xcaf198]
fstp dword [esp]
call fcn.00527b80
sub esp, 8
mov ecx, esp
mov dword [esp + 0x18], esp
push eax
call fcn.00527ba0
lea ecx, [esp + 0x48]
call fcn.00527bc0
fcomp qword [0xcaf1c8]
fnstsw ax
test ah, 1
je 0x5093c9
mov ecx, dword [esp + 0x29c]
push ecx
mov ecx, esi
call fcn.00507ff0
jmp 0x509b09
mov ecx, esi
call fcn.005182e0
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], ebx
fild qword [esp + 0x10]
push ecx
mov ecx, esi
fsubr dword [0xcaf198]
fstp dword [esp]
call fcn.005182f0
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], ebx
fild qword [esp + 0x14]
push ecx
lea ecx, [esp + 0x78]
fsubr dword [0xcaf198]
fstp dword [esp]
call fcn.00527b80
sub esp, 8
mov ecx, esp
mov dword [esp + 0x18], esp
push eax
call fcn.00527ba0
lea ecx, [esp + 0x48]
call fcn.00527bc0
fcomp qword [0xcaf1c8]
fnstsw ax
test ah, 1
je 0x509445
mov edx, dword [esp + 0x29c]
mov ecx, esi
push edx
call fcn.00509b30
jmp 0x509b09
sub esp, 8
lea eax, [esp + 0xa4]
mov ecx, esp
mov dword [esp + 0x18], esp
push eax
call fcn.00527ba0
lea ecx, [esp + 0x48]
call fcn.00527bc0
fcomp qword [0xcaf1c8]
fnstsw ax
test ah, 1
je 0x50926b
mov ecx, dword [esp + 0x29c]
cmp ecx, ebx
je 0x509b07
push 1
push 1
push 1
push esi
call fcn.004ff580
jmp 0x509b07
fld dword [esp + 0x30]
fld dword [esp + 0x38]
fcomp dword [esp + 0x40]
fnstsw ax
test ah, 1
je 0x5094ae
fld dword [esp + 0x38]
jmp 0x5094b2
fld dword [esp + 0x40]
fxch st(1)
fcomp st(1)
fnstsw ax
test ah, 1
fstp st(0)
je 0x5094de
fld dword [esp + 0x28]
fcomp dword [esp + 0x30]
fnstsw ax
test ah, 1
je 0x5094d4
mov ecx, dword [esp + 0x28]
jmp 0x5094fb
mov edx, dword [esp + 0x30]
mov dword [esp + 0x24], edx
jmp 0x5094ff
fld dword [esp + 0x38]
fcomp dword [esp + 0x40]
fnstsw ax
test ah, 1
je 0x5094f7
mov eax, dword [esp + 0x38]
mov dword [esp + 0x24], eax
jmp 0x5094ff
mov ecx, dword [esp + 0x40]
mov dword [esp + 0x24], ecx
fld dword [esp + 0x2c]
fcomp dword [esp + 0x34]
fnstsw ax
test ah, 1
je 0x509514
fld dword [esp + 0x2c]
jmp 0x509518
fld dword [esp + 0x34]
fld dword [esp + 0x3c]
fcomp dword [esp + 0x44]
fnstsw ax
test ah, 1
je 0x50952d
fld dword [esp + 0x3c]
jmp 0x509531
fld dword [esp + 0x44]
fxch st(1)
fcomp st(1)
fnstsw ax
test ah, 1
fstp st(0)
je 0x50955d
fld dword [esp + 0x2c]
fcomp dword [esp + 0x34]
fnstsw ax
test ah, 1
je 0x509553
mov edx, dword [esp + 0x2c]
jmp 0x50957a
mov eax, dword [esp + 0x34]
mov dword [esp + 0x1c], eax
jmp 0x50957e
fld dword [esp + 0x3c]
fcomp dword [esp + 0x44]
fnstsw ax
test ah, 1
je 0x509576
mov ecx, dword [esp + 0x3c]
mov dword [esp + 0x1c], ecx
jmp 0x50957e
mov edx, dword [esp + 0x44]
mov dword [esp + 0x1c], edx
fld dword [esp + 0x28]
fcomp dword [esp + 0x30]
fnstsw ax
test ah, 0x41
jne 0x509593
fld dword [esp + 0x28]
jmp 0x509597
fld dword [esp + 0x30]
fld dword [esp + 0x38]
fcomp dword [esp + 0x40]
fnstsw ax
test ah, 0x41
jne 0x5095ac
fld dword [esp + 0x38]
jmp 0x5095b0
fld dword [esp + 0x40]
fxch st(1)
fcomp st(1)
fnstsw ax
test ah, 0x41
fstp st(0)
jne 0x5095dc
fld dword [esp + 0x28]
fcomp dword [esp + 0x30]
fnstsw ax
test ah, 0x41
jne 0x5095d2
mov eax, dword [esp + 0x28]
jmp 0x5095f9
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x18], ecx
jmp 0x5095fd
fld dword [esp + 0x38]
fcomp dword [esp + 0x40]
fnstsw ax
test ah, 0x41
jne 0x5095f5
mov edx, dword [esp + 0x38]
mov dword [esp + 0x18], edx
jmp 0x5095fd
mov eax, dword [esp + 0x40]
mov dword [esp + 0x18], eax
fld dword [esp + 0x2c]
fcomp dword [esp + 0x34]
fnstsw ax
test ah, 0x41
jne 0x509612
fld dword [esp + 0x2c]
jmp 0x509616
fld dword [esp + 0x34]
fld dword [esp + 0x3c]
fcomp dword [esp + 0x44]
fnstsw ax
test ah, 0x41
jne 0x50962b
fld dword [esp + 0x3c]
jmp 0x50962f
fld dword [esp + 0x44]
fxch st(1)
fcomp st(1)
fnstsw ax
test ah, 0x41
fstp st(0)
jne 0x50965b
fld dword [esp + 0x2c]
fcomp dword [esp + 0x34]
fnstsw ax
test ah, 0x41
jne 0x509651
mov ecx, dword [esp + 0x2c]
jmp 0x509678
mov edx, dword [esp + 0x34]
mov dword [esp + 0x20], edx
jmp 0x50967c
fld dword [esp + 0x3c]
fcomp dword [esp + 0x44]
fnstsw ax
test ah, 0x41
jne 0x509674
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x20], eax
jmp 0x50967c
mov ecx, dword [esp + 0x44]
mov dword [esp + 0x20], ecx
fld dword [esp + 0x18]
fsub dword [esp + 0x24]
sub esp, 8
fadd dword [0xcaf198]
fstp qword [esp]
call dword [sym.imp.msvcrt.dll_floor]
call sub.msvcrt.dll__ftol
fld dword [esp + 0x28]
fsub dword [esp + 0x24]
mov ebp, eax
mov dword [esp + 0x64], ebp
fadd dword [0xcaf198]
fstp qword [esp]
call dword [sym.imp.msvcrt.dll_floor]
add esp, 8
call sub.msvcrt.dll__ftol
fild dword [esp + 0x5c]
fld dword [esp + 0x18]
fadd dword [esp + 0x24]
fld st(1)
fsub dword [0xcaf1c0]
mov edi, eax
mov al, byte [esp + 0x2b0]
fsubp st(1)
mov dword [esp + 0x60], edi
test al, al
fmul dword [0xcaf198]
fstp dword [esp + 0x6c]
fild dword [esp + 0x60]
fstp dword [esp + 0x64]
fld dword [esp + 0x20]
fadd dword [esp + 0x1c]
fld dword [esp + 0x64]
fsub dword [0xcaf1c0]
fsubp st(1)
fmul dword [0xcaf198]
fstp dword [esp + 0x48]
fmul dword [0xcaf198]
fstp dword [esp + 0x70]
fld dword [esp + 0x64]
fmul dword [0xcaf198]
fstp dword [esp + 0x10]
je 0x509774
mov ecx, esi
call fcn.005182f0
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], ebx
fild qword [esp + 0x64]
mov ecx, esi
fmul dword [0xcaf198]
fsubr dword [esp + 0x6c]
fstp dword [esp + 0x6c]
call fcn.005182e0
mov dword [esp + 0x7c], eax
mov dword [esp + 0x80], ebx
fild qword [esp + 0x7c]
fmul dword [0xcaf198]
fsubr dword [esp + 0x48]
fstp dword [esp + 0x48]
push ebx
lea ecx, [esp + 0xa8]
call fcn.004ff430
push esi
lea ecx, [esp + 0xa8]
mov dword [esp + 0x294], ebx
call fcn.004ff6c0
mov ecx, esi
call fcn.00518330
push eax
mov ecx, esi
call fcn.00518320
and eax, 0xffff
lea ecx, [esp + 0xa8]
push eax
push edi
push ebp
call fcn.004ff700
push 0x100
mov ecx, esi
call fcn.0050e740
push eax
lea ecx, [esp + 0xac]
call fcn.0050f1e0
mov ecx, esi
call fcn.0051de10
test al, al
je 0x5097e8
lea ecx, [esp + 0xa4]
call fcn.0051deb0
mov eax, dword [esp + 0x2a8]
cmp eax, ebx
je 0x5097fb
mov edx, dword [eax]
mov dword [esp + 0x58], edx
jmp 0x50980e
mov al, 0xff
mov byte [esp + 0x5b], 0
mov byte [esp + 0x5a], al
mov byte [esp + 0x59], al
mov byte [esp + 0x58], al
mov eax, dword [esp + 0x48]
mov ecx, esi
mov dword [esp + 0x20], eax
call fcn.00518140
test al, al
jne 0x50998c
xor ebp, ebp
cmp edi, ebx
mov dword [esp + 0x48], ebx
jle 0x509ac1
mov dword [esp + 0x4c], ebx
jmp 0x50983b
xor ebx, ebx
mov eax, dword [esp + 0x4c]
cdq
idiv edi
mov dword [esi + 0x144], eax
mov eax, dword [esi + 0x148]
cmp eax, ebx
jne 0x509ac1
mov ecx, dword [esp + 0x6c]
mov edx, dword [esp + 0x48]
mov dword [esp + 0x1c], ecx
push edx
push ebx
lea ecx, [esp + 0xac]
call fcn.0050f620
mov ecx, esi
mov edi, eax
call fcn.0051de10
test al, al
je 0x509891
mov eax, dword [esp + 0x48]
lea ecx, [esp + 0xa4]
push eax
push ebx
call fcn.0051e140
mov ebp, eax
mov eax, dword [esp + 0x5c]
cmp eax, ebx
jle 0x509959
fld dword [esp + 0x20]
fmul dword [esp + 0x50]
mov ebx, eax
fstp dword [esp + 0x78]
fld dword [esp + 0x20]
fmul dword [esp + 0x54]
fstp dword [esp + 0x64]
fld dword [esp + 0x1c]
fmul dword [esp + 0x54]
mov al, byte [esp + 0x2b0]
test al, al
fadd dword [esp + 0x78]
fstp dword [esp + 0x18]
fld dword [esp + 0x1c]
fmul dword [esp + 0x50]
fsubr dword [esp + 0x64]
fstp dword [esp + 0x24]
je 0x5098fa
fld dword [esp + 0x18]
fadd dword [esp + 0x70]
fstp dword [esp + 0x18]
fld dword [esp + 0x24]
fadd dword [esp + 0x10]
fstp dword [esp + 0x24]
mov edx, dword [esp + 0x2a4]
mov eax, dword [esp + 0x2a0]
lea ecx, [esp + 0x58]
push ecx
mov ecx, dword [esp + 0x28]
push edx
mov edx, dword [esp + 0x20]
push eax
push ecx
lea eax, [esp + 0x8c]
push edx
push eax
mov ecx, esi
call fcn.005188b0
mov eax, dword [eax]
mov dword [esp + 0x18], eax
mov cx, word [esp + 0x1a]
test ebp, ebp
je 0x50993b
mov byte [ebp], ch
inc ebp
fld dword [esp + 0x1c]
fadd dword [0xcaf1c0]
mov byte [edi], al
inc edi
mov byte [edi], ah
inc edi
fstp dword [esp + 0x1c]
mov byte [edi], cl
inc edi
dec ebx
jne 0x5098b7
fld dword [esp + 0x20]
fadd dword [0xcaf1c0]
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x4c]
mov edi, dword [esp + 0x60]
inc eax
add edx, 0x64
cmp eax, edi
fstp dword [esp + 0x20]
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], edx
jl 0x509839
jmp 0x509abf
test edi, edi
jle 0x509abf
mov dword [esp + 0x4c], 0
jmp 0x5099a2
mov edi, dword [esp + 0x60]
mov eax, dword [esp + 0x4c]
cdq
idiv edi
mov dword [esi + 0x144], eax
mov eax, dword [esi + 0x148]
test eax, eax
jne 0x509abf
mov eax, dword [esp + 0x5c]
mov ecx, dword [esp + 0x6c]
xor ebp, ebp
mov dword [esp + 0x1c], ecx
test eax, eax
jle 0x509a99
fld dword [esp + 0x20]
fmul dword [esp + 0x50]
fstp dword [esp + 0x78]
fld dword [esp + 0x20]
fmul dword [esp + 0x54]
fstp dword [esp + 0x64]
fld dword [esp + 0x1c]
fmul dword [esp + 0x54]
mov al, byte [esp + 0x2b0]
test al, al
fadd dword [esp + 0x78]
fstp dword [esp + 0x18]
fld dword [esp + 0x1c]
fmul dword [esp + 0x50]
fsubr dword [esp + 0x64]
fstp dword [esp + 0x24]
je 0x509a2e
fld dword [esp + 0x18]
fadd dword [esp + 0x70]
fstp dword [esp + 0x18]
fld dword [esp + 0x24]
fadd dword [esp + 0x10]
fstp dword [esp + 0x24]
mov eax, dword [esp + 0x2a4]
mov ecx, dword [esp + 0x2a0]
lea edx, [esp + 0x58]
push edx
mov edx, dword [esp + 0x28]
push eax
mov eax, dword [esp + 0x20]
push ecx
push edx
lea ecx, [esp + 0x8c]
push eax
push ecx
mov ecx, esi
call fcn.005188b0
mov edi, dword [eax]
mov ecx, esi
call fcn.0051de10
test al, al
je 0x509a6d
push 1
jmp 0x509a6f
push 0
push edi
push ebx
push ebp
lea ecx, [esp + 0xb4]
call fcn.0050ecf0
fld dword [esp + 0x1c]
fadd dword [0xcaf1c0]
mov eax, dword [esp + 0x5c]
inc ebp
cmp ebp, eax
fstp dword [esp + 0x1c]
jl 0x5099eb
fld dword [esp + 0x20]
fadd dword [0xcaf1c0]
mov ecx, dword [esp + 0x4c]
mov eax, dword [esp + 0x60]
inc ebx
add ecx, 0x64
cmp ebx, eax
mov dword [esp + 0x4c], ecx
fstp dword [esp + 0x20]
jl 0x50999e
xor ebx, ebx
mov ecx, dword [esp + 0x29c]
cmp ecx, ebx
je 0x509ad6
lea edx, [esp + 0xa4]
push edx
jmp 0x509ae0
lea eax, [esp + 0xa4]
mov ecx, esi
push eax
call fcn.004ff9c0
lea ecx, [esp + 0xa4]
mov dword [esp + 0x290], 0xffffffff
mov dword [esp + 0xa4], 0xcaf060
call fcn.004ff450
mov al, 1
mov ecx, dword [esp + 0x288]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x284
ret 0x1c