Function at 0x4c27e0
Capabilities:
Terminate process

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
push edi
mov edi, ecx
xor ebx, ebx
mov dword [esp + 0x18], edi
mov esi, dword [edi]
cmp esi, ebx
jne 0x4c2801
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x10
ret 0xc
mov ebp, dword [esp + 0x24]
cmp byte [ebp], 0
jne 0x4c2817
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x10
ret 0xc
cmp esi, ebx
je 0x4c2842
mov al, byte [esi + 0xd]
test al, al
je 0x4c2842
mov byte [esi + 0x60], 1
mov al, byte [esi + 0xd]
test al, al
je 0x4c2842
mov al, byte [esi + 0xc]
test al, al
jne 0x4c2842
mov ecx, edi
call fcn.004c2630
mov al, byte [esi + 0xd]
test al, al
jne 0x4c282d
mov byte [esi + 0x60], 0
mov eax, dword [0x5e1cc0]
cmp eax, ebx
jne 0x4c285f
mov byte [esi + 0x60], 1
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x10
ret 0xc
mov ecx, dword [esi + 0x14]
mov dword [esi + 0x14], ebx
cmp ecx, ebx
je 0x4c2870
mov eax, dword [ecx]
push 1
call dword [eax + 4]
mov ecx, dword [esi + 0x18]
mov dword [esi + 0x18], ebx
cmp ecx, ebx
je 0x4c2881
mov edx, dword [ecx]
push 1
call dword [edx + 4]
mov ecx, str.Stream_sound
call fcn.004505e0
mov edx, 0x410
mov ecx, ebp
call fcn.004b7080
mov dword [esi + 0x14], eax
call fcn.00450600
mov ecx, dword [esi + 0x14]
cmp ecx, ebx
jne 0x4c28b6
mov byte [esi + 0x60], 1
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x10
ret 0xc
call fcn.0048a0b0
mov edx, dword [esp + 0x28]
mov dword [esi + 0x24], eax
sub eax, edx
lea ebp, [esi + 0x2c]
mov dword [esi + 0x28], eax
mov al, byte [esp + 0x2c]
mov byte [esi + 0x62], al
mov ecx, 9
xor eax, eax
mov edi, ebp
mov byte [esi + 0x61], 0
mov dword [esi + 0x5c], ebx
mov dword [esi + 0x58], ebx
rep stosd dword es:[edi], eax
mov ecx, dword [esi + 0x14]
mov dword [ebp], 0x24
mov dword [esi + 0x30], 0xe0
mov dword [esi + 0x34], 0x186a0
call fcn.0044e660
lea ebx, [esi + 0x50]
mov dword [esi + 0x3c], eax
xor edi, edi
mov eax, dword [ebx]
cmp eax, edi
je 0x4c2919
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [ebx], edi
mov eax, dword [0x5e1cc0]
push edi
push ebx
push ebp
mov edx, dword [eax]
push eax
call dword [edx + 0xc]
test eax, eax
je 0x4c293d
mov dword [ebx], edi
mov byte [esi + 0x60], 1
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x10
ret 0xc
lea edx, [esp + 0x1c]
push edi
mov eax, dword [ebx]
push edx
lea edx, [esp + 0x1c]
mov ecx, dword [eax]
push edx
lea edx, [esp + 0x30]
push edx
lea edx, [esp + 0x20]
push edx
push 0x186a0
push edi
push eax
call dword [ecx + 0x2c]
test eax, eax
je 0x4c2985
mov ecx, dword [esi + 0x14]
mov dword [esi + 0x14], edi
cmp ecx, edi
je 0x4c2975
mov eax, dword [ecx]
push 1
call dword [eax + 4]
mov byte [esi + 0x60], 1
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x10
ret 0xc
mov eax, dword [esp + 0x24]
test eax, eax
je 0x4c2a16
mov ecx, dword [esi + 0x28]
mov edi, eax
cmp eax, ecx
jbe 0x4c299c
mov edi, ecx
mov eax, dword [esp + 0x28]
test eax, eax
je 0x4c29ad
mov ecx, dword [esi + 0x14]
push eax
mov edx, dword [ecx]
call dword [edx + 0x10]
mov ecx, dword [esi + 0x14]
mov edx, dword [esp + 0x10]
push edi
push edx
mov eax, dword [ecx]
call dword [eax + 8]
mov edi, eax
mov eax, dword [esi + 0x28]
sub eax, edi
mov dword [esi + 0x28], eax
je 0x4c29cb
test edi, edi
jne 0x4c2a16
mov byte [esi + 0x61], 1
mov dword [esi + 0x5c], edi
mov ecx, dword [esp + 0x24]
cmp edi, ecx
jae 0x4c2a16
mov eax, dword [esi + 0x3c]
sub ecx, edi
xor edx, edx
mov ebp, ecx
cmp word [eax + 0xe], 8
setne dl
dec edx
and edx, 0x80
mov al, dl
mov edx, dword [esp + 0x10]
add edi, edx
mov dl, al
mov dh, dl
mov eax, edx
shl eax, 0x10
mov ax, dx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, ebp
and ecx, 3
rep stosb byte es:[edi], al
mov edi, dword [esp + 0x24]
mov edx, dword [esp + 0x14]
mov eax, dword [ebx]
push 0
push edx
mov edx, dword [esp + 0x18]
mov ecx, dword [eax]
push edi
push edx
push eax
call dword [ecx + 0x4c]
cmp edi, 0x186a0
mov dword [esi + 0x54], edi
jb 0x4c2a3f
add edi, 0xfffe7960
mov dword [esi + 0x54], edi
mov eax, dword [esp + 0x18]
mov cl, byte [eax + 4]
test cl, cl
je 0x4c2a71
mov eax, dword [esi + 0x10]
test eax, eax
jne 0x4c2a71
push 1
push esi
push fcn.004c2bb0
push 5
push 0x32
call dword [sym.imp.WINMM.dll_timeSetEvent]
test eax, eax
mov dword [esi + 0x10], eax
jne 0x4c2a71
push 0xffffffffffffffff
call fcn.005009bb
mov eax, dword [ebx]
mov edx, dword [esi]
push edx
push eax
mov ecx, dword [eax]
call dword [ecx + 0x3c]
mov al, byte [esi + 0xc]
test al, al
jne 0x4c2a95
mov ebx, dword [ebx]
push 1
push 0
push 0
mov eax, dword [ebx]
push ebx
call dword [eax + 0x30]
mov byte [esi + 0xd], 1
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
add esp, 0x10
ret 0xc