Function at 0x21105c90
Capabilities:
Create directory

Disassembly:
mov ecx, dword [esp + 4]
sub esp, 0x190
test byte [esp + 0x1a0], 2
push ebx
push ebp
mov ebp, dword [esp + 0x1a0]
push esi
push edi
je 0x21105e27
lea eax, [ecx + 0x18]
lea edx, [esp + 0x20]
sub edx, eax
lea esp, [esp]
mov cl, byte [eax]
mov byte [eax + edx], cl
add eax, 1
test cl, cl
jne 0x21105cc0
lea eax, [esp + 0x20]
xor edx, edx
lea esi, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x21105cd5
sub eax, esi
je 0x21105d03
mov bl, 0x2e
cmp byte [esp + edx + 0x20], bl
je 0x21105d03
lea eax, [esp + 0x20]
add edx, 1
lea esi, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x21105cf4
sub eax, esi
cmp edx, eax
jb 0x21105ce4
mov ecx, dword [str._Samples]
lea eax, [esp + edx + 0x20]
mov edx, dword [0x2114ffc8]
mov dword [eax], ecx
mov cl, byte [0x2114ffcc]
mov dword [eax + 4], edx
push 0
lea edx, [esp + 0x24]
push edx
mov byte [eax + 8], cl
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x21105d36
xor eax, eax
jmp 0x21105d3b
mov eax, dword [0x2118b3c8]
mov ecx, eax
add eax, 1
push ecx
mov dword [0x2118b3c8], eax
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x128]
push str._s_d.wav
push ecx
call fcn.21132f30
mov eax, dword [ebp + 4]
mov edx, eax
and edx, 1
add edx, eax
lea ebx, [edx + ebp + 8]
lea edi, [ebp + 0xc]
add esp, 0x10
cmp edi, ebx
jae 0x21105df1
cmp dword [edi], 0x5453494c
jne 0x21105dd8
cmp dword [edi + 8], 0x4f464e49
jne 0x21105dd8
mov eax, dword [edi + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea ebp, [ecx + edi + 8]
lea esi, [edi + 0xc]
cmp esi, ebp
jae 0x21105dd8
jmp 0x21105da0
cmp dword [esi], 0x4d414e49
jne 0x21105dc6
lea edx, [esi + 8]
push edx
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x128]
push str._s_s.wav
push ecx
call fcn.21132f30
add esp, 0x10
mov eax, dword [esi + 4]
mov edx, eax
and edx, 1
add edx, eax
lea esi, [esi + edx + 8]
cmp esi, ebp
jb 0x21105da0
mov eax, dword [edi + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea edi, [edi + ecx + 8]
cmp edi, ebx
jb 0x21105d75
mov ebp, dword [esp + 0x1a8]
mov edx, dword [ebp + 4]
mov esi, dword [ebp]
mov edi, dword [ebp + 8]
add edx, 8
push edx
push ebp
lea eax, [esp + 0x128]
push eax
mov dword [ebp], 0x46464952
mov dword [ebp + 8], 0x45564157
call sym.mss32.dll__AIL_file_write_12
mov ecx, dword [esp + 0x1a4]
mov dword [ebp], esi
mov dword [ebp + 8], edi
mov edx, dword [ecx + 0x120]
mov byte [edx + 7], 0
mov eax, dword [ecx + 0x120]
mov eax, dword [eax + 4]
xor edx, edx
test eax, eax
mov dword [esp + 0x14], edx
jbe 0x21105e69
mov ecx, dword [ecx + 0x124]
lea ebx, [ebx]
mov esi, dword [ecx]
cmp esi, dword [esp + 0x1ac]
je 0x21105e65
add edx, 1
add ecx, 4
cmp edx, eax
jb 0x21105e50
mov dword [esp + 0x14], edx
cmp edx, eax
je 0x21106113
add ebp, 0xc
mov dword [esp + 0x18], ebp
mov esi, str.fmt
mov dword [esp + 0x1c], ebp
mov edi, ebp
mov edx, 4
sub esi, ebp
lea ebx, [ebx]
mov cl, byte [edi]
mov al, cl
sub al, 0x61
cmp al, 0x19
ja 0x21105e9d
add cl, 0xe0
mov al, byte [esi + edi]
mov bl, al
sub bl, 0x61
cmp bl, 0x19
ja 0x21105eac
add al, 0xe0
cmp cl, al
jl 0x21105f2b
jg 0x21105f2b
test cl, cl
je 0x21105ebe
add edi, 1
sub edx, 1
jne 0x21105e90
cmp word [ebp + 8], 1
je 0x21105f0e
mov ebp, dword [esp + 0x18]
mov esi, str.pcm
mov dword [esp + 0x1c], ebp
mov edi, ebp
mov edx, 4
sub esi, ebp
jmp 0x21105ee0
mov cl, byte [edi]
mov al, cl
sub al, 0x61
cmp al, 0x19
ja 0x21105eed
add cl, 0xe0
mov al, byte [esi + edi]
mov bl, al
sub bl, 0x61
cmp bl, 0x19
ja 0x21105efc
add al, 0xe0
cmp cl, al
jl 0x21105f3e
jg 0x21105f3e
test cl, cl
je 0x21105f0e
add edi, 1
sub edx, 1
jne 0x21105ee0
movzx eax, word [ebp + 0xa]
xor ecx, ecx
cmp ax, 1
mov dword [esp + 0x10], ecx
jne 0x21105f51
cmp word [ebp + 0x16], 8
jne 0x21105f51
mov dword [esp + 0x10], ecx
jmp 0x21105f97
mov eax, dword [ebp + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea ebp, [ecx + ebp + 8]
jmp 0x21105e78
mov eax, dword [ebp + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea ebp, [ecx + ebp + 8]
jmp 0x21105ec9
cmp ax, 2
jne 0x21105f68
cmp word [ebp + 0x16], 8
jne 0x21105f68
mov dword [esp + 0x10], 2
jmp 0x21105f97
cmp ax, 1
mov ecx, 0x10
jne 0x21105f83
cmp word [ebp + 0x16], cx
jne 0x21105f83
mov dword [esp + 0x10], 1
jmp 0x21105f97
cmp ax, 2
jne 0x21105f97
cmp word [ebp + 0x16], cx
jne 0x21105f97
mov dword [esp + 0x10], 3
mov ebp, dword [esp + 0x18]
jmp 0x21105fa0
mov esi, str.data
mov edi, ebp
mov ebx, 4
sub esi, ebp
mov edi, edi
mov cl, byte [edi]
mov dl, cl
sub dl, 0x61
cmp dl, 0x19
ja 0x21105fbf
add cl, 0xe0
mov al, byte [edi + esi]
mov dl, al
sub dl, 0x61
cmp dl, 0x19
ja 0x21105fce
add al, 0xe0
cmp cl, al
jl 0x2110611e
jg 0x2110611e
test cl, cl
je 0x21105fe8
add edi, 1
sub ebx, 1
jne 0x21105fb0
mov ecx, dword [esp + 0x14]
mov ebx, dword [esp + 0x1a4]
mov edx, dword [ebx + 0x128]
mov eax, ecx
shl eax, 4
sub eax, ecx
mov ecx, dword [esp + 0x10]
add eax, eax
add eax, eax
mov dword [eax + edx + 4], ecx
mov edx, dword [esp + 0x1c]
mov ecx, dword [edx + 0xc]
fild dword [edx + 0xc]
test ecx, ecx
jge 0x21106020
fadd dword [0x21158450]
mov edx, dword [ebx + 0x128]
mov esi, dword [esp + 0x18]
fstp dword [eax + edx + 8]
mov edx, dword [ebp + 4]
mov ecx, dword [ebx + 0x128]
mov dword [eax + ecx + 0x10], edx
mov ecx, dword [ebx + 0x128]
add ebp, 8
mov dword [eax + ecx + 0xc], ebp
mov edx, dword [ebx + 0x128]
mov ebp, dword [esp + 0x1a8]
mov dword [eax + edx + 0x18], 0
mov ecx, dword [ebp + 4]
mov edx, ecx
and edx, 1
add edx, ecx
lea ecx, [edx + ebp + 8]
cmp esi, ecx
jae 0x21106106
cmp dword [esi], 0x706d7377
jne 0x211060e2
mov edx, dword [ebx + 0x128]
mov edi, dword [esi + 8]
mov dword [eax + edx + 0x18], edi
mov edi, dword [esi + 0xc]
lea ecx, [esi + 8]
lea edx, [eax + edx + 0x18]
mov dword [edx + 4], edi
mov edi, dword [ecx + 8]
mov dword [edx + 8], edi
mov edi, dword [ecx + 0xc]
mov dword [edx + 0xc], edi
mov edi, dword [ecx + 0x10]
mov dword [edx + 0x10], edi
mov edx, dword [ebx + 0x128]
cmp dword [eax + edx + 0x28], 0
lea edi, [eax + edx]
je 0x211060d4
mov edx, dword [ecx]
add edx, ecx
lea ecx, [edi + 0x2c]
mov edi, dword [edx]
mov dword [ecx], edi
mov edi, dword [edx + 4]
mov dword [ecx + 4], edi
mov edi, dword [edx + 8]
mov dword [ecx + 8], edi
mov edx, dword [edx + 0xc]
mov dword [ecx + 0xc], edx
mov ecx, dword [ebx + 0x128]
mov dword [eax + ecx + 0x14], 1
mov ecx, dword [esi + 4]
mov edx, ecx
and edx, 1
add edx, ecx
mov ecx, dword [ebp + 4]
lea esi, [esi + edx + 8]
mov edx, ecx
and edx, 1
add edx, ecx
lea ecx, [edx + ebp + 8]
cmp esi, ecx
jb 0x21106073
mov edx, dword [ebx + 0x128]
mov dword [eax + edx], 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x190
ret
mov eax, dword [ebp + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea ebp, [ecx + ebp + 8]
jmp 0x21105fa0