Function at 0x211061a0
Capabilities:
Create directory

Disassembly:
mov al, byte [esp + 0x10]
sub esp, 0x190
test al, 2
push ebx
push ebp
push esi
push edi
je 0x2110632f
mov eax, dword [esp + 0x1a4]
add eax, 0x18
lea edx, [esp + 0x20]
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x211061c6
lea eax, [esp + 0x20]
xor edx, edx
lea esi, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x211061e0
sub eax, esi
mov dword [esp + 0x18], eax
je 0x2110620d
mov bl, 0x2e
cmp byte [esp + edx + 0x20], bl
je 0x2110620d
lea eax, [esp + 0x20]
inc edx
lea esi, [eax + 1]
nop
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x21106200
sub eax, esi
cmp edx, eax
jb 0x211061f1
mov ecx, dword [str._Samples]
lea eax, [esp + edx + 0x20]
mov edx, dword [0x2114afe8]
mov dword [eax], ecx
mov cl, byte [0x2114afec]
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 0x21106240
xor eax, eax
jmp 0x21106245
mov eax, dword [0x21159334]
mov ecx, eax
inc eax
push ecx
mov dword [0x21159334], eax
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x128]
push str._s_d.wav
push ecx
call fcn.21130163
mov ebp, dword [esp + 0x1b8]
mov eax, dword [ebp + 4]
mov edx, eax
and edx, 1
add edx, eax
lea ecx, [edx + ebp + 8]
lea edi, [ebp + 0xc]
add esp, 0x10
cmp edi, ecx
mov dword [esp + 0x18], ecx
jae 0x211062fe
cmp dword [edi], 0x5453494c
jne 0x211062ec
cmp dword [edi + 8], 0x4f464e49
jne 0x211062ec
mov eax, dword [edi + 4]
mov edx, eax
and edx, 1
add edx, eax
lea ebx, [edx + edi + 8]
lea esi, [edi + 0xc]
cmp esi, ebx
jae 0x211062ec
mov edi, edi
cmp dword [esi], 0x4d414e49
jne 0x211062d6
lea eax, [esi + 8]
push eax
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x128]
push str._s_s.wav
push edx
call fcn.21130163
add esp, 0x10
mov eax, dword [esi + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea esi, [esi + ecx + 8]
cmp esi, ebx
jb 0x211062b0
mov ecx, dword [esp + 0x18]
mov eax, dword [edi + 4]
mov edx, eax
and edx, 1
add edx, eax
lea edi, [edi + edx + 8]
cmp edi, ecx
jb 0x21106288
mov eax, dword [ebp + 4]
mov esi, dword [ebp]
mov edi, dword [ebp + 8]
add eax, 8
push eax
push ebp
lea ecx, [esp + 0x128]
push ecx
mov dword [ebp], 0x46464952
mov dword [ebp + 8], 0x45564157
call sym.mss32.dll__AIL_file_write_12
mov dword [ebp], esi
mov dword [ebp + 8], edi
jmp 0x21106336
mov ebp, dword [esp + 0x1a8]
mov edx, dword [esp + 0x1a4]
mov eax, dword [edx + 0x120]
mov byte [eax + 7], 0
mov eax, dword [edx + 0x120]
mov eax, dword [eax + 4]
xor ecx, ecx
test eax, eax
mov dword [esp + 0x1c], ecx
jbe 0x21106377
mov edx, dword [edx + 0x124]
mov esi, dword [esp + 0x1ac]
cmp dword [edx], esi
je 0x21106373
inc ecx
add edx, 4
cmp ecx, eax
jb 0x21106360
mov dword [esp + 0x1c], ecx
cmp ecx, eax
je 0x2110663b
add ebp, 0xc
mov dword [esp + 0x14], ebp
jmp 0x21106390
mov edi, str.fmt
mov esi, ebp
mov dword [esp + 0x10], 4
sub edi, ebp
movsx ecx, byte [esi]
push ecx
call fcn.21130554
movsx edx, byte [edi + esi]
push edx
mov bl, al
call fcn.21130554
add esp, 8
cmp bl, al
jl 0x21106435
jg 0x21106435
test bl, bl
je 0x211063d3
mov eax, dword [esp + 0x10]
inc esi
dec eax
mov dword [esp + 0x10], eax
jne 0x211063a1
cmp word [ebp + 8], 1
je 0x21106468
mov ebp, dword [esp + 0x1a8]
add ebp, 0xc
mov dword [esp + 0x14], ebp
lea esp, [esp]
mov edi, str.pcm
mov esi, ebp
mov dword [esp + 0x10], 4
sub edi, ebp
movsx eax, byte [esi]
push eax
call fcn.21130554
movsx ecx, byte [edi + esi]
push ecx
mov bl, al
call fcn.21130554
add esp, 8
cmp bl, al
jl 0x2110644e
jg 0x2110644e
test bl, bl
je 0x21106464
mov eax, dword [esp + 0x10]
inc esi
dec eax
mov dword [esp + 0x10], eax
je 0x21106464
mov ebp, dword [esp + 0x14]
jmp 0x21106401
mov eax, dword [ebp + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea edx, [ecx + ebp + 8]
mov dword [esp + 0x14], edx
mov ebp, edx
jmp 0x21106390
mov eax, dword [ebp + 4]
mov edx, eax
and edx, 1
add edx, eax
lea eax, [edx + ebp + 8]
mov dword [esp + 0x14], eax
mov ebp, eax
jmp 0x211063f0
mov ebp, dword [esp + 0x14]
mov ax, word [ebp + 0xa]
xor ecx, ecx
cmp ax, 1
mov dword [esp + 0x10], ecx
jne 0x21106485
cmp word [ebp + 0x16], 8
jne 0x21106485
mov dword [esp + 0x10], ecx
jmp 0x211064cb
cmp ax, 2
jne 0x2110649c
cmp word [ebp + 0x16], 8
jne 0x2110649c
mov dword [esp + 0x10], 2
jmp 0x211064cb
cmp ax, 1
mov ecx, 0x10
jne 0x211064b7
cmp word [ebp + 0x16], cx
jne 0x211064b7
mov dword [esp + 0x10], 1
jmp 0x211064cb
cmp ax, 2
jne 0x211064cb
cmp word [ebp + 0x16], cx
jne 0x211064cb
mov dword [esp + 0x10], 3
mov edi, dword [esp + 0x1a8]
add edi, 0xc
jmp 0x211064e0
mov ebp, str.data
mov esi, edi
mov dword [esp + 0x18], 4
sub ebp, edi
movsx ecx, byte [esi]
push ecx
call fcn.21130554
movsx edx, byte [esi + ebp]
push edx
mov bl, al
call fcn.21130554
add esp, 8
cmp bl, al
jl 0x21106646
jg 0x21106646
test bl, bl
je 0x21106527
mov eax, dword [esp + 0x18]
inc esi
dec eax
mov dword [esp + 0x18], eax
jne 0x211064f1
mov eax, dword [esp + 0x1c]
mov ebp, dword [esp + 0x1a4]
imul eax, eax, 0x3c
mov edx, dword [ebp + 0x128]
mov ecx, dword [esp + 0x10]
mov dword [eax + edx + 4], ecx
mov edx, dword [esp + 0x14]
mov ecx, dword [edx + 0xc]
test ecx, ecx
fild dword [edx + 0xc]
jge 0x21106557
fadd dword [0x2114bd78]
mov edx, dword [ebp + 0x128]
mov esi, dword [esp + 0x1a8]
fstp dword [eax + edx + 8]
mov edx, dword [edi + 4]
mov ecx, dword [ebp + 0x128]
mov dword [eax + ecx + 0x10], edx
mov ecx, dword [ebp + 0x128]
add edi, 8
mov dword [eax + ecx + 0xc], edi
mov edx, dword [ebp + 0x128]
mov dword [eax + edx + 0x18], 0
mov ecx, dword [esi + 4]
mov edx, dword [esp + 0x1a8]
mov edi, ecx
and edi, 1
add edi, ecx
add edx, 0xc
lea ecx, [edi + esi + 8]
cmp edx, ecx
jae 0x2110662e
cmp dword [edx], 0x706d7377
jne 0x2110660e
mov ecx, dword [ebp + 0x128]
lea ebx, [edx + 8]
lea edi, [eax + ecx + 0x18]
mov ecx, 5
mov esi, ebx
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebx + 0x10]
test ecx, ecx
je 0x211065f9
mov ecx, dword [ebx]
mov esi, dword [ebp + 0x128]
add ecx, ebx
mov edi, dword [ecx]
lea esi, [eax + esi + 0x2c]
mov dword [esi], edi
mov edi, dword [ecx + 4]
mov dword [esi + 4], edi
mov edi, dword [ecx + 8]
mov dword [esi + 8], edi
mov ecx, dword [ecx + 0xc]
mov dword [esi + 0xc], ecx
mov ecx, dword [ebp + 0x128]
mov esi, dword [esp + 0x1a8]
mov dword [eax + ecx + 0x14], 1
mov ecx, dword [edx + 4]
mov edi, ecx
and edi, 1
add edi, ecx
mov ecx, dword [esi + 4]
lea edx, [edx + edi + 8]
mov edi, ecx
and edi, 1
add edi, ecx
lea ecx, [edi + esi + 8]
cmp edx, ecx
jb 0x211065b0
mov edx, dword [ebp + 0x128]
mov dword [eax + edx], 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x190
ret
mov eax, dword [edi + 4]
mov ecx, eax
and ecx, 1
add ecx, eax
lea edi, [edi + ecx + 8]
jmp 0x211064e0