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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
mov esi, dword [ebp + 8]
push edi
xor edi, edi
cmp esi, edi
jne 0x40b02c
pop edi
mov eax, 0xffffff9a
pop esi
mov esp, ebp
pop ebp
ret
cmp dword [esi + 0x2c], edi
je 0x40b021
cmp dword [esi + 0x80], 8
push ebx
mov dword [esi + 0x34], edi
jne 0x40b087
cmp dword [esi + 0x84], edi
jne 0x40b087
cmp dword [esi + 0x40], 0
jne 0x40b061
call fcn.0040ae20
lea eax, [esi + 0x88]
mov dword [esi + 0x40], 0x4000
mov dword [esi + 0x3c], eax
mov ebx, dword [esi + 0x44]
lea eax, [esi + 0x30]
push 4
push eax
call fcn.004070fb
mov ecx, dword [esi + 0x44]
sub ecx, ebx
add dword [esi + 0x6c], ecx
mov edi, eax
add esp, 8
test edi, edi
je 0x40b046
cmp edi, 1
jne 0x40b087
xor edi, edi
cmp dword [esi + 0x6c], 0
jbe 0x40b09d
test edi, edi
jne 0x40b09d
call fcn.0040ae20
cmp eax, 0xffffffff
jne 0x40b09d
or edi, eax
cmp dword [esi + 0x80], 8
jne 0x40b0c4
cmp dword [esi + 0x84], 0
jne 0x40b0de
lea edx, [esi + 0x30]
push edx
call fcn.0040783d
add esp, 4
mov edi, eax
mov dword [esi + 0x68], 0
cmp dword [esi + 0x84], 0
jne 0x40b0de
mov eax, dword [esi + 0x408c]
mov edx, dword [esi + 0x38]
mov dword [ebp + 0x10], eax
mov dword [ebp + 0xc], edx
jmp 0x40b0e4
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp + 0xc]
mov ebx, dword [esi + 0x40a4]
add ebx, dword [esi + 0x44]
mov ecx, dword [esi + 0x74]
mov byte [ecx + 0x10], al
shr eax, 8
mov dword [ebp - 4], eax
mov byte [ecx + 0x11], al
shr eax, 8
mov byte [ecx + 0x12], al
shr eax, 8
mov byte [ecx + 0x13], al
shr eax, 8
mov dword [ebp + 8], eax
test eax, eax
je 0x40b119
mov dword [ecx + 0x10], 0xffffffff
mov ecx, dword [esi + 0x74]
mov eax, ebx
shr eax, 8
mov dword [ebp - 8], eax
mov byte [ecx + 0x15], al
shr eax, 8
mov byte [ecx + 0x16], al
shr eax, 8
mov byte [ecx + 0x17], al
shr eax, 8
mov byte [ecx + 0x14], bl
mov dword [ebp + 8], eax
test eax, eax
je 0x40b147
mov dword [ecx + 0x14], 0xffffffff
cmp dword [esi + 0x5c], 1
jne 0x40b156
mov eax, dword [esi + 0x74]
mov word [eax + 0x24], 1
mov ecx, dword [esi + 0x74]
mov eax, edx
shr eax, 8
mov dword [ebp - 0xc], eax
mov byte [ecx + 0x19], al
shr eax, 8
mov byte [ecx + 0x1a], al
shr eax, 8
mov byte [ecx + 0x1b], al
shr eax, 8
mov byte [ecx + 0x18], dl
mov dword [ebp + 8], eax
test eax, eax
je 0x40b184
mov dword [ecx + 0x18], 0xffffffff
test edi, edi
jne 0x40b19e
mov eax, dword [esi + 0x78]
mov ecx, dword [esi + 0x74]
push eax
push ecx
lea edx, [esi + 0x24]
push edx
call fcn.0040a4f0
add esp, 0xc
mov edi, eax
mov eax, dword [esi + 0x74]
push eax
call fcn.0040bf61
add esp, 4
test edi, edi
jne 0x40b2c1
mov ecx, dword [esi + 0x20]
mov edx, dword [esi + 0x1c]
mov eax, dword [esi + 0xc]
push ecx
push edx
call eax
mov ecx, dword [esi + 0x70]
mov edx, dword [esi + 0x20]
push edi
add ecx, 0xe
push ecx
mov ecx, dword [esi + 0x10]
mov dword [ebp - 0x10], eax
mov eax, dword [esi + 0x1c]
push edx
push eax
call ecx
add esp, 0x18
or edi, 0xffffffff
test eax, eax
jne 0x40b2a4
mov eax, dword [ebp - 4]
mov dl, byte [ebp + 0x10]
mov ecx, dword [esi + 0x20]
mov byte [ebp + 9], al
shr eax, 8
mov byte [ebp + 0xa], al
shr eax, 8
mov byte [ebp + 0xb], al
shr eax, 8
mov byte [ebp + 8], dl
mov dword [ebp - 4], eax
test eax, eax
je 0x40b20d
mov dword [ebp + 8], edi
mov edx, dword [esi + 8]
push 4
lea eax, [ebp + 8]
push eax
push ecx
mov ecx, dword [esi + 0x1c]
push ecx
call edx
add esp, 0x10
cmp eax, 4
jne 0x40b2a4
mov eax, dword [ebp - 8]
mov ecx, dword [esi + 0x20]
mov byte [ebp + 9], al
shr eax, 8
mov byte [ebp + 0xa], al
shr eax, 8
mov byte [ebp + 0xb], al
shr eax, 8
mov byte [ebp + 8], bl
mov dword [ebp - 8], eax
test eax, eax
je 0x40b24a
mov dword [ebp + 8], edi
mov edx, dword [esi + 8]
push 4
lea eax, [ebp + 8]
push eax
push ecx
mov ecx, dword [esi + 0x1c]
push ecx
call edx
add esp, 0x10
cmp eax, 4
jne 0x40b2a4
mov al, byte [ebp + 0xc]
mov ecx, dword [esi + 0x20]
mov byte [ebp + 8], al
mov eax, dword [ebp - 0xc]
mov byte [ebp + 9], al
shr eax, 8
mov byte [ebp + 0xa], al
shr eax, 8
mov byte [ebp + 0xb], al
shr eax, 8
mov dword [ebp - 0xc], eax
test eax, eax
je 0x40b28a
mov dword [ebp + 8], edi
mov eax, dword [esi + 0x1c]
push 4
lea edx, [ebp + 8]
push edx
push ecx
mov ecx, dword [esi + 8]
push eax
call ecx
add esp, 0x10
lea edi, [eax - 4]
neg edi
sbb edi, edi
mov edx, dword [ebp - 0x10]
mov eax, dword [esi + 0x20]
mov ecx, dword [esi + 0x1c]
push 0
push edx
mov edx, dword [esi + 0x10]
push eax
push ecx
call edx
add esp, 0x10
test eax, eax
je 0x40b2c1
or edi, 0xffffffff
inc dword [esi + 0x40b0]
pop ebx
mov eax, edi
pop edi
mov dword [esi + 0x2c], 0
pop esi
mov esp, ebp
pop ebp
ret