Function at 0x404c80
Capabilities:
Check if file exists
Create directory
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x417776
mov eax, dword fs:[0]
push eax
sub esp, 0x180
mov eax, dword [0x41fea0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x180]
push eax
mov dword [ebp - 4], 0
mov dword [ebp - 0x164], ebx
mov dword [ebp - 0x18c], ebx
mov dword [ebp - 0x178], 0
call fcn.00401940
push str.Language
push eax
lea eax, [ebp - 0x170]
mov dword [ebp - 4], 1
push eax
call fcn.00401380
add esp, 0x10
mov edx, dword [ebp - 0x180]
or edi, 0xffffffff
add edx, 0xfffffff0
mov byte [ebp - 4], 3
mov eax, edi
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x404d1c
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
call fcn.00402b80
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x404d38
push 0x80004005
call fcn.00401670
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebx], eax
push dword [ebp - 0x170]
mov dword [ebp - 0x178], 1
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x404d9f
push eax
push dword [ebp - 0x170]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x40541e
push dword [0x4211d8]
lea eax, [ebp - 0x164]
push eax
call fcn.00401a70
add esp, 8
push eax
mov ecx, ebx
mov byte [ebp - 4], 4
call fcn.00401210
mov edx, dword [ebp - 0x164]
jmp 0x405401
lea eax, [ebp - 0x184]
push eax
call fcn.00401940
push str.Settings.ini
push eax
lea eax, [ebp - 0x15c]
mov byte [ebp - 4], 5
push eax
call fcn.00401380
add esp, 0x10
mov edx, dword [ebp - 0x184]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 7
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x404de7
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push ecx
mov ecx, esp
mov dword [ebp - 0x154], esp
push str.Language
call fcn.00401100
push ecx
mov ecx, esp
mov dword [ebp - 0x158], esp
push str.General_Settings
mov byte [ebp - 4], 8
call fcn.00401100
mov eax, dword [ebp - 0x15c]
push ecx
add eax, 0xfffffff0
mov byte [ebp - 4], 9
mov esi, esp
push eax
call fcn.004016a0
add eax, 0x10
add esp, 4
mov dword [esi], eax
lea eax, [ebp - 0x160]
mov byte [ebp - 4], 7
push eax
call fcn.00402380
push 0x418268
push dword [ebp - 0x160]
mov byte [ebp - 4], 0xa
call fcn.0040704d
add esp, 0x18
test eax, eax
sete al
test al, al
je 0x4051b3
lea eax, [ebp - 0x158]
push eax
call fcn.00401c40
add esp, 4
push eax
lea ecx, [ebp - 0x160]
mov byte [ebp - 4], 0xb
call fcn.00401210
mov edx, dword [ebp - 0x158]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x404ea5
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push 0x418268
push dword [ebp - 0x160]
call fcn.0040704d
add esp, 8
test eax, eax
sete al
test al, al
je 0x404ede
push 0xb
push 0x4182bc
lea ecx, [ebp - 0x160]
call fcn.00402fa0
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
jmp 0x404f7f
push 0x418604
lea eax, [ebp - 0x170]
push eax
lea eax, [ebp - 0x154]
push eax
call fcn.00401380
lea ecx, [ebp - 0x160]
mov byte [ebp - 4], 0xc
push ecx
push eax
lea eax, [ebp - 0x158]
push eax
call fcn.004012c0
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
add esp, 0x18
push dword [eax]
call esi
mov edx, dword [ebp - 0x158]
test eax, eax
mov ecx, edi
sete byte [ebp - 0x169]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x404f43
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x154]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x404f66
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
cmp byte [ebp - 0x169], 0
je 0x404f7f
push 0x4182bc
lea ecx, [ebp - 0x160]
call fcn.00401280
push 0x418604
lea eax, [ebp - 0x170]
push eax
lea eax, [ebp - 0x158]
push eax
call fcn.00401380
lea ecx, [ebp - 0x160]
mov byte [ebp - 4], 0xd
push ecx
push eax
lea eax, [ebp - 0x154]
push eax
call fcn.004012c0
add esp, 0x18
push eax
mov ecx, ebx
mov byte [ebp - 4], 0xe
call fcn.00401210
mov edx, dword [ebp - 0x154]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xd
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x404fe1
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x158]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405004
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebx]
call esi
test eax, eax
jne 0x405050
push dword [0x4211d8]
lea eax, [ebp - 0x154]
push eax
call fcn.00401a70
add esp, 8
push eax
mov ecx, ebx
mov byte [ebp - 4], 0xf
call fcn.00401210
mov edx, dword [ebp - 0x154]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405050
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push ecx
mov ecx, esp
mov dword [ebp - 0x154], esp
push str.Language
call fcn.00401100
push ecx
mov ecx, esp
mov dword [ebp - 0x158], esp
push str.General_Settings
mov byte [ebp - 4], 0x10
call fcn.00401100
mov eax, dword [ebx]
push ecx
sub eax, 0x10
mov byte [ebp - 4], 0x11
mov esi, esp
push eax
call fcn.004016a0
add eax, 0x10
add esp, 4
mov dword [esi], eax
lea eax, [ebp - 0x168]
mov byte [ebp - 4], 0xa
push eax
call fcn.00402380
lea eax, [ebp - 0x154]
mov byte [ebp - 4], 0x12
push eax
call fcn.00401940
push str.Settings.ini
push eax
lea eax, [ebp - 0x164]
mov byte [ebp - 4], 0x13
push eax
call fcn.00401380
add esp, 0x20
mov edx, dword [ebp - 0x154]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0x15
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4050f0
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x168]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x174], esp
mov esi, esp
push eax
call fcn.004016a0
add eax, 0x10
mov dword [esi], eax
mov ecx, esp
mov dword [ebp - 0x158], esp
push str.Language
mov byte [ebp - 4], 0x16
call fcn.00401100
push ecx
mov ecx, esp
mov dword [ebp - 0x17c], esp
push str.General_Settings
mov byte [ebp - 4], 0x17
call fcn.00401100
mov eax, dword [ebp - 0x164]
push ecx
add eax, 0xfffffff0
mov byte [ebp - 4], 0x18
mov esi, esp
push eax
call fcn.004016a0
add esp, 4
add eax, 0x10
mov dword [esi], eax
mov byte [ebp - 4], 0x15
call fcn.00402900
mov edx, dword [ebp - 0x164]
add esp, 0x10
add edx, 0xfffffff0
mov byte [ebp - 4], 0x12
mov ecx, edi
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405187
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x168]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4053d8
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x4053d8
push 0x418604
lea eax, [ebp - 0x170]
push eax
lea eax, [ebp - 0x158]
push eax
call fcn.00401380
push str..ini
push eax
lea eax, [ebp - 0x154]
mov byte [ebp - 4], 0x19
push eax
call fcn.00401380
add esp, 0x18
push eax
lea ecx, [ebp - 0x15c]
mov byte [ebp - 4], 0x1a
call fcn.00401210
mov edx, dword [ebp - 0x154]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0x19
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405217
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x158]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40523a
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x15c]
mov edx, 1
sub edx, dword [eax - 4]
mov ecx, dword [eax - 8]
or ecx, edx
jge 0x405262
push 0
lea ecx, [ebp - 0x15c]
call fcn.00402dc0
mov eax, dword [ebp - 0x15c]
lea ecx, [ebp - 0x150]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4053d2
jmp 0x405280
push 0x418604
lea eax, [ebp - 0x170]
push eax
lea eax, [ebp - 0x158]
push eax
call fcn.00401380
lea ecx, [ebp - 0x124]
mov byte [ebp - 4], 0x1b
push ecx
push eax
lea eax, [ebp - 0x154]
push eax
call fcn.00401380
add esp, 0x18
push eax
lea ecx, [ebp - 0x15c]
mov byte [ebp - 4], 0x1c
call fcn.00401210
mov edx, dword [ebp - 0x154]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0x1b
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4052e6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x158]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405309
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push ecx
mov ecx, esp
mov dword [ebp - 0x188], esp
push str.Language
call fcn.00401100
push ecx
mov ecx, esp
mov dword [ebp - 0x17c], esp
push str.General_Settings
mov byte [ebp - 4], 0x1d
call fcn.00401100
mov eax, dword [ebp - 0x15c]
push ecx
add eax, 0xfffffff0
mov byte [ebp - 4], 0x1e
mov esi, esp
push eax
call fcn.004016a0
add eax, 0x10
add esp, 4
mov dword [esi], eax
lea eax, [ebp - 0x168]
mov byte [ebp - 4], 0xa
push eax
call fcn.00402380
add esp, 0x10
mov eax, dword [ebp - 0x160]
xor ecx, ecx
test eax, eax
mov byte [ebp - 4], 0x1f
setne cl
test ecx, ecx
je 0x404d2e
push eax
push dword [ebp - 0x168]
call fcn.0040704d
add esp, 8
test eax, eax
sete al
test al, al
jne 0x40545d
mov edx, dword [ebp - 0x168]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 0xa
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4053bc
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [ebp - 0x150]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x405280
mov ebx, dword [ebp - 0x164]
mov edx, dword [ebp - 0x160]
mov ecx, edi
add edx, 0xfffffff0
mov byte [ebp - 4], 7
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4053fb
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x15c]
add edx, 0xfffffff0
mov byte [ebp - 4], 3
mov ecx, edi
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40541e
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, dword [ebp - 0x170]
add esi, 0xfffffff0
mov byte [ebp - 4], 0
lea eax, [esi + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x40543f
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00407792
mov esp, ebp
pop ebp
ret
mov ebx, dword [ebp - 0x164]
lea eax, [ebp - 0x15c]
push eax
mov ecx, ebx
call fcn.00401210
jmp 0x405187