Function at 0x491230
Capabilities:
Write file on windows

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x858
push esi
mov esi, dword [ebx + 0x14]
mov eax, edx
mov edx, dword [ebx + 8]
mov dword [ebp - 0x10], ecx
xor ecx, ecx
push edi
mov dword [ebp - 0xc], ecx
xor edi, edi
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 8], ecx
mov dword [ebp - 0x18], ecx
lea ecx, [ebp - 8]
push ecx
push dword [ebx + 0x18]
mov ecx, eax
mov dword [ebp - 4], 0
push esi
push dword [ebx + 0xc]
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], edi
call fcn.00491440
mov eax, dword [0x4bccb0]
add esp, 0x10
push edi
push edi
push edi
push edi
push esi
call eax
mov edx, eax
mov dword [ebp - 0x28], edx
test edx, edx
jne 0x4912b3
lea eax, [edi + 1]
pop edi
pop esi
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
mov eax, dword [ebx + 0xc]
mov ecx, dword [0x4bccb8]
movzx eax, al
neg eax
push 0
sbb eax, eax
and eax, 0x803000
add eax, 0x80000000
push eax
push 0
push 0
push dword [ebp - 0x10]
push edx
call ecx
mov ecx, eax
mov dword [ebp - 0x10], ecx
test ecx, ecx
jne 0x4912eb
lea esi, [eax + 2]
jmp 0x491412
mov eax, dword [0x4bcc9c]
lea edx, [ebp - 4]
push edx
push 0x800
lea edx, [ebp - 0x850]
push edx
push ecx
call eax
test eax, eax
je 0x49137b
mov ecx, dword [ebp - 0x14]
mov eax, dword [ebp - 4]
add ecx, eax
mov dword [ebp - 0x14], ecx
test eax, eax
je 0x491374
xor esi, esi
test eax, eax
je 0x491351
mov ecx, dword [ebp - 0xc]
nop
lea eax, [ebp - 0x850]
add eax, esi
cmp edi, ecx
je 0x491336
mov al, byte [eax]
mov byte [edi], al
inc edi
mov dword [ebp - 0x20], edi
jmp 0x49134b
push eax
push edi
lea ecx, [ebp - 0x24]
call fcn.00410040
mov eax, dword [ebp - 0x1c]
mov ecx, eax
mov edi, dword [ebp - 0x20]
mov dword [ebp - 0xc], eax
inc esi
cmp esi, dword [ebp - 4]
jb 0x491320
mov eax, dword [0x4bcc9c]
lea ecx, [ebp - 4]
push ecx
push 0x800
lea ecx, [ebp - 0x850]
push ecx
push dword [ebp - 0x10]
call eax
test eax, eax
jne 0x491307
mov ecx, dword [ebp - 0x14]
jmp 0x49137d
mov eax, ecx
mov dword [ebp - 8], eax
jmp 0x491380
xor ecx, ecx
mov eax, dword [ebp - 8]
test eax, eax
jle 0x49138f
cmp ecx, eax
je 0x49138f
mov dword [ebp - 0x18], 5
mov dword [ebp - 0x40], 0xbd78a9da
lea eax, [ebp - 0x40]
mov dword [ebp - 0x3c], 0x25a4ab41
mov dword [ebp - 0x38], 0xcfff7b16
mov dword [ebp - 0x34], 0x2fdd2f44
movaps xmm1, xmmword [ebp - 0x40]
push eax
push dword [ebx + 0x10]
mov dword [ebp - 0x50], 0xbd78cbad
mov dword [ebp - 0x4c], 0x25a4ab41
mov dword [ebp - 0x48], 0xcfff7b16
mov dword [ebp - 0x44], 0x2fdd2f44
pxor xmm1, xmmword [ebp - 0x50]
movaps xmmword [ebp - 0x40], xmm1
call fcn.004488a2
mov esi, eax
add esp, 8
test esi, esi
je 0x491406
mov ecx, dword [ebp - 0x24]
sub edi, ecx
push esi
push edi
push 1
call fcn.00403ee0
push eax
call fcn.00448ed7
push esi
call fcn.0044892f
add esp, 0x14
push dword [ebp - 0x10]
call dword [0x4bcc98]
mov esi, dword [ebp - 0x18]
push dword [ebp - 0x28]
call dword [0x4bcc98]
mov ecx, dword [ebp - 0x24]
test ecx, ecx
je 0x491431
mov eax, dword [ebp - 0xc]
sub eax, ecx
push eax
push ecx
call fcn.00409000
add esp, 8
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret