Function at 0x404540
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
lea ebp, [esp - 0x408]
sub esp, 0x408
push 0xffffffffffffffff
push 0x421c60
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x42e1f8]
xor eax, ebp
mov dword [ebp + 0x404], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 0x414]
mov edi, dword [ebp + 0x410]
mov dword [ebp - 0x1c], eax
xor eax, eax
mov esi, edx
mov dword [ebp - 0x24], eax
mov dword [ebp - 4], eax
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x2c], eax
mov dword [ebp], eax
push 2
push eax
push esi
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov ebx, eax
mov dword [ebp - 0x20], ebx
test ebx, ebx
jne 0x4045e8
mov edx, dword [0x42f12c]
push esi
push str.Failed_to_LoadLibrary_on__s_n
push eax
push edx
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], str.C:PROGRA2MICROS1.0VC_atlmfcinclude_statreg.h
mov dword [ebp - 0x14], 0x188
call fcn.004038e0
add esp, 0x10
call fcn.00402360
mov esi, eax
jmp 0x404729
mov eax, dword [ebp - 0x1c]
push eax
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x40463e
mov ecx, edi
shr ecx, 0x10
mov eax, str.Failed_to_FindResource_on_ID:_d_TYPE:_s_n
test ecx, ecx
je 0x40460d
mov eax, str.Failed_to_FindResource_on_ID:_s_TYPE:_s_n
mov edx, dword [ebp - 0x1c]
push edx
push edi
push eax
mov eax, dword [0x42f12c]
push 0
push eax
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], str.C:PROGRA2MICROS1.0VC_atlmfcinclude_statreg.h
mov dword [ebp - 0x14], 0x191
call fcn.004038e0
add esp, 0x14
call fcn.00402360
jmp 0x404720
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x40467d
mov ecx, dword [0x42f12c]
push str.Failed_to_LoadResource_n
push eax
push ecx
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], str.C:PROGRA2MICROS1.0VC_atlmfcinclude_statreg.h
mov dword [ebp - 0x14], 0x19c
call fcn.004038e0
add esp, 0xc
call fcn.00402360
jmp 0x404720
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
lea eax, [esi + 1]
mov dword [ebp - 0x1c], esi
cmp eax, esi
jae 0x4046b3
lea edx, [ebp + 4]
cmp dword [ebp], edx
je 0x4046a1
lea eax, [ebp]
call fcn.00402bf0
lea esi, [ebp - 0x24]
call fcn.00402d10
mov eax, 0x8007000e
jmp 0x404742
lea edi, [ebp]
mov byte [ebp - 4], 2
call fcn.00402300
mov dword [ebp - 4], 1
jmp 0x4046db
mov eax, dword [ebp]
test eax, eax
jne 0x4046e9
mov esi, 0x8007000e
jmp 0x404722
push esi
push eax
mov eax, dword [ebp - 0x14]
push esi
push eax
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jne 0x404705
call fcn.00402360
jmp 0x404720
mov edx, dword [ebp]
xor ecx, ecx
mov word [edx + eax*2], cx
mov eax, dword [ebp + 0x418]
mov ecx, dword [ebp]
push eax
lea edx, [ebp - 0x2c]
call fcn.00404340
mov esi, eax
push ebx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea ecx, [ebp + 4]
cmp dword [ebp], ecx
je 0x404740
lea eax, [ebp]
call fcn.00402bf0
lea esp, [esp]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x404]
xor ecx, ebp
call fcn.00407200
add ebp, 0x408
mov esp, ebp
pop ebp
ret 0xc