Function at 0x4945cd
Capabilities:
Write file on windows

Disassembly:
push 0x240
mov eax, 0x49c1a7
call fcn.004961c2
xor esi, esi
push 0x168
lea eax, [ebp - 0x1e8]
push esi
xor edi, edi
push eax
mov ebx, ecx
mov dword [ebp - 0x1f4], esi
mov dword [ebp - 0x214], esi
mov dword [ebp - 0x1ec], esi
mov dword [ebp - 0x1f0], edi
call sub.MSVCR100.dll_memset
push 0x10
lea eax, [ebp - 0x208]
push esi
push eax
call sub.MSVCR100.dll_memset
push 0x20
lea eax, [ebp - 0x24c]
push esi
push eax
call sub.MSVCR100.dll_memset
push 0x10
lea eax, [ebp - 0x22c]
push esi
push eax
call sub.MSVCR100.dll_memset
push 0x30
lea eax, [ebp - 0x40]
push esi
push eax
call sub.MSVCR100.dll_memset
mov ecx, dword [ebx + 0x298]
mov eax, dword [ebx + 0x29c]
sub eax, ecx
xor edx, edx
sar eax, 6
add esp, 0x3c
mov dword [ebp - 0x210], esi
mov dword [ebp - 0x20c], edx
cmp eax, esi
jbe 0x49469c
add ecx, 0x1c
mov dword [ebp - 0x1f8], eax
mov eax, dword [ecx - 4]
cmp dword [ebp - 0x210], eax
jl 0x494683
cmp edx, dword [ecx]
jge 0x49468b
mov edx, dword [ecx]
mov dword [ebp - 0x210], eax
add ecx, 0x40
dec dword [ebp - 0x1f8]
jne 0x494674
mov dword [ebp - 0x20c], edx
mov ecx, dword [ebx + 0x2a8]
cmp ecx, esi
jne 0x4946c5
cmp dword [ebx + 0x2ac], esi
jne 0x4946c1
mov eax, dword [ebp - 0x210]
mov dword [ebp - 0x1ec], eax
mov edi, edx
jmp 0x49475b
cmp ecx, esi
je 0x4946cb
mov dword [ebp - 0x1ec], ecx
mov eax, dword [ebx + 0x2ac]
cmp eax, esi
je 0x4946dd
mov edi, eax
mov dword [ebp - 0x1f0], eax
fild dword [ebp - 0x210]
fidiv dword [ebp - 0x20c]
fstp dword [ebp - 0x1f8]
cmp ecx, esi
jne 0x494728
fild dword [ebp - 0x1f0]
push ecx
fmul dword [ebp - 0x1f8]
fsub qword [0x4bcb00]
fstp dword [ebp - 0x1f0]
fld dword [ebp - 0x1f0]
fstp dword [esp]
call fcn.00494143
pop ecx
call fcn.00496570
mov dword [ebp - 0x1ec], eax
jmp 0x49475b
cmp eax, esi
je 0x49475b
fild dword [ebp - 0x1ec]
push ecx
fdiv dword [ebp - 0x1f8]
fsub qword [0x4bcb00]
fstp dword [ebp - 0x1f0]
fld dword [ebp - 0x1f0]
fstp dword [esp]
call fcn.00494143
pop ecx
call fcn.00496570
mov edi, eax
mov esi, dword [ebp - 0x1ec]
add esi, 0xf
add edi, 0xf
push 0
and esi, 0xfffffff0
and edi, 0xfffffff0
call dword [sym.imp.MSVCR100.dll__time64]
push eax
call dword [sym.imp.MSVCR100.dll_srand]
call dword [sym.imp.MSVCR100.dll_rand]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041dc80
lea eax, [ebp - 0x80]
push eax
call fcn.00405340
mov ecx, dword [ebx + 0x2c0]
xor eax, eax
mov dword [ebp - 0x6c], eax
mov dword [ebp - 0x68], eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x54], eax
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x60], ecx
mov ecx, dword [ebx + 0x2b8]
lea eax, [ebp - 0x80]
push eax
mov dword [ebp - 0x7c], esi
mov dword [ebp - 0x78], edi
mov dword [ebp - 0x74], esi
mov dword [ebp - 0x70], edi
mov dword [ebp - 0x64], 0x3e8
mov dword [ebp - 0x48], ecx
mov dword [ebp - 0x44], 6
call fcn.00407cb0
mov dword [ebp - 0x1ec], eax
lea eax, [ebp - 0x80]
push eax
call fcn.00405370
mov eax, edi
imul eax, esi
mov dword [ebp - 0x1f0], eax
imul eax, eax, 3
cdq
sub eax, edx
sar eax, 1
push eax
call fcn.0049608e
mov ecx, eax
mov eax, dword [ebp - 0x1f0]
add eax, ecx
mov dword [ebp - 0x24], eax
mov eax, esi
cdq
sub eax, edx
mov dword [ebp - 0x40], esi
mov dword [ebp - 0x38], esi
mov esi, eax
mov eax, edi
cdq
sub eax, edx
mov dword [ebp - 0x3c], edi
mov edi, eax
mov eax, dword [ebp - 0x1f0]
imul eax, eax, 5
cdq
and edx, 3
add eax, edx
sar esi, 1
sar edi, 1
sar eax, 2
add esp, 0x20
add eax, ecx
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x30], esi
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x14], eax
lea eax, [ebx + 4]
push str._video.ogg
push eax
mov dword [ebp - 0x20c], eax
lea eax, [ebp - 0x218]
push eax
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x18], esi
call fcn.00460179
and dword [ebp - 4], 0
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebx + 8]
call fcn.0045f9b8
push 0x4bc87c
push dword [ebp - 0x218]
lea eax, [ebp - 0x1f4]
push eax
call dword [sym.imp.MSVCR100.dll__wfopen_s]
add esp, 0xc
cmp dword [ebp - 0x1f4], 0
je 0x494b82
lea eax, [ebp - 0x22c]
push eax
call fcn.00405390
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x22c]
push eax
push dword [ebp - 0x1ec]
call fcn.004080f0
add esp, 0x10
test eax, eax
jle 0x494b82
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e0e0
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e400
xor edi, edi
inc edi
add esp, 0x10
cmp eax, edi
jne 0x494b82
push dword [ebp - 0x1f4]
mov esi, dword [sym.imp.MSVCR100.dll_fwrite]
push dword [ebp - 0x204]
push edi
push dword [ebp - 0x208]
call esi
push dword [ebp - 0x1f4]
push dword [ebp - 0x1fc]
push edi
push dword [ebp - 0x200]
call esi
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x22c]
push eax
push dword [ebp - 0x1ec]
call fcn.004080f0
add esp, 0x2c
jmp 0x49499c
je 0x4949a5
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e0e0
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x22c]
push eax
push dword [ebp - 0x1ec]
call fcn.004080f0
add esp, 0x14
test eax, eax
jns 0x49496b
jmp 0x494b82
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e3d0
pop ecx
pop ecx
jmp 0x494a02
js 0x494b82
push dword [ebp - 0x1f4]
push dword [ebp - 0x204]
push edi
push dword [ebp - 0x208]
call esi
push dword [ebp - 0x1f4]
push dword [ebp - 0x1fc]
push edi
push dword [ebp - 0x200]
call esi
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e3d0
add esp, 0x28
test eax, eax
jne 0x4949bc
mov eax, dword [ebx + 0x29c]
sub eax, dword [ebx + 0x298]
mov edi, dword [ebx + 0x2d0]
sar eax, 6
cmp edi, eax
jne 0x494af6
xor edi, edi
jmp 0x494af6
xor eax, eax
cmp dword [ebp - 0x1f8], eax
sete al
mov dword [ebp - 0x1f0], eax
jmp 0x494a9f
lea eax, [ebp - 0x24c]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e0e0
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e400
add esp, 0x10
test eax, eax
js 0x494b82
je 0x494a9f
push dword [ebp - 0x1f4]
push dword [ebp - 0x204]
push 1
push dword [ebp - 0x208]
call esi
push dword [ebp - 0x1f4]
push dword [ebp - 0x1fc]
push 1
push dword [ebp - 0x200]
call esi
add esp, 0x20
lea eax, [ebp - 0x24c]
push eax
push dword [ebp - 0x1f0]
push dword [ebp - 0x1ec]
call fcn.00408650
add esp, 0xc
test eax, eax
jne 0x494a3d
cmp dword [ebp - 0x1f8], eax
je 0x494b23
mov eax, dword [ebx + 0x29c]
sub eax, dword [ebx + 0x298]
inc dword [ebp - 0x214]
inc edi
sar eax, 6
cmp edi, eax
jne 0x494ae6
xor edi, edi
cmp edi, dword [ebx + 0x2d0]
je 0x494b23
cmp dword [ebp - 0x214], eax
jge 0x494b23
lea eax, [ebp - 0x40]
push eax
push edi
mov ecx, ebx
call fcn.0049435f
mov dword [ebp - 0x1f8], eax
lea eax, [ebp - 0x40]
push eax
push dword [ebp - 0x1ec]
call fcn.004083b0
pop ecx
pop ecx
test eax, eax
je 0x494a2a
jmp 0x494b82
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e3d0
pop ecx
pop ecx
jmp 0x494b7e
js 0x494b82
push dword [ebp - 0x1f4]
push dword [ebp - 0x204]
push 1
push dword [ebp - 0x208]
call esi
push dword [ebp - 0x1f4]
push dword [ebp - 0x1fc]
push 1
push dword [ebp - 0x200]
call esi
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041e3d0
add esp, 0x28
test eax, eax
jne 0x494b3a
lea eax, [ebp - 0x1e8]
push eax
call fcn.0041dd50
lea eax, [ebp - 0x22c]
push eax
call fcn.00405650
push dword [ebp - 0x1ec]
call fcn.00407d00
add esp, 0xc
cmp dword [ebp - 0x1f4], 0
je 0x494bbe
push dword [ebp - 0x1f4]
call dword [sym.imp.MSVCR100.dll_fclose]
pop ecx
cmp dword [ebp - 0x34], 0
je 0x494bcd
push dword [ebp - 0x34]
call sub.MSVCR100.dll_void___cdecl_operator_delete___void__
pop ecx
push 0x4a3688
push dword [ebp - 0x20c]
lea eax, [ebp - 0x21c]
push eax
call fcn.00460179
push 1
push ecx
lea eax, [ebp - 0x21c]
mov ecx, esp
mov dword [ebp - 0x20c], esp
push eax
mov byte [ebp - 4], 1
call fcn.0045e829
call fcn.0045f57e
pop ecx
pop ecx
lea ecx, [ebp - 0x21c]
call fcn.0045ddba
lea ecx, [ebp - 0x218]
call fcn.0045ddba
xor eax, eax
inc eax
call fcn.00496245
ret