Function at 0x407f20
Capabilities:
Delete file
Print debug messages

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x452e9e
mov eax, dword fs:[0]
push eax
sub esp, 0x468
mov eax, dword [0x46a860]
xor eax, esp
mov dword [esp + 0x460], eax
push ebx
push esi
push edi
mov eax, dword [0x46a860]
xor eax, esp
push eax
lea eax, [esp + 0x478]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [esp + 0x18], 0
mov eax, dword [ebx + 0x2c]
test eax, eax
mov dword [esp + 0x20], ebx
je 0x407f7c
mov eax, dword [eax]
call fcn.00405080
cmp dword [ebx + 0x28], 0
je 0x408693
mov eax, dword [ebx + 0x20]
push 0x2000
push 4
push eax
call fcn.00414eec
push 0xffff
mov esi, eax
mov eax, dword [ebx + 0x18]
push 4
push eax
mov dword [esp + 0x5c], esi
call fcn.00414eec
push 0xffff
mov edi, eax
mov eax, dword [ebx + 0x1c]
push 4
push eax
mov dword [esp + 0x64], edi
call fcn.00414eec
push 0xffff
mov dword [esp + 0x28], eax
mov eax, dword [ebx + 0x24]
push 4
push eax
call fcn.00414eec
cmp esi, 0xffffffff
mov dword [esp + 0x34], eax
je 0x40868f
cmp edi, 0xffffffff
je 0x40868f
mov ecx, dword [esp + 0x24]
cmp ecx, 0xffffffff
je 0x40868f
cmp eax, 0xffffffff
je 0x40868f
test esi, esi
je 0x40868f
test edi, edi
je 0x40868f
test ecx, ecx
je 0x40868f
test eax, eax
je 0x40868f
cmp dword [ebx + 0x38], 2
jne 0x408576
mov dword [esp + 0x2c], 0
mov eax, dword [ebx + 0x34]
push eax
lea edi, [esp + 0x2c]
mov dword [esp + 0x2c], 0
call fcn.00404f10
cmp dword [esp + 0x28], 0
je 0x408576
push 0x200
lea eax, [esp + 0x70]
push 0
push eax
call fcn.004376d0
add esp, 0xc
push 0x200
lea ecx, [esp + 0x270]
push 0
push ecx
call fcn.004376d0
mov edx, dword [ebx + 0xc]
add esp, 0xc
push edx
lea eax, [esp + 0x70]
push 0x200
push eax
call fcn.004366a7
mov esi, dword [esp + 0x34]
mov ecx, dword [esi + 0x14]
add esp, 0xc
push ecx
lea edx, [esp + 0x70]
push 0x200
push edx
call fcn.00436be9
mov esi, dword [esi + 0x10]
add esp, 0xc
mov edi, str.Launcher.exe
mov ecx, 0xd
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x4080d9
push str..new
lea ecx, [esp + 0x70]
push 0x200
push ecx
call fcn.00436be9
add esp, 0xc
mov edx, dword [ebx + 0x10]
push edx
lea eax, [esp + 0x270]
push 0x200
push eax
call fcn.004366a7
mov esi, dword [esp + 0x34]
mov ecx, dword [esi + 0x14]
add esp, 0xc
push ecx
lea edx, [esp + 0x270]
push 0x200
push edx
call fcn.00436be9
mov eax, dword [esi + 0x14]
add esp, 0xc
push eax
lea ecx, [esp + 0x20]
call fcn.004029f0
lea edi, [esp + 0x1c]
mov dword [esp + 0x480], 0
call fcn.00408970
mov ebx, edi
call fcn.004088c0
mov ecx, edi
push ecx
call fcn.00408810
cmp dword [esi], 1
je 0x408521
push 4
lea edx, [esp + 0x48]
push edx
mov ecx, edi
call fcn.004045f0
push str..map
push eax
call fcn.004089d0
add esp, 8
lea ecx, [esp + 0x44]
mov bl, al
call fcn.00402ae0
xor edi, edi
test bl, bl
jne 0x4084e0
push 4
lea eax, [esp + 0x68]
push eax
lea ecx, [esp + 0x24]
call fcn.004045f0
mov byte [esp + 0x480], 1
mov ebx, dword [esp + 0x18]
push str..dds
or ebx, 1
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
jne 0x4081dc
push 4
lea ecx, [esp + 0x64]
push ecx
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..tga
or ebx, 2
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
mov byte [esp + 0x17], 0
je 0x4081e1
mov byte [esp + 0x17], 1
test bl, 2
je 0x4081f6
and ebx, 0xfffffffd
lea ecx, [esp + 0x60]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
test bl, 1
mov dword [esp + 0x480], edi
je 0x408212
and ebx, 0xfffffffe
lea ecx, [esp + 0x64]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
cmp byte [esp + 0x17], 0
jne 0x4084e0
push 5
lea edx, [esp + 0x6c]
push edx
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..pwm3
mov byte [esp + 0x484], 2
or ebx, 4
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
jne 0x4082e8
push 4
lea eax, [esp + 0x50]
push eax
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..m4f
mov dword [esp + 0x484], 3
or ebx, 8
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
jne 0x4082e8
push 9
lea ecx, [esp + 0x60]
push ecx
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..pwm3.cfg
mov dword [esp + 0x484], 4
or ebx, 0x10
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
jne 0x4082e8
push 4
lea edx, [esp + 0x3c]
push edx
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..trk
or ebx, 0x20
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
mov byte [esp + 0x17], 0
je 0x4082ed
mov byte [esp + 0x17], 1
test bl, 0x20
je 0x408302
and ebx, 0xffffffdf
lea ecx, [esp + 0x38]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
test bl, 0x10
je 0x408317
and ebx, 0xffffffef
lea ecx, [esp + 0x5c]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
test bl, 8
je 0x40832c
and ebx, 0xfffffff7
lea ecx, [esp + 0x4c]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
test bl, 4
mov dword [esp + 0x480], edi
je 0x408348
and ebx, 0xfffffffb
lea ecx, [esp + 0x68]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
cmp byte [esp + 0x17], 0
jne 0x4084e0
push 7
lea eax, [esp + 0x4c]
push eax
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..string
mov byte [esp + 0x484], 5
or ebx, 0x40
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
jne 0x408427
push 5
lea ecx, [esp + 0x44]
push ecx
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..task
mov dword [esp + 0x484], 6
or ebx, 0x80
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
jne 0x408427
push 4
lea edx, [esp + 0x40]
push edx
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..str
mov dword [esp + 0x484], 7
or ebx, 0x100
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
jne 0x408427
push 4
lea eax, [esp + 0x58]
push eax
lea ecx, [esp + 0x24]
call fcn.004045f0
push str..tas
or ebx, 0x200
push eax
mov dword [esp + 0x20], ebx
call fcn.004089d0
add esp, 8
test al, al
mov byte [esp + 0x17], 0
je 0x40842c
mov byte [esp + 0x17], 1
test ebx, 0x200
je 0x408447
and ebx, 0xfffffdff
lea ecx, [esp + 0x54]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
test ebx, 0x100
je 0x408462
and ebx, 0xfffffeff
lea ecx, [esp + 0x3c]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
test bl, bl
jns 0x408479
and ebx, 0xffffff7f
lea ecx, [esp + 0x40]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
test bl, 0x40
mov dword [esp + 0x480], edi
je 0x408495
and ebx, 0xffffffbf
lea ecx, [esp + 0x48]
mov dword [esp + 0x18], ebx
call fcn.00402ae0
cmp byte [esp + 0x17], 0
jne 0x4084e0
mov esi, dword [esi + 0x18]
lea ecx, [esp + 0x6c]
push ecx
call fcn.0040e470
add esp, 4
mov ecx, eax
call fcn.0040e390
mov cl, byte [eax]
cmp cl, byte [esi]
jne 0x4084d3
test cl, cl
je 0x4084cf
mov cl, byte [eax + 1]
cmp cl, byte [esi + 1]
jne 0x4084d3
add eax, 2
add esi, 2
test cl, cl
jne 0x4084b3
xor eax, eax
jmp 0x4084d8
sbb eax, eax
sbb eax, 0xffffffff
cmp eax, edi
jne 0x40867b
mov eax, dword [esp + 0x2c]
mov esi, dword [esp + 0x20]
add eax, 0x12c
xor edx, edx
mov dword [esp + 0x2c], eax
div dword [esi + 0x58]
lea edx, [esp + 0x26c]
push edx
add eax, 0x2bc
mov dword [esi + 0x54], eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileA]
mov eax, dword [esi + 0x54]
mov ecx, dword [esi + 8]
mov edx, dword [esi + 4]
push eax
push edi
push ecx
push edx
call dword [sym.imp.USER32.dll_SendMessageA]
jmp 0x408554
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x20]
add eax, 0x12c
mov dword [esp + 0x2c], eax
xor edx, edx
div dword [ecx + 0x58]
add eax, 0x2bc
push eax
mov dword [ecx + 0x54], eax
mov eax, dword [ecx + 8]
mov ecx, dword [ecx + 4]
push 0
push eax
push ecx
call dword [sym.imp.USER32.dll_SendMessageA]
mov esi, dword [esp + 0x20]
lea ecx, [esp + 0x1c]
mov dword [esp + 0x480], 0xffffffff
call fcn.00402ae0
cmp dword [esi + 0x38], 2
mov ebx, dword [esp + 0x20]
je 0x408034
mov eax, dword [esp + 0x50]
push 0
push eax
call fcn.00414f0e
mov ecx, dword [esp + 0x58]
push 0
push ecx
call fcn.00414f0e
mov edx, dword [esp + 0x24]
push 0
push edx
call fcn.00414f0e
mov eax, dword [esp + 0x34]
push 0
push eax
call fcn.00414f0e
mov edx, dword [ebx + 0xc]
push edx
lea ecx, [esp + 0x34]
call fcn.004029f0
push 0x1c
push str.LauncherCfgNewUpdateCfg.xml
lea ecx, [esp + 0x38]
mov dword [esp + 0x488], 8
call fcn.00404930
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x40], esp
lea edi, [ebx + 0x5c]
push eax
call fcn.00405a10
mov ecx, dword [esp + 0x3c]
push ecx
call fcn.004063d0
lea edi, [ebx + 0x3c]
push edi
call dword [sym.imp.KERNEL32.DLL_EnterCriticalSection]
push edi
mov dword [ebx + 0x38], 4
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
push edi
call dword [sym.imp.KERNEL32.DLL_DeleteCriticalSection]
mov edx, dword [ebx + 8]
mov eax, dword [ebx + 4]
push 0x3e9
push 0
push edx
push eax
mov dword [ebx + 0x54], 0x3e9
call dword [sym.imp.USER32.dll_SendMessageA]
mov dword [esp + 0x480], 0xffffffff
mov eax, dword [esp + 0x30]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x408650
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
mov ecx, dword [esp + 0x478]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x460]
xor ecx, esp
call fcn.00435287
mov esp, ebp
pop ebp
ret 4
lea edx, [esp + 0x6c]
push edx
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringA]
lea ecx, [esp + 0x1c]
call fcn.00402ae0
xor eax, eax
jmp 0x408655
cmp dword [ebx + 0x38], 2
jne 0x4085a6
xor esi, esi
nop
mov eax, dword [ebx + 0x34]
push eax
lea edi, [esp + 0x28]
mov dword [esp + 0x28], 0
call fcn.00404f10
mov edi, dword [esp + 0x24]
test edi, edi
je 0x4085a6
push 0x200
lea ecx, [esp + 0x70]
push 0
push ecx
call fcn.004376d0
add esp, 0xc
push 0x200
lea edx, [esp + 0x270]
push 0
push edx
call fcn.004376d0
mov eax, dword [ebx + 0x10]
add esp, 0xc
push eax
lea ecx, [esp + 0x70]
push 0x200
push ecx
call fcn.004366a7
mov edx, dword [edi + 0x14]
add esp, 0xc
push edx
lea eax, [esp + 0x70]
push 0x200
push eax
call fcn.00436be9
mov ecx, dword [ebx + 0x10]
add esp, 0xc
push ecx
lea edx, [esp + 0x270]
push 0x200
push edx
call fcn.004366a7
mov eax, dword [edi + 0x14]
add esp, 0xc
push eax
lea ecx, [esp + 0x270]
push 0x200
push ecx
call fcn.00436be9
add esp, 0xc
cmp dword [edi], 1
je 0x4087c2
mov edi, dword [edi + 0x18]
lea edx, [esp + 0x6c]
push edx
call fcn.0040e470
add esp, 4
mov ecx, eax
call fcn.0040e390
mov cl, byte [eax]
cmp cl, byte [edi]
jne 0x408786
test cl, cl
je 0x408782
mov cl, byte [eax + 1]
cmp cl, byte [edi + 1]
jne 0x408786
add eax, 2
add edi, 2
test cl, cl
jne 0x408766
xor eax, eax
jmp 0x40878b
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x4087f7
add esi, 0x12c
xor edx, edx
mov eax, esi
div dword [ebx + 0x58]
add eax, 0x2bc
mov dword [ebx + 0x54], eax
lea eax, [esp + 0x26c]
push eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileA]
mov ecx, dword [ebx + 0x54]
mov edx, dword [ebx + 8]
mov eax, dword [ebx + 4]
push ecx
push 0
push edx
push eax
jmp 0x4087e2
add esi, 0x12c
xor edx, edx
mov eax, esi
div dword [ebx + 0x58]
mov ecx, dword [ebx + 8]
mov edx, dword [ebx + 4]
add eax, 0x2bc
push eax
push 0
push ecx
mov dword [ebx + 0x54], eax
push edx
call dword [sym.imp.USER32.dll_SendMessageA]
cmp dword [ebx + 0x38], 2
je 0x4086a0
jmp 0x4085a6
mov eax, dword [ebx + 8]
mov ecx, dword [ebx + 4]
push 0
push 0
push eax
push ecx
call dword [sym.imp.USER32.dll_SendMessageA]
xor eax, eax
jmp 0x408655