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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffc0
sub esp, 0x74
fldz
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
fstp qword [esi + 0x20]
xor edi, edi
mov dword [esp + 0x40], edi
cmp dword [esi + 0x10], edi
jle 0x47448d
mov dword [esp + 0x48], edi
mov dword [esp + 0x44], edi
jmp 0x474150
mov eax, dword [ebp + 0x10]
mov eax, dword [eax + 0x15d0]
add eax, dword [esp + 0x48]
mov edx, dword [esi + 0x14]
add edx, dword [esp + 0x44]
mov dword [esp + 0x60], eax
mov eax, dword [edx + 8]
sub eax, dword [edx]
mov dword [esp + 0x28], edx
mov dword [esp + 0x54], eax
mov dword [esp + 0x3c], edi
cmp dword [edx + 0x10], edi
jle 0x47446e
mov dword [esp + 0x30], edi
jmp 0x474190
mov ecx, dword [edx + 0x14]
add ecx, dword [esp + 0x30]
mov dword [esp + 0x70], edi
mov dword [esp + 0x7c], ecx
cmp dword [ecx + 0x18], edi
jle 0x474457
lea esi, [ecx + 0x38]
mov dword [esp + 0x2c], esi
nop
mov eax, dword [ecx + 0x10]
imul eax, dword [ecx + 0x14]
mov dword [esp + 0x6c], edi
test eax, eax
jle 0x47443b
mov dword [esp + 0x38], edi
jmp 0x4741d0
mov eax, dword [esi - 8]
add eax, dword [esp + 0x38]
mov dword [esp + 0x64], edi
mov ebx, dword [eax + 0x14]
imul ebx, dword [eax + 0x10]
mov dword [esp + 0x68], eax
test ebx, ebx
jle 0x47441e
mov dword [esp + 0x34], edi
jmp 0x4741f8
mov eax, dword [esp + 0x68]
mov eax, dword [eax + 0x18]
add eax, dword [esp + 0x34]
mov ebx, dword [esi - 0xc]
mov edx, dword [eax + 0xc]
mov edi, dword [eax + 0x10]
sub edi, dword [esi - 0x18]
mov ecx, edx
sub ecx, dword [esi - 0x1c]
mov dword [esp + 0x78], eax
mov dword [esp + 0x4c], ecx
test bl, 1
je 0x47423a
mov edx, dword [esp + 0x28]
mov edx, dword [edx + 0x14]
mov esi, dword [esp + 0x30]
lea edx, [edx + esi - 0x7c]
mov esi, dword [edx + 8]
sub esi, dword [edx]
mov edx, dword [eax + 0xc]
add ecx, esi
mov dword [esp + 0x4c], ecx
test bl, 2
je 0x474256
mov ecx, dword [esp + 0x28]
mov esi, dword [esp + 0x30]
mov ecx, dword [ecx + 0x14]
lea ecx, [ecx + esi - 0x7c]
mov esi, dword [ecx + 0xc]
sub esi, dword [ecx + 4]
add edi, esi
mov ebx, dword [eax + 0x18]
sub ebx, dword [eax + 0x10]
mov eax, dword [eax + 0x14]
mov esi, dword [ebp + 8]
sub eax, edx
push eax
call fcn.00473a40
add esp, 4
test eax, eax
je 0x47448d
mov ecx, dword [esp + 0x54]
imul edi, ecx
add edi, dword [esp + 0x4c]
mov eax, esi
mov esi, dword [esp + 0x28]
mov esi, dword [esi + 0x18]
mov edx, dword [eax + 0x14]
mov ebx, dword [eax + 0xc]
mov eax, dword [eax + 0x18]
lea edi, [esi + edi*4]
mov esi, dword [esp + 0x60]
cmp dword [esi + 0x14], 1
mov dword [esp + 0x74], edx
jne 0x4742f5
test eax, eax
jle 0x47439f
add ecx, ecx
add ecx, ecx
mov dword [esp + 0x5c], ecx
mov dword [esp + 0x4c], edi
mov dword [esp + 0x50], eax
test edx, edx
jle 0x4742d5
mov eax, edi
mov ecx, ebx
mov edi, edx
mov esi, dword [eax]
shl esi, 6
mov dword [ecx], esi
add eax, 4
add ecx, 4
dec edi
jne 0x4742c5
mov edi, dword [esp + 0x4c]
add edi, dword [esp + 0x5c]
lea eax, [edx*4]
add ebx, eax
dec dword [esp + 0x50]
mov dword [esp + 0x4c], edi
jne 0x4742bb
jmp 0x47439f
test eax, eax
jle 0x47439f
mov esi, ebx
mov dword [esp + 0x58], edi
mov dword [esp + 0x4c], esi
mov dword [esp + 0x5c], eax
jmp 0x474310
test edx, edx
jle 0x474373
mov ebx, edi
mov dword [esp + 0x50], edx
mov edx, dword [esp + 0x2c]
fld dword [edx]
sub esp, 8
fmul qword [0x4e0fc8]
fstp qword [esp]
call sub.MSVCRT.dll_floor
add esp, 8
call fcn.0049d940
mov ecx, eax
mov eax, 0x4000000
cdq
idiv ecx
xor edi, edi
imul dword [ebx]
mov ecx, eax
and ecx, 0x1000
add ecx, eax
adc edi, edx
shrd ecx, edi, 0xd
sar ecx, 5
mov dword [esi], ecx
sar edi, 0xd
add ebx, 4
add esi, 4
dec dword [esp + 0x50]
jne 0x47431a
mov edx, dword [esp + 0x74]
mov ecx, dword [esp + 0x54]
mov esi, dword [esp + 0x4c]
mov edi, dword [esp + 0x58]
lea eax, [edx*4]
add esi, eax
lea eax, [ecx*4]
add edi, eax
dec dword [esp + 0x5c]
mov dword [esp + 0x4c], esi
mov dword [esp + 0x58], edi
jne 0x474310
mov eax, dword [ebp + 0xc]
mov edx, dword [eax + 0x10]
mov ecx, dword [esp + 0x60]
push eax
mov eax, dword [ecx + 0x10]
mov ecx, dword [ecx + 0x14]
push edx
mov edx, dword [esp + 0x30]
push eax
mov eax, dword [esp + 0x38]
fld dword [eax]
mov eax, dword [eax - 0xc]
sub esp, 8
fstp qword [esp]
push ecx
mov ecx, dword [edx + 0x10]
sub ecx, dword [esp + 0x54]
mov edx, dword [esp + 0x58]
dec ecx
push ecx
mov ecx, dword [esp + 0x94]
push edx
mov edx, dword [ebp + 8]
push eax
push ecx
push edx
call fcn.00473af0
mov ecx, dword [esp + 0x94]
mov edx, dword [ecx + 0x14]
imul edx, dword [ecx + 0x10]
mov eax, dword [esp + 0x90]
add dword [esp + 0x60], 0x30
mov esi, dword [esp + 0x58]
inc eax
add esp, 0x2c
mov dword [esp + 0x64], eax
cmp eax, edx
jl 0x4741f4
mov ecx, dword [esp + 0x7c]
mov edx, dword [esp + 0x28]
xor edi, edi
mov ebx, dword [ecx + 0x10]
imul ebx, dword [ecx + 0x14]
mov eax, dword [esp + 0x6c]
add dword [esp + 0x38], 0x24
inc eax
mov dword [esp + 0x6c], eax
cmp eax, ebx
jl 0x4741d0
mov eax, dword [esp + 0x70]
inc eax
add esi, 0x20
mov dword [esp + 0x70], eax
mov dword [esp + 0x2c], esi
cmp eax, dword [ecx + 0x18]
jl 0x4741b0
mov esi, dword [ebp + 0xc]
mov eax, dword [esp + 0x3c]
add dword [esp + 0x30], 0x7c
inc eax
mov dword [esp + 0x3c], eax
cmp eax, dword [edx + 0x10]
jl 0x474190
mov eax, dword [esp + 0x40]
add dword [esp + 0x44], 0x20
add dword [esp + 0x48], 0x434
inc eax
mov dword [esp + 0x40], eax
cmp eax, dword [esi + 0x10]
jl 0x474150
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret