Function at 0x412e9e
Capabilities:
Delete file
Extract resource via kernel32 functions
Get common file path
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x39c]
sub esp, 0x41c
mov eax, dword [0x81c5a8]
xor eax, ebp
mov dword [ebp + 0x398], eax
push ebx
push esi
mov eax, ecx
push edi
lea ecx, [eax + 0xa10]
push ecx
mov dword [ebp - 0x6c], eax
add eax, 0x610
push eax
push 0x720f7c
mov dword [ebp - 0x74], eax
mov esi, 0x200
lea eax, [ebp + 0x198]
push esi
push eax
mov dword [ebp - 0x78], ecx
call fcn.00403c35
mov edi, dword [sym.imp.KERNEL32.dll_CreateFileA]
add esp, 0x14
xor ebx, ebx
push ebx
push 2
push 3
push ebx
push ebx
push SysReAllocStringLen
lea eax, [ebp + 0x198]
push eax
call edi
cmp eax, 0xffffffff
je 0x412f1e
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x4130c1
mov eax, dword [ebp - 0x6c]
push dword [eax + 0xd80]
call fcn.00412e93
pop ecx
test eax, eax
jne 0x412f3b
mov eax, 0x5007
jmp 0x4130c1
mov eax, dword [ebp - 0x6c]
add eax, 0x810
cmp byte [eax], bl
je 0x413070
push eax
lea eax, [ebp - 0x68]
push esi
push eax
call fcn.0067eece
add esp, 0xc
lea eax, [ebp - 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov dword [ebp - 0x70], eax
cmp eax, ebx
je 0x413084
mov ecx, dword [ebp - 0x6c]
movzx ecx, word [ecx + 0xd80]
push 0xa
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov dword [ebp - 0x6c], eax
cmp eax, ebx
je 0x413084
push eax
push dword [ebp - 0x70]
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, ebx
je 0x413084
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push dword [ebp - 0x6c]
mov dword [ebp - 0x7c], eax
push dword [ebp - 0x70]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebp - 0x70], eax
cmp eax, ebx
je 0x413084
push ebx
push 2
push 2
push ebx
push ebx
push 0xc0000000
lea eax, [ebp + 0x198]
push eax
call edi
mov dword [ebp - 0x6c], eax
cmp eax, 0xffffffff
jne 0x413096
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea eax, [ebp + 0x198]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push ebx
push 2
push 2
push ebx
push ebx
push 0xc0000000
lea eax, [ebp + 0x198]
push eax
call edi
mov dword [ebp - 0x6c], eax
cmp eax, 0xffffffff
jne 0x413096
push esi
lea eax, [ebp + 0x198]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push 0x768238
lea eax, [ebp + 0x198]
push esi
push eax
call fcn.00403c7f
push dword [ebp - 0x78]
lea eax, [ebp + 0x198]
push esi
push eax
call fcn.00403c7f
add esp, 0x18
push ebx
push 2
push 2
push ebx
push ebx
push 0xc0000000
lea eax, [ebp + 0x198]
push eax
call edi
mov dword [ebp - 0x6c], eax
cmp eax, 0xffffffff
jne 0x41308c
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x412f17
push esi
lea eax, [ebp - 0x68]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x412f59
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4130c1
push esi
push dword [ebp - 0x74]
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push ebx
lea eax, [ebp - 0x80]
push eax
push dword [ebp - 0x70]
push dword [ebp - 0x7c]
push dword [ebp - 0x6c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4130b6
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
push dword [ebp - 0x6c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
mov ecx, dword [ebp + 0x398]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00647fba
add ebp, 0x39c
leave
ret