Function at 0x2112d010
Capabilities:
Check mutex on windows

Disassembly:
sub esp, 0xa8
push ebx
push ebp
push esi
mov esi, eax
mov eax, dword [esi + 0xb0]
xor ebp, ebp
cmp eax, ebp
push edi
je 0x2112d033
push eax
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
jne 0x2112d03e
call sym.mss32.dll__AIL_HWND_0
mov dword [esi + 0xb0], eax
cmp dword [0x211566a0], ebp
je 0x2112d061
mov ecx, dword [esi + 0x100]
xor eax, eax
cmp ecx, ebp
sete al
mov dword [esp + 0x14], 4
mov dword [esp + 0x1c], eax
jmp 0x2112d06d
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x14], 1
mov ebx, dword [sym.imp.KERNEL32.dll_CreateMutexA]
lea ecx, [esi + 0xa0]
lea edi, [esi + 0xac]
mov dword [esp + 0x10], ecx
mov dword [esp + 0x18], edi
mov eax, dword [edi]
cmp eax, ebp
je 0x2112d095
mov edx, dword [eax]
push eax
call dword [edx + 8]
mov dword [edi], ebp
mov eax, dword [esp + 0x10]
mov eax, dword [eax]
cmp eax, ebp
je 0x2112d0ab
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov edx, dword [esp + 0x10]
mov dword [edx], ebp
mov eax, dword [0x211566c0]
cmp eax, ebp
je 0x2112d0c5
mov eax, dword [0x211592a0]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [0x211566c0]
cmp eax, ebp
mov edi, dword [0x211566a8]
je 0x2112d0f4
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d0e6
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d0d8
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [0x211566c0]
cmp edi, ebp
jne 0x2112d146
cmp eax, ebp
je 0x2112d109
mov ecx, dword [0x211592a0]
push ecx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, dword [esp + 0x10]
mov eax, dword [esi + 0x9c]
push ebp
push edx
push eax
call dword [0x21159170]
test eax, eax
mov eax, dword [0x211566c0]
jl 0x2112d3ee
cmp eax, ebp
je 0x2112d197
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d18e
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d136
jmp 0x2112d18e
cmp eax, ebp
je 0x2112d157
mov ecx, dword [0x211592a0]
push ecx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, dword [esp + 0x10]
mov eax, dword [esi + 0x9c]
push ebp
push edx
push eax
call edi
test eax, eax
mov eax, dword [0x211566c0]
jl 0x2112d42e
cmp eax, ebp
je 0x2112d197
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d18e
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d180
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
xor eax, eax
mov ecx, 0x18
lea edi, [esp + 0x58]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x10]
mov eax, dword [ecx]
lea ecx, [esp + 0x58]
push ecx
mov dword [esi + 0xa8], ebp
mov dword [esp + 0x5c], 0x60
mov edx, dword [eax]
push eax
call dword [edx + 0x10]
test eax, eax
jne 0x2112d1d7
mov edx, dword [esp + 0x5c]
shr edx, 5
and edx, 1
mov dword [esi + 0xa8], edx
cmp dword [esi + 0xa8], ebp
je 0x2112d1ee
cmp dword [esp + 0x14], 4
jne 0x2112d1ee
mov dword [esp + 0x14], 2
cmp dword [0x211566c0], ebp
je 0x2112d202
mov eax, dword [0x211592a0]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov edx, dword [esp + 0x14]
mov edi, dword [esp + 0x10]
mov eax, dword [edi]
mov ecx, dword [eax]
push edx
mov edx, dword [esi + 0xb0]
push edx
push eax
call dword [ecx + 0x18]
test eax, eax
jl 0x2112d46e
cmp dword [0x211566c0], ebp
je 0x2112d24a
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d241
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d233
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 0x14]
mov dword [esi + 0xa4], eax
xor eax, eax
mov ecx, 9
lea edi, [esp + 0x34]
rep stosd dword es:[edi], eax
cmp dword [0x211566a4], ebp
mov dword [esp + 0x34], 0x24
mov dword [esp + 0x38], 1
je 0x2112d281
mov dword [esp + 0x38], 0x11
cmp dword [0x211566c0], ebp
mov dword [esp + 0x3c], ebp
mov dword [esp + 0x44], ebp
je 0x2112d29e
mov ecx, dword [0x211592a0]
push ecx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov ecx, dword [esp + 0x18]
mov edi, dword [esp + 0x10]
mov eax, dword [edi]
mov edx, dword [eax]
push ebp
push ecx
lea ecx, [esp + 0x3c]
push ecx
push eax
call dword [edx + 0xc]
test eax, eax
jl 0x2112d4b5
cmp dword [0x211566c0], ebp
je 0x2112d2e7
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d2de
mov edi, edi
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d2d0
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp dword [esp + 0x1c], ebp
je 0x2112d35d
movzx edx, word [esi + 0x98]
imul edx, dword [esi + 0x90]
lea edi, [esi + 0x8c]
mov word [edi], 1
mov dword [esi + 0x94], edx
cmp dword [0x211566c0], ebp
je 0x2112d320
mov eax, dword [0x211592a0]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov ecx, dword [esp + 0x18]
mov eax, dword [ecx]
mov edx, dword [eax]
push edi
push eax
call dword [edx + 0x38]
test eax, eax
jl 0x2112d4fe
cmp dword [0x211566c0], ebp
je 0x2112d35d
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d354
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d346
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 0x18]
mov eax, dword [eax]
mov ecx, dword [eax]
push 0
push 0x12
lea edx, [esp + 0x28]
push edx
push eax
call dword [ecx + 0x14]
mov ax, word [esp + 0x22]
cmp ax, word [esi + 0x8e]
mov ecx, dword [esi + 0x100]
mov edi, dword [esp + 0x2e]
mov ebp, dword [esp + 0x24]
jne 0x2112d3bf
cmp ebp, dword [esi + 0x90]
jne 0x2112d3bf
mov dx, word [esp + 0x2c]
cmp dx, word [esi + 0x98]
jne 0x2112d3bf
cmp di, word [esi + 0x9a]
jne 0x2112d3bf
mov dx, word [esp + 0x20]
cmp dx, word [esi + 0x8c]
je 0x2112d54e
test ecx, ecx
jne 0x2112d54e
mov ecx, dword [esp + 0x1c]
test ecx, ecx
jne 0x2112d54e
mov edi, dword [esp + 0x18]
mov dword [esp + 0x1c], 1
mov dword [esp + 0x14], 2
xor ebp, ebp
jmp 0x2112d087
cmp eax, ebp
je 0x2112d417
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d40e
jmp 0x2112d400
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d400
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push str.DirectSoundCreate___failed.
call sym.mss32.dll__AIL_set_error_4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xa8
ret
cmp eax, ebp
je 0x2112d457
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d44e
jmp 0x2112d440
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d440
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push str.DirectSoundCreate___custom_handler_failed.
call sym.mss32.dll__AIL_set_error_4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xa8
ret
mov eax, dword [edi]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
cmp dword [0x211566c0], ebp
je 0x2112d49e
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d495
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d487
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push str.SetCooperativeLevel___failed.
call sym.mss32.dll__AIL_set_error_4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xa8
ret
mov eax, dword [edi]
mov edx, dword [eax]
push eax
call dword [edx + 8]
cmp dword [0x211566c0], ebp
je 0x2112d4e7
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d4de
mov edi, edi
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d4d0
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push str.CreateSoundBuffer___failed_on_primary_buffer.
call sym.mss32.dll__AIL_set_error_4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xa8
ret
mov eax, dword [esp + 0x10]
mov eax, dword [eax]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
cmp dword [0x211566c0], ebp
je 0x2112d537
mov eax, dword [0x211592a0]
cmp eax, ebp
jne 0x2112d52e
jmp 0x2112d520
push ebp
push ebp
push ebp
call ebx
cmp eax, ebp
mov dword [0x211592a0], eax
je 0x2112d520
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push str.SetFormat___failed_on_primary_buffer.
call sym.mss32.dll__AIL_set_error_4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xa8
ret
xor edx, edx
cmp di, 0x10
sete dl
xor ecx, ecx
mov word [esi + 0x8e], ax
mov dword [esi + 0x90], ebp
mov word [esi + 0x9a], di
mov word [esi + 0x8c], 1
inc edx
cmp ax, 2
sete cl
mov eax, edx
inc ecx
imul eax, ecx
movzx edx, ax
imul edx, ebp
mov word [esi + 0x98], ax
cmp dword [esp + 0x14], 4
mov dword [esi + 0x94], edx
jne 0x2112d5b0
mov ecx, dword [esp + 0x18]
mov esi, dword [ecx]
movzx eax, di
push eax
call fcn.2112cf00
add esp, 4
mov eax, dword [0x211566c0]
test eax, eax
je 0x2112d5c6
mov edx, dword [0x211592a0]
push edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [esp + 0x18]
mov eax, dword [eax]
mov ecx, dword [eax]
push 1
push 0
push 0
push eax
call dword [ecx + 0x30]
mov eax, dword [0x211566c0]
test eax, eax
je 0x2112d60a
mov eax, dword [0x211592a0]
test eax, eax
jne 0x2112d601
lea ebx, [ebx]
push 0
push 0
push 0
call ebx
test eax, eax
mov dword [0x211592a0], eax
je 0x2112d5f0
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xa8
ret