Function at 0x540880
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0xcc
push ebx
push esi
mov esi, dword [0x65b33c]
push edi
lea eax, [esp + 0xb8]
push eax
mov edi, ecx
call esi
lea ecx, [esp + 0x58]
push 0x80
push ecx
call fcn.0050cd20
add esp, 8
lea edx, [esp + 0x14]
push edx
call esi
mov ecx, dword [edi]
call fcn.0054ca10
mov ecx, eax
call fcn.005e2040
mov ebx, eax
test ebx, ebx
je 0x540b1f
mov ecx, dword [edi + 8]
push ebp
call fcn.005447b0
mov ebp, dword [esp + 0xe4]
mov dword [esp + 0x28], eax
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x14]
push ecx
mov ecx, ebp
call fcn.00541130
mov esi, dword [esp + 0xe0]
mov eax, dword [esi + 0x10]
mov ecx, dword [esi + 0x14]
mov edx, dword [esp + 0x10]
mov dword [esp + 0x4c], eax
sub eax, 0xffffff80
mov dword [esp + 0x50], ecx
mov dword [esp + 0x54], eax
xor eax, eax
sub ecx, 0xffffff80
mov dword [esp + 0x58], ecx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x14]
lea ecx, [esp + 0x2c]
mov dword [esp + 0x34], edx
push ecx
lea edx, [esp + 0x50]
mov dword [esp + 0x3c], eax
push edx
mov eax, ecx
push eax
call dword [0x65b460]
test eax, eax
je 0x540b1e
movzx ecx, byte [esi + 0xa]
movzx edx, byte [esi + 9]
movzx eax, byte [esi + 8]
push ecx
mov ecx, dword [edi]
push edx
push eax
call fcn.0054c9b0
movzx ecx, byte [esi + 0xe]
movzx edx, byte [esi + 0xd]
movzx eax, byte [esi + 0xc]
push ecx
mov ecx, dword [edi]
push edx
push eax
call fcn.0054c9d0
mov eax, dword [edi]
mov edx, dword [eax]
mov eax, dword [esp + 0x28]
mov ecx, dword [eax + 0xac]
push ecx
mov edx, dword [edx + 4]
xor ecx, ecx
cmp dword [eax + 0xa0], 0x2bc
lea eax, [esi + 0x34]
sete cl
push ecx
mov ecx, dword [esi + 0x1c]
push eax
movzx eax, word [esi + 4]
push ecx
push eax
lea ecx, [esp + 0x50]
push ecx
mov ecx, dword [edi]
call edx
mov ecx, dword [eax]
mov dword [esp + 0x18], ecx
mov edx, dword [eax + 4]
mov dword [esp + 0x1c], edx
mov edx, dword [eax + 8]
mov dword [esp + 0x20], edx
mov eax, dword [eax + 0xc]
mov dword [esi + 0x40], ecx
mov ecx, dword [esp + 0x1c]
mov dword [esi + 0x44], ecx
mov dword [esi + 0x48], edx
mov ecx, ebp
mov dword [esp + 0x24], eax
mov dword [esi + 0x4c], eax
call fcn.00541150
mov ecx, ebp
mov dword [esp + 0x5c], eax
call fcn.005673b0
mov ecx, dword [esi + 0x10]
add ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0x64], edx
mov edx, dword [esi + 0x14]
add edx, dword [esp + 0x1c]
mov dword [esp + 0x6c], ecx
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x20]
mov dword [esp + 0x78], ecx
mov ecx, ebp
mov dword [esp + 0x70], edx
mov dword [esp + 0x74], eax
call fcn.0052a210
xor esi, esi
mov ecx, ebx
mov dword [esp + 0x7c], eax
mov dword [esp + 0x80], esi
call fcn.00541150
mov ecx, ebx
mov dword [esp + 0x84], eax
call fcn.005673b0
mov dword [esp + 0x88], eax
lea edx, [esp + 0x14]
push edx
lea eax, [esp + 0x14]
push eax
mov ecx, ebx
call fcn.00541130
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
mov dword [esp + 0x8c], ecx
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x90], edx
mov edx, dword [esp + 0x20]
mov dword [esp + 0x94], eax
mov eax, dword [esp + 0x24]
mov dword [esp + 0x98], ecx
mov ecx, ebx
mov dword [esp + 0x9c], edx
mov dword [esp + 0xa0], eax
call fcn.0052a210
lea ecx, [esp + 0x5c]
push ecx
mov dword [esp + 0xa8], eax
mov dword [esp + 0xac], 0xff
mov dword [esp + 0xb0], esi
mov dword [esp + 0xb4], esi
mov dword [esp + 0xb8], 1
mov dword [esp + 0xbc], esi
call fcn.00558170
mov eax, dword [esp + 0x70]
mov edx, dword [esp + 0x78]
mov ecx, dword [esp + 0x74]
add edx, eax
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x7c]
add eax, ecx
mov dword [esp + 0x44], ecx
add esp, 4
lea ecx, [esp + 0x3c]
push ecx
mov ecx, dword [edi + 0xc]
mov dword [esp + 0x48], edx
mov dword [esp + 0x4c], eax
call fcn.0062a2b0
pop ebp
pop edi
pop esi
pop ebx
add esp, 0xcc
ret 8