Function at 0x405bd0
Capabilities:
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x560
mov eax, dword [0x4710b0]
xor eax, esp
mov dword [esp + 0x55c], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, ecx
mov dword [esp + 0x14], eax
xor ecx, ecx
mov eax, ebx
mov edx, 4
mul edx
seto cl
push esi
mov dword [esp + 0x20], ebx
neg ecx
or ecx, eax
push ecx
call fcn.0040c4fb
mov dword [esp + 0xc], eax
xor ecx, ecx
add esp, 4
mov eax, ebx
mov edx, 4
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0040c4fb
mov esi, eax
xor ecx, ecx
add esp, 4
mov eax, ebx
mov edx, 4
mul edx
seto cl
mov dword [esp + 0x28], esi
neg ecx
or ecx, eax
push ecx
call fcn.0040c4fb
mov dword [esp + 0x18], eax
xor ecx, ecx
add esp, 4
mov eax, ebx
mov edx, 4
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0040c4fb
mov ecx, dword [ebp + 0x10]
add esp, 4
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], 0
test ecx, ecx
jle 0x4060f5
lea eax, [ebp + 0x10]
mov dword [esp + 0x34], ecx
jmp 0x405c97
mov eax, dword [esp + 0x3c]
add eax, 4
mov dword [esp + 0x3c], eax
mov eax, dword [eax]
push eax
mov dword [esp + 0x20], eax
lea eax, [esp + 0x35c]
push 0x468f28
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
mov ecx, dword [esp + 0x24]
mov ecx, dword [ecx + 0x50c]
mov edx, dword [ecx]
mov edx, dword [edx + 0x2c]
add esp, 0xc
lea eax, [esp + 0x358]
push eax
call edx
cmp ebx, 1
jle 0x405eff
mov dword [esp + 0x10], 0
test ebx, ebx
jle 0x4060cb
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 8]
sub ecx, eax
mov dword [esp + 0x38], ecx
mov ecx, dword [esp + 0xc]
sub ecx, eax
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x14]
sub ecx, eax
mov dword [esp + 0x2c], ecx
mov ebx, dword [esp + 0x20]
mov eax, dword [esp + 8]
add ebx, ebx
add ebx, ebx
push ebx
push 0
push eax
call fcn.004426d0
mov ecx, dword [esp + 0x34]
add esp, 0xc
push ebx
push 0
push ecx
call fcn.004426d0
mov edx, dword [esp + 0x20]
add esp, 0xc
push ebx
push 0
push edx
call fcn.004426d0
add esp, 0xc
push ebx
mov ebx, dword [esp + 0x10]
push 0
push ebx
call fcn.004426d0
mov eax, dword [esp + 0x24]
mov ecx, dword [eax + 0x504]
add esp, 0xc
push 0
call fcn.004124f9
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 8]
push ecx
mov ecx, dword [esp + 0x20]
push edx
push eax
mov edx, ebx
call fcn.004051c0
cmp dword [esi], 0
je 0x405ee0
mov ecx, dword [esp + 0x10]
push ecx
push edi
lea edx, [esp + 0x48]
push str..__s_02d.idx
push edx
call fcn.0043f2fe
mov edx, dword [ebp + 0xc]
mov ebx, dword [esp + 0x48]
mov ecx, dword [esp + 0x3c]
add esp, 0x10
push edx
lea eax, [esp + 0x44]
add ebx, esi
add ecx, esi
push eax
mov edx, ebx
call fcn.00405480
mov ecx, dword [esp + 0x10]
push ecx
push edi
lea edx, [esp + 0x48]
push str..__s_02d.pak
push edx
call fcn.0043f2fe
mov eax, dword [ebp + 0xc]
mov ecx, dword [esi]
mov edx, dword [esp + 0x40]
mov edx, dword [edx + esi]
add esp, 0x10
push eax
mov eax, dword [esp + 0x30]
push ecx
mov ecx, dword [esp + 0x20]
add eax, esi
push eax
lea eax, [esp + 0x4c]
push eax
push ecx
mov ecx, dword [esp + 0x30]
call fcn.004058e0
mov eax, dword [esp + 0x10]
push eax
push edi
lea ecx, [esp + 0x48]
push str..__s_02d.idx.___
push ecx
call fcn.0043f2fe
mov edx, dword [ebp + 0xc]
mov ecx, dword [ebx]
add esp, 0x10
push edx
lea eax, [esp + 0x44]
push eax
mov eax, dword [esp + 0x34]
mov edx, dword [eax + esi]
call fcn.004055c0
mov eax, dword [esp + 0x30]
mov ecx, dword [eax + esi]
mov eax, dword [esi]
test eax, eax
jle 0x405e74
lea ebx, [ecx + 4]
mov dword [esp + 0x24], eax
mov ecx, dword [esp + 0x1c]
push ebx
push ecx
lea edx, [esp + 0x258]
push 0x468f20
push edx
call fcn.0043f2fe
add esp, 0x10
lea eax, [esp + 0x250]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
add ebx, 0x1c
dec dword [esp + 0x24]
jne 0x405e42
mov ebx, dword [esp + 0x10]
push ebx
push edi
lea ecx, [esp + 0x48]
push str._s_02d.idx
push ecx
call fcn.0043f2fe
push ebx
push edi
lea edx, [esp + 0x160]
push str._s_02d.idx.___
push edx
call fcn.0043f2fe
add esp, 0x20
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [esp + 0x40]
push ecx
lea edx, [esp + 0x14c]
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileA]
mov eax, dword [esp + 0x30]
mov ecx, dword [eax + esi]
push ecx
call fcn.0043e14e
mov eax, dword [esp + 0x30]
mov eax, dword [eax + esi]
add esp, 4
push eax
call fcn.0043e14e
add esp, 4
jmp 0x405ee4
mov ebx, dword [esp + 0x10]
inc ebx
add esi, 4
mov dword [esp + 0x10], ebx
cmp ebx, dword [esp + 0x20]
jl 0x405d0f
mov esi, dword [esp + 0x28]
jmp 0x4060c7
mov ecx, dword [esp + 8]
lea eax, [ebx*4]
push eax
push 0
push ecx
call fcn.004426d0
add esp, 0xc
lea eax, [ebx*4]
push eax
push 0
push esi
call fcn.004426d0
mov edx, dword [esp + 0x20]
add esp, 0xc
lea eax, [ebx*4]
push eax
push 0
push edx
call fcn.004426d0
add esp, 0xc
lea eax, [ebx*4]
push eax
mov eax, dword [esp + 0x10]
push 0
push eax
call fcn.004426d0
mov ecx, dword [esp + 0x24]
mov ecx, dword [ecx + 0x504]
add esp, 0xc
push 0
call fcn.004124f9
mov edx, dword [esp + 8]
mov ecx, dword [esp + 0x1c]
push ebx
push esi
push edx
mov edx, dword [esp + 0x18]
call fcn.004051c0
cmp dword [esi], 0
je 0x4060cb
push edi
lea eax, [esp + 0x44]
push str._s.idx
push eax
call fcn.0043f2fe
mov ebx, dword [ebp + 0xc]
mov edx, dword [esp + 0x14]
add esp, 0xc
push ebx
lea ecx, [esp + 0x44]
push ecx
mov ecx, dword [esp + 0x1c]
call fcn.00405480
push edi
lea edx, [esp + 0x44]
push str._s.pak
push edx
call fcn.0043f2fe
mov eax, dword [esi]
mov ecx, dword [esp + 0x20]
add esp, 0xc
push ebx
mov ebx, dword [esp + 0xc]
push eax
mov eax, dword [esp + 0x20]
push ecx
mov ecx, dword [esp + 0x18]
lea edx, [esp + 0x4c]
push edx
mov edx, dword [esp + 0x20]
mov edx, dword [ecx + edx*4]
mov ecx, dword [esp + 0x2c]
push eax
call fcn.004058e0
push edi
lea eax, [esp + 0x44]
push str._s.idx.___
push eax
call fcn.0043f2fe
mov ecx, dword [ebp + 0xc]
add esp, 0xc
push ecx
lea edx, [esp + 0x44]
push edx
mov edx, dword [esp + 0x1c]
mov edx, dword [edx]
mov eax, ebx
mov ecx, dword [eax]
call fcn.004055c0
mov eax, dword [esp + 0xc]
mov ecx, dword [eax]
mov eax, dword [esi]
test eax, eax
jle 0x406062
lea ebx, [ecx + 4]
mov dword [esp + 0x24], eax
lea ebx, [ebx]
mov ecx, dword [esp + 0x1c]
push ebx
push ecx
lea edx, [esp + 0x258]
push 0x468f20
push edx
call fcn.0043f2fe
add esp, 0x10
lea eax, [esp + 0x250]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
add ebx, 0x1c
dec dword [esp + 0x24]
jne 0x406030
push edi
lea ecx, [esp + 0x44]
push str._s.idx
push ecx
call fcn.0043f2fe
add esp, 0xc
push edi
lea edx, [esp + 0x14c]
push str._s.idx.___
push edx
call fcn.0043f2fe
add esp, 0xc
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [esp + 0x40]
push ecx
lea edx, [esp + 0x14c]
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileA]
mov eax, dword [esp + 0xc]
mov ecx, dword [eax]
push ecx
call fcn.0043e14e
mov edx, dword [esp + 0x18]
mov eax, dword [edx]
add esp, 4
push eax
call fcn.0043e14e
add esp, 4
mov ebx, dword [esp + 0x20]
mov ecx, dword [esp + 0x18]
mov ecx, dword [ecx + 0x508]
call fcn.004124f2
mov edx, dword [esp + 0x18]
mov ecx, dword [edx + 0x508]
inc eax
push eax
call fcn.004124f9
dec dword [esp + 0x34]
jne 0x405c93
mov eax, dword [esp + 0x14]
test eax, eax
je 0x406106
push eax
call fcn.0043db99
add esp, 4
mov eax, dword [esp + 0xc]
test eax, eax
je 0x406117
push eax
call fcn.0043db99
add esp, 4
mov eax, dword [esp + 8]
test eax, eax
je 0x406128
push eax
call fcn.0043dc24
add esp, 4
test esi, esi
je 0x406135
push esi
call fcn.0043dc24
add esp, 4
mov ecx, dword [esp + 0x564]
pop esi
pop ebx
xor ecx, esp
call fcn.0043db8a
mov esp, ebp
pop ebp
ret