Function at 0x415570
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x860
mov eax, dword [edi + 0x10cc07c]
mov ecx, dword [eax + 0xe0]
push ebx
mov ebx, dword [eax + 0xe4]
mov eax, dword [edi + 0x10cc080]
mov edx, dword [eax + 0xe0]
mov eax, dword [eax + 0xe4]
cmp ebx, eax
push ebp
lea ebp, [edi + 0x10969f8]
push esi
mov dword [esp + 0x44], ebp
jg 0x4155c3
jl 0x4155b1
cmp ecx, edx
jae 0x4155c3
mov dword [esp + 0x20], ecx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], edx
mov dword [esp + 0x2c], eax
jmp 0x4155df
mov dword [esp + 0x28], ecx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x20], edx
mov dword [esp + 0x24], eax
mov ebx, eax
mov eax, dword [esp + 0x2c]
mov ecx, edx
mov edx, dword [esp + 0x28]
cmp ecx, edx
jne 0x4155eb
cmp ebx, eax
je 0x4159ad
sub edx, ecx
mov ecx, dword [0x488a6c]
sbb eax, ebx
mov dword [esp + 0x1c], eax
mov eax, dword [0x489b08]
push 0x100
shl eax, 9
add eax, 0x488b08
mov dword [esp + 0x1c], edx
fild qword [esp + 0x1c]
push eax
push 0xcf
push ecx
fstp qword [esp + 0x68]
mov dword [esp + 0x48], 0
call dword [sym.imp.USER32.dll_LoadStringW]
mov eax, dword [0x489b08]
lea edx, [eax + 1]
and edx, reloc.OLEAUT32.dll_VariantInit
jns 0x415641
dec edx
or edx, 0xfffffff8
inc edx
shl eax, 9
add eax, 0x488b08
push eax
mov eax, dword [edi + 0x1097a10]
push 2
push 0x400
push eax
mov dword [0x489b08], edx
call dword [sym.imp.USER32.dll_SendMessageW]
mov esi, dword [edi + 0x10cc078]
push 0
push 0
push 0
push 1
push ebp
call fcn.00403170
push 0
push 0x20
push 3
push 0
push 0
push 0x40000000
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
mov dword [esp + 0x3c], esi
jne 0x4156c3
mov ecx, dword [edi + 0x1097a10]
push 0x64
push 1
push 0x400
push ecx
call dword [sym.imp.USER32.dll_SendMessageW]
mov dword [edi + 0x1097a10], 0
pop esi
pop ebp
pop ebx
add esp, 0x860
ret
push 2
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edx, dword [edi + 0x10cc078]
mov ebp, dword [edx + 0x2c]
imul ebp, dword [edi + 0x10975fc]
add ebp, ebp
add ebp, ebp
push ebp
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push eax
mov dword [esp + 0x44], eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
push ebp
push 0
push eax
mov dword [esp + 0x40], eax
call fcn.0043e710
mov eax, dword [edi + 0x10cc078]
mov ebp, dword [eax + 0x2c]
add esp, 0xc
cmp dword [edi + 0x10975fc], 0
mov dword [esp + 0x30], 0
mov dword [esp + 0x10], 0
jbe 0x41579e
mov ecx, dword [esp + 0x34]
mov dword [esp + 0x14], ecx
xor esi, esi
test ebp, ebp
jle 0x41577c
mov ebx, dword [esp + 0x14]
mov eax, dword [edi + 0x10975fc]
mov ecx, dword [esp + 0x10]
cdq
sub eax, edx
sar eax, 1
cdq
sub ecx, eax
mov eax, 0
sbb eax, edx
add ecx, dword [esp + 0x20]
adc eax, dword [esp + 0x24]
push eax
push ecx
mov ecx, dword [edi + 0x10cc078]
mov eax, esi
call fcn.00402de0
fstp dword [ebx]
add esi, 1
add ebx, 4
cmp esi, ebp
jl 0x41573c
mov ebx, dword [esp + 0x24]
mov ecx, dword [esp + 0x10]
add ecx, 1
lea eax, [ebp*4]
add dword [esp + 0x14], eax
cmp ecx, dword [edi + 0x10975fc]
mov dword [esp + 0x10], ecx
jb 0x415732
mov esi, dword [esp + 0x3c]
cmp ebx, dword [esp + 0x2c]
mov eax, dword [esp + 0x20]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ebx
jg 0x41594f
jl 0x4157ca
cmp eax, dword [esp + 0x28]
jae 0x41594f
jmp 0x4157ca
mov ebx, dword [esp + 0x24]
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x18]
sub edx, eax
mov eax, dword [esp + 0x1c]
sbb eax, ebx
mov dword [esp + 0x50], edx
mov dword [esp + 0x54], eax
fild qword [esp + 0x50]
fdiv qword [esp + 0x58]
fmul qword [0x479580]
call fcn.00441ca0
mov ebx, eax
cmp ebx, dword [esp + 0x38]
je 0x415812
mov ecx, dword [edi + 0x1097a10]
push ebx
push 1
push 0x400
push ecx
call dword [sym.imp.USER32.dll_SendMessageW]
mov dword [esp + 0x38], ebx
xor ebx, ebx
test ebp, ebp
mov dword [esp + 0x10], ebx
jle 0x4158ed
mov eax, dword [esp + 0x34]
lea esi, [esp + 0x68]
mov ecx, esi
lea edx, [edi + 0x10971f8]
sub eax, ecx
mov dword [esp + 0x14], edx
mov dword [esp + 0x4c], eax
lea ebx, [ebx]
mov edx, dword [esp + 0x14]
cmp dword [edx], 0
jne 0x415859
mov eax, dword [edi + 0x10cc078]
cmp dword [eax + 0x30], 1
je 0x4158d6
mov eax, dword [edi + 0x10975fc]
mov ecx, dword [edi + 0x10cc078]
cdq
sub eax, edx
sar eax, 1
cdq
add eax, dword [esp + 0x18]
adc edx, dword [esp + 0x1c]
push edx
push eax
mov eax, ebx
call fcn.00402de0
mov edx, dword [esp + 0x34]
mov ecx, ebp
imul ecx, dword [esp + 0x30]
add ecx, ebx
fstp dword [edx + ecx*4]
mov eax, dword [edi + 0x10975fc]
test eax, eax
fldz
fstp dword [esi]
mov dword [esp + 0x48], eax
jle 0x4158be
mov eax, dword [esp + 0x4c]
mov ecx, dword [edi + 0x10975fc]
lea edx, [ebp*4]
add eax, esi
fld dword [esi]
fadd dword [eax]
add eax, edx
sub ecx, 1
fstp dword [esi]
jne 0x4158b1
fld dword [esi]
mov eax, dword [esp + 0x10]
fidiv dword [esp + 0x48]
add eax, 1
mov dword [esp + 0x10], eax
fstp dword [esp + eax*4 + 0x464]
add dword [esp + 0x14], 4
add ebx, 1
add esi, 4
cmp ebx, ebp
jl 0x415840
mov esi, dword [esp + 0x3c]
mov edx, dword [esp + 0x10]
push 0
lea ecx, [esp + 0x68]
push ecx
lea eax, [edx*4]
push eax
lea ecx, [esp + 0x474]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 0x30]
add eax, 1
cdq
idiv dword [edi + 0x10975fc]
add dword [esp + 0x18], 1
mov eax, dword [esp + 0x1c]
adc eax, 0
cmp eax, dword [esp + 0x2c]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x30], edx
jl 0x4157c2
jg 0x41594b
mov edx, dword [esp + 0x18]
cmp edx, dword [esp + 0x28]
jb 0x4157c2
mov ebx, dword [esp + 0x24]
mov ebp, dword [esp + 0x40]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [esp + 0x20]
push ebx
push eax
mov ebx, esi
mov ecx, edi
call fcn.00416ef0
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [edi + 0x1097a10]
mov esi, dword [sym.imp.USER32.dll_SendMessageW]
push 0x64
push 1
push 0x400
push ecx
call esi
mov edx, dword [esp + 0x44]
mov eax, dword [0x488ae4]
push edx
push 1
push 0x400
push eax
mov dword [edi + 0x1097a10], 0
call esi
pop esi
pop ebp
pop ebx
add esp, 0x860
ret