Function at 0x4c8991
Capabilities:
Read file on windows

Disassembly:
push 0x434
push 0x5eee68
call fcn.00549b0c
mov esi, ecx
mov dword [ebp - 0x444], esi
mov eax, dword [ebp + 8]
mov dword [ebp - 0x440], eax
xor edi, edi
mov dword [ebp - 0x438], edi
mov byte [ebp - 0x434], 0
mov ebx, 0x103
push ebx
push edi
lea eax, [ebp - 0x433]
push eax
call fcn.005306b0
add esp, 0xc
mov byte [ebp - 0x12c], 0
push ebx
push edi
lea eax, [ebp - 0x12b]
push eax
call fcn.005306b0
add esp, 0xc
mov edi, 0x1e8
call fcn.004ca763
test eax, eax
je 0x4c9167
mov edx, dword [ebp - 0x440]
call fcn.004ccc0d
test eax, eax
lea eax, [ebp - 0x12c]
jne 0x4c8a26
push dword [ebp - 0x440]
lea ecx, [ebx + 1]
call fcn.004ccc3f
pop ecx
jmp 0x4c8a2b
call fcn.004ccb8b
and dword [ebp - 0x440], 0
lea edx, [ebp - 0x12c]
call fcn.004ccc0d
test eax, eax
jne 0x4c8b3d
lea edi, [ebp - 0x12c]
call fcn.00432263
test eax, eax
jne 0x4c8ab2
mov edi, 0x7046b0
mov edx, edi
call fcn.004ccc0d
test eax, eax
jne 0x4c8b18
push edi
call fcn.00530f70
pop ecx
mov ecx, ebx
sub ecx, eax
lea eax, [ebp - 0x12c]
push eax
lea eax, [ebp - 0x434]
call fcn.004ccc3f
pop ecx
mov edx, edi
mov ecx, eax
call fcn.004cd1ce
lea edi, [ebp - 0x434]
call fcn.00432263
test eax, eax
je 0x4c8aeb
mov eax, edi
push eax
mov ecx, 0x104
lea eax, [ebp - 0x12c]
call fcn.004ccc3f
pop ecx
push 0
xor edx, edx
lea ecx, [ebp - 0x12c]
call fcn.004328fa
pop ecx
mov dword [ebp - 0x440], eax
test eax, eax
jne 0x4c8b3d
cmp dword [0x7047b8], eax
jne 0x4c9167
lea eax, [ebp - 0x12c]
push eax
push str.:5:LoadSound___s___FAILED:_GetFileSizeTimeOut___FAILED.
call fcn.0042b70b
jmp 0x4c8b36
cmp dword [0x7047b4], 0
jne 0x4c9167
lea eax, [ebp - 0x434]
push eax
lea eax, [ebp - 0x12c]
push eax
push str.:2:LoadSound___s___FAILED:_The_file_could_not_be_found__Tried_default_directory___s_
call fcn.0042bd38
add esp, 0xc
jmp 0x4c9167
cmp dword [0x7047b4], 0
jne 0x4c9167
lea eax, [ebp - 0x12c]
push eax
push str.:2:LoadSound___s___FAILED:_The_file_could_not_be_found__No_default_directory_has_been_defined.
call fcn.0042bd38
pop ecx
pop ecx
jmp 0x4c9167
xor ebx, ebx
cmp dword [ebp - 0x440], ebx
jne 0x4c8b87
mov edi, 0x21a
call fcn.004ca763
test eax, eax
je 0x4c8b7f
mov eax, esi
call fcn.004ca7c5
test eax, eax
je 0x4c8b7f
push str.LoadSound1
mov ecx, esi
call fcn.004c84ba
pop ecx
mov dword [esi + 0x104], ebx
mov eax, esi
call fcn.004ccb8b
call fcn.004ca7dd
xor eax, eax
inc eax
jmp 0x4c9169
push 0x228
push str..Sound.c
mov edx, 0x54f4b8
lea ecx, [ebp - 0x12c]
call fcn.00434df1
pop ecx
pop ecx
mov edi, eax
cmp edi, ebx
jne 0x4c8bd1
cmp dword [0x7047b8], ebx
jne 0x4c9167
push dword [ebp - 0x440]
lea eax, [ebp - 0x12c]
push eax
push str.:5:LoadSound___s___FAILED:_The_file_of_size__ld_exists_but_cannot_be_opened__
call fcn.0042b70b
jmp 0x4c8b10
mov dword [ebp - 0x43c], ebx
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x52
jne 0x4c8c1b
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x49
jne 0x4c8c1b
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x46
jne 0x4c8c1b
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x46
je 0x4c8c25
mov dword [ebp - 0x43c], 1
xor ebx, ebx
inc ebx
push edi
call fcn.0053256f
pop ecx
push edi
call fcn.0053256f
pop ecx
push edi
call fcn.0053256f
pop ecx
push edi
call fcn.0053256f
pop ecx
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x57
jne 0x4c8c88
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x41
jne 0x4c8c88
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x56
jne 0x4c8c88
push edi
call fcn.0053256f
pop ecx
call fcn.004cca6a
cmp eax, 0x45
je 0x4c8c8e
mov dword [ebp - 0x43c], ebx
cmp dword [ebp - 0x43c], 0
je 0x4c8cbc
cmp dword [0x7047b8], 0
jne 0x4c9160
lea eax, [ebp - 0x12c]
push eax
push str.LoadSound___s___FAILED:_The_wave_file_is_invalid:_The_RIFF_Chunk_was_not_found.
call fcn.0042b70b
pop ecx
pop ecx
jmp 0x4c9160
push edi
mov eax, str.fmt
call fcn.00434368
pop ecx
test eax, eax
jne 0x4c8ce6
cmp dword [0x7047b8], eax
jne 0x4c9160
lea eax, [ebp - 0x12c]
push eax
push str.LoadSound___s___FAILED:_The_wave_file_is_invalid:_The_Format_Chunk_was_not_found.
jmp 0x4c8cb0
and dword [ebp - 0x438], 0
push edi
push ebx
push 4
lea eax, [ebp - 0x438]
push eax
call fcn.00530e93
add esp, 0x10
cmp eax, ebx
jne 0x4c913d
cmp dword [ebp - 0x438], 0x10
jb 0x4c913d
push dword [ebp - 0x438]
push ebx
call fcn.00530848
pop ecx
pop ecx
mov dword [ebp - 0x43c], eax
test eax, eax
jne 0x4c8d55
cmp dword [0x7047b8], eax
jne 0x4c9160
push dword [ebp - 0x438]
lea eax, [ebp - 0x12c]
push eax
push str.:6:LoadSound___s___FAILED:_Could_not_allocate__ld_bytes_for_the_wave_format_header_struct.
call fcn.0042b70b
jmp 0x4c915d
push edi
push dword [ebp - 0x438]
push ebx
push dword [ebp - 0x43c]
call fcn.00530e93
add esp, 0x10
cmp eax, dword [ebp - 0x438]
je 0x4c8dae
cmp dword [0x7047b8], 0
jne 0x4c8d97
push eax
push dword [ebp - 0x438]
lea eax, [ebp - 0x12c]
push eax
push str.:7:LoadSound___s___FAILED:_Could_not_read_the_Format_Chunk_of_size__ld_from_the_file.__Only__ld_bytes_could_be_read.
call fcn.0042b70b
add esp, 0x10
mov ecx, edi
call fcn.00435239
push dword [ebp - 0x43c]
call fcn.0053061e
jmp 0x4c8b37
push edi
mov eax, str.data
call fcn.00434368
pop ecx
test eax, eax
jne 0x4c8ddb
cmp dword [0x7047b8], eax
jne 0x4c8d97
lea eax, [ebp - 0x12c]
push eax
push str.LoadSound___s___FAILED:_The_wave_file_is_invalid:_The_Format_Chunk_was_not_found.
call fcn.0042b70b
pop ecx
pop ecx
jmp 0x4c8d97
and dword [ebp - 0x438], 0
push edi
push ebx
push 4
lea eax, [ebp - 0x438]
push eax
call fcn.00530e93
add esp, 0x10
cmp eax, ebx
jne 0x4c9114
cmp dword [ebp - 0x438], 0
je 0x4c9114
push dword [ebp - 0x438]
call fcn.00532823
pop ecx
mov ebx, eax
test ebx, ebx
jne 0x4c8e47
cmp dword [0x7047b8], eax
jne 0x4c8d97
push dword [ebp - 0x438]
lea eax, [ebp - 0x12c]
push eax
push str.:7:LoadSound___s___FAILED:_The_file_is_too_large_for_memory:_Could_not_allocate__ld_bytes_for_wave_data.
call fcn.0042b70b
add esp, 0xc
jmp 0x4c8d97
push edi
push dword [ebp - 0x438]
push 1
push ebx
call fcn.00530e93
add esp, 0x10
cmp eax, dword [ebp - 0x438]
je 0x4c8e9c
cmp dword [0x7047b8], 0
jne 0x4c8e85
push eax
push dword [ebp - 0x438]
lea eax, [ebp - 0x12c]
push eax
push str.:7:LoadSound___s___FAILED:_Wave_data_size_should_be__ld_but_only__ld_bytes_could_be_read.
call fcn.0042b70b
add esp, 0x10
push ebx
call fcn.0053061e
pop ecx
push dword [ebp - 0x43c]
call fcn.0053061e
jmp 0x4c8cb6
mov ecx, edi
call fcn.00435239
mov edi, 0x2a2
call fcn.004ca763
test eax, eax
je 0x4c9108
mov eax, esi
call fcn.004ca7c5
test eax, eax
je 0x4c9108
push str.LoadSound
mov ecx, esi
call fcn.004c84ba
pop ecx
and dword [ebp - 4], 0
mov dword [esi + 0x108], ebx
mov eax, dword [ebp - 0x438]
mov dword [esi + 0x10c], eax
mov eax, dword [ebp - 0x43c]
mov dword [esi + 0x110], eax
lea eax, [ebp - 0x12c]
push eax
mov ecx, 0x104
mov eax, esi
call fcn.004ccc3f
pop ecx
mov eax, dword [ebp - 0x440]
mov dword [esi + 0x104], eax
lea ebx, [esi + 0x114]
push 0x20
push 0
push ebx
call fcn.005306b0
add esp, 0xc
mov eax, dword [ebp - 0x438]
mov dword [esi + 0x118], eax
mov eax, dword [esi + 0x108]
mov dword [ebx], eax
and dword [esi + 0x120], 0
lea edi, [esi + 0x434]
and dword [edi], 0
push 0x30000
push esi
push 0x4ca69d
push dword [esi + 0x110]
push 0xffffffffffffffff
push edi
call dword [sym.imp.WINMM.dll_waveOutOpen]
mov dword [ebp - 0x440], eax
test eax, eax
je 0x4c9031
mov byte [ebp - 0x32c], 0
push 0xff
push 0
lea eax, [ebp - 0x32b]
push eax
call fcn.005306b0
add esp, 0xc
mov ebx, dword [ebp - 0x440]
push ebx
push str.Err_ld
push 0xf6
lea eax, [ebp - 0x32c]
push eax
call fcn.004ce4e5
lea eax, [ebp - 0x32c]
push eax
call fcn.00530f70
add esp, 0x14
mov ecx, 0x100
sub ecx, eax
push ecx
lea eax, [ebp - 0x32c]
push eax
call fcn.00530f70
pop ecx
lea eax, [ebp + eax - 0x32c]
push eax
push ebx
call dword [sym.imp.WINMM.dll_waveOutGetErrorTextA]
cmp dword [0x7047cc], ebx
je 0x4c8ff6
and dword [0x7048d4], 0
mov dword [0x7047cc], ebx
jmp 0x4c8ffc
inc dword [0x7048d4]
cmp dword [0x7047b4], 0
jne 0x4c9029
cmp dword [0x7048d4], 2
jg 0x4c9029
lea eax, [ebp - 0x32c]
push eax
lea eax, [ebp - 0x12c]
push eax
push str.:4:LoadSound___s___encountered_a_problem:_The_initial_sound_instance_could_not_be_queued_because_waveOutOpen___FAILED:__s
call fcn.0042bd38
add esp, 0xc
and dword [edi], 0
jmp 0x4c90d1
push 0x20
push ebx
push dword [edi]
call dword [sym.imp.WINMM.dll_waveOutPrepareHeader]
mov edi, eax
test edi, edi
je 0x4c90d1
mov byte [ebp - 0x22c], 0
push 0xff
push 0
lea eax, [ebp - 0x22b]
push eax
call fcn.005306b0
add esp, 0xc
push edi
push str.Err_ld
push 0xf6
lea eax, [ebp - 0x22c]
push eax
call fcn.004ce4e5
lea eax, [ebp - 0x22c]
push eax
call fcn.00530f70
add esp, 0x14
mov ecx, 0x100
sub ecx, eax
push ecx
lea eax, [ebp - 0x22c]
push eax
call fcn.00530f70
pop ecx
lea eax, [ebp + eax - 0x22c]
push eax
push edi
call dword [sym.imp.WINMM.dll_waveOutGetErrorTextA]
cmp dword [0x7047b4], 0
jne 0x4c90d1
lea eax, [ebp - 0x22c]
push eax
lea eax, [ebp - 0x12c]
push eax
push str.:4:LoadSound___s___encountered_a_problem:_The_initial_sound_instance_could_not_be_queued_because_waveOutPrepareHeader___FAILED:__s
call fcn.0042bd38
add esp, 0xc
mov dword [ebp - 4], 0xfffffffe
jmp 0x4c9101
mov eax, esi
jmp 0x4c8b7a
push ebx
call fcn.0053061e
pop ecx
jmp 0x4c8d9e
cmp dword [0x7047b4], 0
jne 0x4c8d97
push dword [ebp - 0x438]
lea eax, [ebp - 0x12c]
push eax
push str.:6:LoadSound___s___FAILED:_The_file_format_is_invalid._The_Data_Chunk_size___ld__could_not_be_read.
call fcn.0042bd38
jmp 0x4c8e3f
cmp dword [0x7047b4], 0
jne 0x4c9160
push dword [ebp - 0x438]
lea eax, [ebp - 0x12c]
push eax
push str.:6:LoadSound___s___FAILED:_The_file_format_is_invalid._The_Format_Chunk_size___ld__could_not_be_read.
call fcn.0042bd38
add esp, 0xc
mov ecx, edi
call fcn.00435239
xor eax, eax
call fcn.00549b54
ret