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

Disassembly:
sub esp, 0x218
mov eax, dword [0x424310]
xor eax, esp
mov dword [esp + 0x214], eax
movzx eax, word [esp + 0x21c]
push ebx
push ebp
mov ebp, dword [esp + 0x228]
push esi
push edi
push 0xa
push eax
push 0
mov dword [esp + 0x20], ebp
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push esi
push 0
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push edi
mov dword [esp + 0x1c], eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push ebp
lea ecx, [esp + 0x24]
mov ebx, eax
push str.unable_to_extract_resource_file__s__cant_load_resource_
push ecx
mov dword [esp + 0x28], ebx
call fcn.00401830
add esp, 0xc
test esi, esi
je 0x404b2c
test edi, edi
je 0x404b2c
test ebx, ebx
jne 0x404b7e
call fcn.00401610
call fcn.00401580
push str.h___NULL__h2___NULL__data___NULL
push 0x1c
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
push 0x41d410
call fcn.004014d0
lea edx, [esp + 0x34]
push edx
push str.Resource_load_failed:___syserror____s
call fcn.004014d0
call fcn.00401630
push 0x1c
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
push str.h___NULL__h2___NULL__data___NULL
call fcn.004019f0
add esp, 0x2c
test esi, esi
je 0x404f39
test edi, edi
je 0x404f39
test ebx, ebx
je 0x404f39
push 0
push 0x80
push 3
push 0
push 0
push 1
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x404d6e
mov esi, dword [esp + 0x18]
add esi, 0x400
push esi
call fcn.0040bee9
mov edi, eax
add esp, 4
test edi, edi
je 0x404d30
push 0
lea eax, [esp + 0x14]
push eax
push esi
push edi
push ebp
mov dword [esp + 0x24], 0
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x404d1e
mov esi, dword [esp + 0x18]
cmp dword [esp + 0x10], esi
jne 0x404cdf
cmp esi, 4
mov eax, esi
mov ecx, edi
mov edx, ebx
jb 0x404c24
lea ecx, [ecx]
mov esi, dword [edx]
cmp esi, dword [ecx]
jne 0x404c28
sub eax, 4
add ecx, 4
add edx, 4
cmp eax, 4
jae 0x404c10
test eax, eax
je 0x404c85
movzx ebx, byte [ecx]
movzx esi, byte [edx]
sub esi, ebx
jne 0x404c77
sub eax, 1
add ecx, 1
add edx, 1
test eax, eax
je 0x404c85
movzx ebx, byte [ecx]
movzx esi, byte [edx]
sub esi, ebx
jne 0x404c77
sub eax, 1
add ecx, 1
add edx, 1
test eax, eax
je 0x404c85
movzx ebx, byte [ecx]
movzx esi, byte [edx]
sub esi, ebx
jne 0x404c77
sub eax, 1
add ecx, 1
add edx, 1
test eax, eax
je 0x404c85
movzx ecx, byte [ecx]
movzx esi, byte [edx]
sub esi, ecx
je 0x404c85
test esi, esi
mov eax, 1
jg 0x404c87
or eax, 0xffffffff
jmp 0x404c87
xor eax, eax
test eax, eax
jne 0x404cdb
push 0x2d
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
call fcn.004010e0
add esp, 0xc
test al, al
je 0x404cc4
call fcn.00401610
call fcn.00401580
mov edx, dword [esp + 0x14]
push edx
push str.WriteResource:_data_matches_whats_already_on_disk___s_
call fcn.004014d0
add esp, 8
call fcn.00401630
push edi
call fcn.0040ad5f
add esp, 4
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x404f6c
mov esi, dword [esp + 0x18]
push 0x34
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
call fcn.004010e0
add esp, 0xc
test al, al
je 0x404d1e
call fcn.00401610
call fcn.00401580
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push eax
push ecx
push esi
push str.WriteResource:_read_back_file_and_data_does_not_match____d_bytes_in_resource_vs__d_bytes_on_disk___s_
call fcn.004014d0
add esp, 0x10
call fcn.00401630
push edi
call fcn.0040ad5f
add esp, 4
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x404da7
push 0x3c
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
call fcn.004010e0
add esp, 0xc
test al, al
je 0x404d65
call fcn.00401610
call fcn.00401580
push esi
push str.WriteResource:_Couldnt_allocate__d_bytes_for_tempBuf
call fcn.004014d0
add esp, 8
call fcn.00401630
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x404da7
push 0x43
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
call fcn.004010e0
add esp, 0xc
test al, al
je 0x404da7
call fcn.00401610
call fcn.00401580
mov edx, dword [esp + 0x14]
push edx
push str.WriteResource:_couldnt_read__s__going_ahead_and_writing_the_file...
call fcn.004014d0
add esp, 8
call fcn.00401630
mov ebp, dword [sym.imp.KERNEL32.dll_Sleep]
xor edi, edi
lea ebx, [edi + 0x28]
mov eax, dword [esp + 0x14]
push 0
push 0x80
push 2
push 0
push 0
push 2
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp dword [0x4a9e8c], ebx
mov esi, eax
jge 0x404e24
cmp esi, 0xffffffff
jne 0x404e24
push 0x50
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
call fcn.004010e0
add esp, 0xc
test al, al
je 0x404e0f
call fcn.00401610
call fcn.00401580
push str.WriteResource:_Sleeping_100ms_because_couldnt_write_file
call fcn.004014d0
add esp, 4
call fcn.00401630
push 0x64
call ebp
add dword [0x4a9e8c], 1
mov ecx, edi
add edi, 1
cmp ecx, 0x14
jl 0x404db2
lea edx, [esp + 0x120]
push edx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov eax, 0x41f7cc
lea ecx, [esp + 0x120]
call fcn.00404aa0
mov edi, dword [esp + 0x14]
mov eax, edi
lea ecx, [esp + 0x120]
call fcn.00404aa0
cmp esi, 0xffffffff
je 0x404ee3
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
push 0
lea eax, [esp + 0x14]
push eax
push ecx
push edx
push esi
mov dword [esp + 0x24], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x404ed5
call fcn.00401610
call fcn.00401580
push 0x41d45c
push 0x62
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
push 0x41d410
call fcn.004014d0
push edi
push str.WriteResource:_WriteFile__s__failed:___syserror__
call fcn.004014d0
call fcn.00401630
push 0x62
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
push 0x41d45c
call fcn.004019f0
add esp, 0x2c
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x404f6c
push 0x68
push str.WriteResource
push str....._vseeCore_vseeResource.cpp
call fcn.004010e0
add esp, 0xc
test al, al
je 0x404f26
call fcn.00401610
call fcn.00401580
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [esp + 0x124]
push eax
push str.Unable_to_create_resource_file__s__GetLastError_returns__d
call fcn.004014d0
add esp, 0xc
call fcn.00401630
push edi
lea ecx, [esp + 0x24]
push str.unable_to_create_resource_file__s
push ecx
call fcn.00401830
add esp, 0xc
cmp byte [esp + 0x234], 0
je 0x404f6a
cmp byte [0x424224], 0
je 0x404f6a
push 0x1000
push 0x41f72c
lea edx, [esp + 0x28]
push edx
push 0
mov byte [0x424224], 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xor al, al
mov ecx, dword [esp + 0x224]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0040a52f
add esp, 0x218
ret