Function at 0x4146a0
Capabilities:
Delete file
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x218
mov eax, dword [0x4f2500]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [0x4f36ec]
mov edx, dword [eax + 0xc]
push esi
push edi
mov ecx, 0x4f36ec
call edx
add eax, 0x10
mov dword [ebp - 0x214], eax
lea eax, [ebx + 0x208]
push eax
push str._scommon.7z
lea edi, [ebp - 0x214]
call fcn.00404650
add esp, 8
lea esi, [ebx + 0x1860]
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
test edi, edi
je 0x414735
push str.UnPackEx2
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x414721
mov edx, dword [ebp - 0x214]
lea ecx, [ebx + 0x1658]
push ecx
push edx
lea ecx, [ebx + 0x1c70]
push ecx
call eax
mov edx, dword [ebp - 0x214]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push edi
push str.hDll__0x_x_wClient7zFile___s_Error___d
push 0x5b5
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
mov eax, dword [0x4f6d14]
push str.ModuleAid.cpp
push 1
push eax
mov eax, str.CModuleAidManger::Un7zZip
call fcn.00403090
add esp, 0x24
xor ecx, ecx
push 0x206
push ecx
lea edx, [ebp - 0x20e]
push edx
mov word [ebp - 0x210], cx
call fcn.004276b0
add esp, 0xc
push 0x104
lea eax, [ebp - 0x210]
push eax
push str._localappdata__GamePPSdk_Common
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
lea ecx, [ebp - 0x210]
push ecx
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
mov edx, dword [0x4f36ec]
mov eax, dword [edx + 0xc]
mov ecx, 0x4f36ec
call eax
add eax, 0x10
mov dword [ebp - 0x218], eax
lea eax, [ebx + 0x208]
push eax
push str._scommonSdk.7z
lea edi, [ebp - 0x218]
call fcn.00404650
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
test edi, edi
je 0x414828
push str.UnPackEx2
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x414814
mov edx, dword [ebp - 0x218]
lea ecx, [ebx + 0x1658]
push ecx
push edx
lea ecx, [ebp - 0x210]
push ecx
call eax
mov edx, dword [ebp - 0x218]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push edi
push str.hDll__0x_x_wClient7zFile___s_Error___d
push 0x5b5
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
mov eax, dword [0x4f6d14]
push str.ModuleAid.cpp
push 1
push eax
mov eax, str.CModuleAidManger::Un7zZip
call fcn.00403090
add esp, 0x24
push ebx
call fcn.00416a60
mov eax, dword [ebp - 0x218]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x414884
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x214]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4148a6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0042292e
mov esp, ebp
pop ebp
ret