Function at 0x40ae40
Capabilities:
Delete file
Move file
Read file on windows

Disassembly:
mov eax, dword [0x4f68c8]
sub esp, 0x28
push ebx
push esi
mov esi, dword [0x4f68b0]
add esi, ecx
push edi
cmp esi, eax
jge 0x40b27c
test eax, eax
je 0x40b27c
mov bl, byte [0x550b68]
test bl, bl
je 0x40ae74
xor cl, cl
call fcn.00422ed0
mov dword [0x4ecae8], 0xffffffff
call fcn.0040b7a0
mov eax, dword [0x4f6768]
lea ecx, [esi + esi*2]
lea edi, [eax + ecx*4]
movsx ecx, bl
mov al, byte [edi + 4]
sub ecx, 1
je 0x40b13c
sub ecx, 1
je 0x40afdf
mov esi, dword [edi]
test al, al
je 0x40aeb9
mov ecx, esi
pop edi
pop esi
pop ebx
add esp, 0x28
jmp fcn.00409d50
push 0x4ddc24
push esi
call fcn.004893d7
add esp, 8
test eax, eax
jne 0x40aee6
push eax
push str.Couldnt_open_file_directory__No_permission_or_in_use_
push str.System_message
push eax
call fcn.00441180
add esp, 0x10
pop edi
pop esi
pop ebx
add esp, 0x28
ret
push eax
call fcn.00489118
add esp, 4
mov ecx, esi
call fcn.00409640
cmp eax, 0xffffffff
jne 0x40af18
push 0
push str.The_file_is_too_big_and_cant_be_loaded__over_2GB_.
push str.System_message
push 0
call fcn.00441180
add esp, 0x10
pop edi
pop esi
pop ebx
add esp, 0x28
ret
cmp eax, 0x8000000
jl 0x40af3f
push 0
push str.Are_you_sure_you_want_to_load_such_a_big_file_
push str.System_request
push 2
call fcn.00441180
add esp, 0x10
cmp ax, 1
jne 0x40b27c
movzx eax, byte [0x4edf6e]
dec eax
cmp eax, 3
ja case.default.0x40af4c
jmp dword [eax*4 + 0x40b284]
mov ecx, esi
pop edi
pop esi
pop ebx
add esp, 0x28
jmp fcn.0041b0e0
mov dl, byte [0x54e52c]
mov ecx, esi
push 0
call fcn.0043e220
add esp, 4
pop edi
pop esi
pop ebx
add esp, 0x28
ret
mov ecx, esi
pop edi
pop esi
pop ebx
add esp, 0x28
jmp 0x4296b0
mov ecx, esi
pop edi
pop esi
pop ebx
add esp, 0x28
jmp 0x4294f0
cmp byte [0x54ef62], 0
je 0x40afcb
mov dword [0x4ecae8], 0xffffffff
call fcn.0040b7a0
push 0
push str.You_have_unsaved_changes_in_your_song._Load_new_song_and_lose_all_changes_
push str.System_request
push 2
call fcn.00441180
add esp, 0x10
cmp ax, 1
jne 0x40b27c
mov byte [0x54e4e3], 3
mov ecx, esi
pop edi
pop esi
pop ebx
add esp, 0x28
jmp fcn.004206b0
test al, al
jne 0x40b023
mov eax, dword [edi]
mov ecx, 0x4de9bc
nop word [eax + eax]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40b016
test dx, dx
je 0x40b012
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40b016
add eax, 4
add ecx, 4
test dx, dx
jne 0x40aff0
xor eax, eax
jmp 0x40b01b
sbb eax, eax
or eax, 1
test eax, eax
je 0x40b27c
mov ecx, dword [edi]
mov dl, 1
call fcn.004461b0
mov esi, eax
test esi, esi
je 0x40b27c
push 0x104
push esi
push dword [0x4f68c4]
call fcn.0048aa80
mov eax, dword [0x4f68c4]
add esp, 0xc
push esi
mov byte [eax + 0x104], 0
call fcn.00488f53
mov edx, dword [0x4f68c4]
add esp, 4
test edx, edx
je 0x40b091
cmp byte [edx], 0
je 0x40b091
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40b073
sub ecx, esi
xor eax, eax
test ecx, ecx
jle 0x40b091
cmp byte [edx + eax], 0x3f
jne 0x40b08c
mov byte [edx + eax], 0x20
inc eax
cmp eax, ecx
jl 0x40b082
cmp byte [edi + 4], 0
mov eax, str.Enter_new_filename:
push 0x104
push edx
mov edx, str.Enter_new_directory_name:
mov ecx, 1
cmove edx, eax
call fcn.004418c0
add esp, 8
cmp ax, 1
jne 0x40b27c
mov ecx, dword [0x4f68c4]
test ecx, ecx
je 0x40b11f
cmp byte [ecx], 0
je 0x40b11f
mov esi, dword [edi]
call fcn.00445fd0
mov ebx, eax
test ebx, ebx
je 0x40b0f5
push ebx
push esi
call fcn.0048aba4
push ebx
mov esi, eax
call fcn.00488f53
add esp, 0xc
test esi, esi
je 0x40b275
cmp byte [edi + 4], 0
mov ecx, str.Couldnt_rename_directory:_Access_denied__or_dir_already_exists_
push 0
mov eax, str.Couldnt_rename_file:_Access_denied__or_file_already_exists_
cmovne eax, ecx
push eax
push str.System_message
push 0
call fcn.00441180
add esp, 0x10
pop edi
pop esi
pop ebx
add esp, 0x28
ret
push 0
push str.New_name_cant_be_empty_
push str.System_message
push 0
call fcn.00441180
add esp, 0x10
pop edi
pop esi
pop ebx
add esp, 0x28
ret
test al, al
je 0x40b17a
mov eax, dword [edi]
mov ecx, 0x4de9bc
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40b16d
test dx, dx
je 0x40b169
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40b16d
add eax, 4
add ecx, 4
test dx, dx
jne 0x40b147
xor eax, eax
jmp 0x40b172
sbb eax, eax
or eax, 1
test eax, eax
je 0x40b27c
mov ecx, dword [edi]
mov dl, 1
call fcn.004461b0
mov esi, eax
test esi, esi
je 0x40b27c
mov dl, byte [edi + 4]
mov ecx, esi
call fcn.0040a100
cmp byte [edi + 4], 0
mov eax, str.Delete_directory___s__
mov ecx, str.Delete_file___s__
push esi
cmovne ecx, eax
push ecx
push 0x4f67b0
call fcn.004010e0
add esp, 0xc
push esi
call fcn.00488f53
add esp, 4
push 0
push 0x4f67b0
push str.System_request
push 2
call fcn.00441180
add esp, 0x10
cmp ax, 1
jne 0x40b27c
cmp byte [edi + 4], 0
mov eax, dword [edi]
je 0x40b24b
mov dword [esp + 0x18], eax
xorps xmm0, xmm0
lea eax, [esp + 0x10]
mov dword [esp + 0x10], 0
mov ecx, 0x414
mov dword [esp + 0x1c], 0
push eax
movlpd qword [esp + 0x26], xmm0
mov dword [esp + 0x2e], 0
mov dword [esp + 0x18], 3
mov word [esp + 0x24], cx
call dword [sym.imp.SHELL32.dll_SHFileOperationW]
test eax, eax
je 0x40b275
push 0
push str.Couldnt_delete_folder:_Access_denied_
push str.System_message
push 0
call fcn.00441180
add esp, 0x10
pop edi
pop esi
pop ebx
add esp, 0x28
ret
push eax
call fcn.0048a9e0
add esp, 4
test eax, eax
je 0x40b275
push 0
push str.Couldnt_delete_file:_Access_denied_
push str.System_message
push 0
call fcn.00441180
add esp, 0x10
pop edi
pop esi
pop ebx
add esp, 0x28
ret
mov byte [0x54e4e0], 1
pop edi
pop esi
pop ebx
add esp, 0x28
ret
sub esp, 0x50c
push ebx
push ebp
push esi
push edi
mov ebp, ecx
push 0x4ddc24
push ebp
call fcn.004893d7
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x429531
push eax
push str.General_I_O_error_during_loading__Is_the_file_in_use_
push str.System_message
push eax
call fcn.00441180
add esp, 0x10
xor al, al
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x50c
ret
push ebx
push 4
lea eax, [esp + 0x1c]
push 1
push eax
call fcn.0048a645
add esp, 0x10
cmp eax, 4
je 0x42954f
mov eax, str.General_I_O_error_during_loading__Is_the_file_in_use_
jmp 0x4295c0
cmp word [esp + 0x14], 1
je 0x42955e
mov eax, str.Incompatible_format_version_
jmp 0x4295c0
mov dx, word [esp + 0x16]
mov eax, 0x100
cmp dx, ax
jbe 0x429574
mov edx, eax
mov word [esp + 0x16], dx
movzx eax, word [0x54e560]
movzx esi, word [eax*2 + 0x54e740]
movsx ecx, si
movzx eax, dx
cmp ecx, eax
jle 0x429590
movzx esi, dx
movsx esi, si
push ebx
push 1
lea eax, [esi + esi*4]
push eax
lea eax, [esp + 0x24]
push eax
call fcn.0048a645
add esp, 0x10
cmp eax, 1
jne 0x429548
mov ecx, dword [0x54e560]
call fcn.00427460
test al, al
jne 0x4295e5
mov eax, str.Not_enough_memory_
push 0
push eax
push str.System_message
push 0
call fcn.00441180
push ebx
call fcn.00489118
add esp, 0x14
xor al, al
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x50c
ret
call fcn.00402200
test esi, esi
jle 0x429646
movzx eax, byte [0x54e4b6]
lea edx, [esp + 0x18]
lea edi, [eax + eax*4]
nop dword [eax]
movzx eax, word [0x54e560]
mov ecx, dword [eax*4 + 0x54e940]
mov eax, dword [edx]
add ecx, edi
mov dword [ecx], eax
mov al, byte [edx + 4]
mov byte [ecx + 4], al
cmp byte [ecx], 0x61
jbe 0x429622
mov byte [ecx], 0
cmp byte [ecx + 1], 0x80
jbe 0x42962c
mov byte [ecx + 1], 0
cmp byte [ecx + 3], 0x23
jbe 0x429638
mov word [ecx + 3], 0
add edi, 0xa0
add edx, 5
sub esi, 1
jne 0x429600
call fcn.00436720
cmp byte [0x789f64], 0
je 0x42966e
mov eax, dword [0x78b4d8]
test eax, eax
je 0x429667
push eax
call dword [sym.imp.SDL2.dll_SDL_UnlockAudioDevice]
add esp, 4
mov byte [0x789f64], 0
push ebx
call fcn.00489118
add esp, 4
mov byte [0x54e642], 1
mov edx, ebp
mov byte [0x54e637], 1
mov cl, 4
call fcn.00409e40
pop edi
pop esi
pop ebp
mov byte [0x54ef62], 1
mov al, 1
mov byte [0x54e4e2], 1
pop ebx
add esp, 0x50c
ret
sub esp, 8
push ebx
push esi
push edi
mov ebx, ecx
push 0x4ddc24
push ebx
call fcn.004893d7
mov edi, eax
add esp, 8
test edi, edi
jne 0x4296e9
push eax
push str.General_I_O_error_during_loading__Is_the_file_in_use_
push str.System_message
push eax
call fcn.00441180
add esp, 0x10
xor al, al
pop edi
pop esi
pop ebx
add esp, 8
ret
mov ecx, dword [0x54e560]
call fcn.00427460
test al, al
jne 0x4296ff
mov eax, str.Not_enough_memory_
jmp 0x429770
push edi
push 4
lea eax, [esp + 0x14]
push 1
push eax
call fcn.0048a645
add esp, 0x10
cmp eax, 4
jne 0x42976b
cmp word [esp + 0xc], 1
je 0x429725
mov eax, str.Incompatible_format_version_
jmp 0x429770
mov eax, 0x100
cmp word [esp + 0xe], ax
jbe 0x429736
mov word [esp + 0xe], ax
call fcn.00402200
movzx eax, word [0x54e560]
push edi
push 1
mov ecx, dword [eax*4 + 0x54e940]
movzx eax, word [esp + 0x16]
lea eax, [eax + eax*4]
shl eax, 5
push eax
push ecx
call fcn.0048a645
add esp, 0x10
cmp eax, 1
je 0x429791
call fcn.00402270
mov eax, str.General_I_O_error_during_loading__Is_the_file_in_use_
push 0
push eax
push str.System_message
push 0
call fcn.00441180
push edi
call fcn.00489118
add esp, 0x14
xor al, al
pop edi
pop esi
pop ebx
add esp, 8
ret
mov dx, word [esp + 0xe]
xor eax, eax
xor esi, esi
cmp ax, dx
jae 0x4297f3
xor ecx, ecx
mov edx, 0x20
nop word [eax + eax]
movzx eax, word [0x54e560]
mov eax, dword [eax*4 + 0x54e940]
add eax, ecx
cmp byte [eax], 0x61
jbe 0x4297c8
mov byte [eax], 0
cmp byte [eax + 1], 0x80
jbe 0x4297d2
mov byte [eax + 1], 0x80
cmp byte [eax + 3], 0x23
jbe 0x4297de
mov word [eax + 3], 0
add ecx, 5
sub edx, 1
jne 0x4297b0
mov dx, word [esp + 0xe]
inc esi
movzx eax, dx
cmp esi, eax
jl 0x4297a1
movzx eax, word [0x54e560]
mov word [0x54fc1c], dx
mov word [eax*2 + 0x54e740], dx
cmp word [0x54fc1a], dx
jl 0x429838
mov eax, dword [esp + 0xe]
movzx ecx, word [0x54e55c]
dec eax
cmp byte [0x4edf32], 0
mov word [0x54fc1a], ax
movzx eax, ax
cmove ecx, eax
mov word [0x54e55c], cx
call fcn.00436720
cmp byte [0x789f64], 0
je 0x429860
mov eax, dword [0x78b4d8]
test eax, eax
je 0x429859
push eax
call dword [sym.imp.SDL2.dll_SDL_UnlockAudioDevice]
add esp, 4
mov byte [0x789f64], 0
push edi
call fcn.00489118
add esp, 4
mov byte [0x54e642], 1
mov edx, ebx
mov byte [0x54e637], 1
mov cl, 3
call fcn.00409e40
pop edi
pop esi
mov byte [0x54ef62], 1
mov al, 1
mov byte [0x54e4e2], 1
pop ebx
add esp, 8
ret