Function at 0x46ce00
Capabilities:
Get file size
Read file on windows

Disassembly:
sub esp, 0x1c
mov ecx, dword [esp + 0x20]
mov edx, dword [ecx]
add edx, edx
add edx, edx
mov dword [0x6c6d34], edx
mov eax, dword [ecx + 4]
add eax, 7
shr eax, 3
add eax, 3
and eax, 0xfffffffc
mov dword [0x6cbd44], eax
mov ecx, dword [ecx + 8]
add ecx, 7
shr ecx, 3
add ecx, 3
and ecx, 0xfffffffc
mov dword [0x6c9840], ecx
add ecx, eax
lea eax, [ecx + edx + 0xaa0]
push ebp
xor ebp, ebp
push eax
mov dword [esp + 8], ebp
mov dword [0x4b4afc], eax
call fcn.004275c0
add esp, 4
mov dword [0x6cbdcc], eax
mov eax, dword [0x4b4afc]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
cmp eax, ebp
mov dword [0x6cdf20], eax
jne 0x46ce7d
xor eax, eax
pop ebp
add esp, 0x1c
ret
push esi
push str.PJSYSDAT_Rev1.00
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov eax, dword [0x6cdf20]
lea ecx, [eax + 0x20]
mov dword [0x6cbbd0], ecx
mov ecx, dword [0x6c6d34]
lea edx, [eax + ecx + 0x20]
mov dword [0x6cbd38], edx
mov edx, dword [0x6cbd44]
lea esi, [eax + edx]
lea esi, [esi + ecx + 0x20]
mov dword [0x6cdd54], esi
mov esi, dword [0x6c9840]
add eax, esi
add eax, edx
lea eax, [eax + ecx + 0x20]
push 0x104
mov dword [0x6cde2c], eax
call fcn.004811ca
mov esi, eax
add esp, 4
cmp esi, ebp
jne 0x46cee9
pop esi
xor eax, eax
pop ebp
add esp, 0x1c
ret
mov ecx, dword [str.syssave.dat]
push edi
push ecx
push 0x4bcb08
push 0x49a440
push esi
call dword [sym.imp.USER32.dll_wsprintfA]
push esi
call fcn.00430df0
mov edi, eax
push esi
mov dword [esp + 0x28], edi
call fcn.0048124d
add esp, 0x18
cmp edi, ebp
je 0x46d1e8
push ebx
push ebp
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
push esi
call fcn.004811ca
mov ebx, eax
add esp, 4
cmp ebx, ebp
mov dword [esp + 0x30], ebx
je 0x46d1d6
push ebp
lea edx, [esp + 0x1c]
push edx
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x46d1cd
push esi
call fcn.004811ca
mov ebx, eax
add esp, 4
cmp ebx, ebp
je 0x46d1c9
mov eax, dword [esp + 0x30]
push esi
push ebx
push eax
call fcn.00427730
add esp, 0xc
test eax, eax
je 0x46d1c0
mov esi, dword [ebx + 0x10]
mov eax, dword [0x6c6d34]
cmp esi, eax
mov edi, dword [ebx + 0x14]
mov ebp, dword [ebx + 0x18]
jbe 0x46cfa2
mov edx, dword [0x6cbbd0]
push eax
lea ecx, [ebx + 0x20]
push ecx
push edx
jmp 0x46cfae
mov ecx, dword [0x6cbbd0]
push esi
lea eax, [ebx + 0x20]
push eax
push ecx
call fcn.004826d0
mov eax, dword [0x6cbd44]
add esp, 0xc
cmp edi, eax
jbe 0x46cfcd
push eax
mov eax, dword [0x6cbd38]
lea edx, [esi + ebx + 0x20]
push edx
push eax
jmp 0x46cfda
mov edx, dword [0x6cbd38]
push edi
lea ecx, [esi + ebx + 0x20]
push ecx
push edx
call fcn.004826d0
mov eax, dword [0x6c9840]
mov edx, dword [0x6cdd54]
add esp, 0xc
cmp ebp, eax
jbe 0x46cff4
push eax
jmp 0x46cff5
push ebp
lea eax, [edi + esi]
lea ecx, [eax + ebx + 0x20]
push ecx
push edx
call fcn.004826d0
mov eax, dword [0x6cdf20]
mov ecx, dword [0x6c6d34]
mov dword [eax + 0x10], ecx
mov edx, dword [0x6cdf20]
mov eax, dword [0x6cbd44]
mov dword [edx + 0x14], eax
mov ecx, dword [0x6c9840]
mov edx, dword [0x6cdf20]
mov dword [edx + 0x18], ecx
mov eax, dword [0x6c6d34]
mov ecx, dword [0x6cbbd0]
add esp, 0xc
push eax
push ecx
push 0x6c9858
mov dword [esp + 0x1c], 1
call fcn.004826d0
add ebp, edi
add ebp, esi
mov edx, dword [ebx + ebp + 0x20]
mov dword [0x6cdddc], edx
lea eax, [ebx + ebp + 0x20]
mov ecx, dword [eax + 4]
add eax, 4
add eax, 4
mov dword [0x6c77b0], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6cbd40], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6c984c], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6cdd10], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6cde0c], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6c9850], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6c77e0], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6c9854], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6cb7a0], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6cdde0], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6c77dc], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6c6d38], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6cbbd4], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6c6d30], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6cde28], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6cbdc8], edx
mov ecx, dword [eax]
add esp, 0xc
add eax, 4
mov dword [0x6c983c], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6cb798], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6cbbd8], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6c9838], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6c9728], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x6cde10], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x4bcf10], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x4bcf34], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x4bcf08], ecx
mov edx, dword [eax]
add eax, 4
mov dword [0x4bcc6c], edx
mov ecx, dword [eax]
add eax, 4
mov dword [0x6c77d4], ecx
mov edx, dword [eax]
mov dword [0x6c77d8], edx
lea edx, [eax + 0x10]
mov eax, 0x6c6d60
mov edi, eax
mov esi, edx
add eax, 0x28
mov ecx, 0xa
add edx, 0x28
cmp eax, 0x6c7760
rep movsd dword es:[edi], dword [esi]
jl 0x46d1a2
mov edi, dword [esp + 0x14]
xor ebp, ebp
push ebx
call fcn.0048124d
add esp, 4
mov ebx, dword [esp + 0x30]
push ebx
call fcn.0048124d
add esp, 4
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esp + 0x10], ebp
pop ebx
jne 0x46d33b
mov eax, dword [0x6cdf20]
mov ecx, dword [0x6c6d34]
mov dword [eax + 0x10], ecx
mov edx, dword [0x6cdf20]
mov eax, dword [0x6cbd44]
mov dword [edx + 0x14], eax
mov ecx, dword [0x6c9840]
mov edx, dword [0x6cdf20]
mov dword [edx + 0x18], ecx
call dword [sym.imp.USER32.dll_GetDesktopWindow]
lea ecx, [esp + 0x18]
push ecx
push eax
call dword [sym.imp.USER32.dll_GetWindowRect]
mov eax, dword [esp + 0x20]
add eax, 0xfffffc00
cdq
sub eax, edx
mov ecx, eax
mov eax, dword [esp + 0x24]
add eax, 0xfffffd00
cdq
sub eax, edx
mov edx, dword [0x6c77b0]
or dword [0x6c984c], 0x13
and dword [0x6c77e4], 0xfffffffe
sar ecx, 1
sar eax, 1
and eax, 0xffff
shl ecx, 0x10
or ecx, eax
or eax, 0xffffffff
mov dword [0x6cbd40], eax
mov dword [0x6cde0c], eax
mov eax, dword [0x6cdd10]
mov dword [0x6cdddc], ecx
mov ecx, dword [0x6cde28]
and eax, 0xfffff0ef
or eax, 0x1000
and ecx, 0xff000019
mov dword [0x6cdd10], eax
mov eax, 0x2710
or ecx, 0x4000019
and edx, 0x400fff0f
mov dword [0x6cde28], ecx
mov dword [0x6cbdc8], eax
mov dword [0x6c9838], eax
mov dword [0x6cbbd8], eax
mov dword [0x6cb798], eax
mov dword [0x6c983c], eax
or edx, 0x30b00000
xor eax, eax
mov ecx, 0x7d0
mov edi, 0x6c9858
mov dword [0x6c6d30], 0x32
mov dword [0x6c77b0], edx
mov dword [0x6cdde0], 2
mov dword [0x6c77dc], 0xff
mov dword [0x6c6d38], ebp
mov dword [0x6cbbd4], ebp
mov dword [0x6cde10], 0x1388
mov dword [0x4bcc6c], ebp
mov dword [0x6c77d8], ebp
mov dword [0x6c77d4], ebp
rep stosd dword es:[edi], eax
call fcn.0046c700
mov dword [0x4bcf10], ebp
mov dword [0x4bcf34], ebp
mov dword [0x4bcf08], ebp
push 0x104
call fcn.004811ca
mov esi, eax
add esp, 4
cmp esi, ebp
jne 0x46d357
pop edi
pop esi
xor eax, eax
pop ebp
add esp, 0x1c
ret
mov edx, dword [0x4b4654]
push edx
push 0x4bcb08
push 0x49a440
push esi
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
push ebp
push 0x80
push 3
push ebp
push 1
push DirectSoundCreate
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
push esi
mov edi, eax
call fcn.0048124d
add esp, 4
cmp edi, 0xffffffff
jne 0x46d3a1
mov dword [0x4bcc5c], ebp
jmp 0x46d3c6
push ebp
lea eax, [esp + 0x18]
push eax
push 4
push 0x4bcc5c
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x46d3bf
mov dword [0x4bcc5c], ebp
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [0x4bcc5c], 0x40
and dword [0x6c77b0], 0x7fffffff
mov eax, dword [esp + 0xc]
pop edi
pop esi
pop ebp
add esp, 0x1c
ret