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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0xc0
mov edi, dword [ebp + 0x24]
mov esi, dword [ebp + 0x28]
mov ebx, dword [ebp + 8]
mov dword [esp + 0x44], esi
mov dword [esp + 0x40], edi
mov eax, dword [ebx]
mov edx, dword [ebx + 4]
mov dword [esp + 4], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], edx
mov dword [esp + 0x34], 0
mov dword [esp + 0x30], 0
mov ecx, dword [ebp + 0x20]
mov eax, 6
test ecx, ecx
js 0x404cff
mov eax, ecx
mov dword [esp], edx
mov ecx, edi
mov dword [esp + 0x10], esi
or ecx, esi
je 0x404d1a
mov esi, eax
and esi, 0x400
mov cx, 8
jmp 0x404d34
cmp dword [ebp + 0x14], 0
setne cl
mov esi, eax
and esi, 0x400
sete dl
and dl, cl
movzx ecx, dl
shl ecx, 3
mov dword [esp + 0x2c], ecx
mov ecx, eax
xor ecx, 0xfffeffff
mov edx, eax
or edx, 0x10000
test edx, ecx
mov dword [esp + 0x14], edi
jne 0x404d61
mov ecx, dword [esp + 0x2c]
movzx ecx, cx
or ecx, 0x800
mov dword [esp + 0x2c], ecx
mov edi, eax
not edi
or edi, 0xf
add edi, eax
inc edi
sete al
test esi, esi
setne ah
mov ecx, dword [ebx + 0x48]
mov dword [esp + 0xc], ecx
test ecx, ecx
je 0x405015
cmp dword [ebx + 0x14], 2
jne 0x405015
cmp dword [ebp + 0x14], 0
sete cl
cmp dword [ebp + 0x10], 0
setne dl
cmp dword [ebp + 0xc], 0
je 0x405015
or dl, cl
je 0x405015
cmp word [ebp + 0x1c], 0
setne cl
cmp dword [ebp + 0x18], 0
sete dl
test dl, cl
jne 0x405015
cmp edi, 0xb
jae 0x405015
mov edx, dword [esp + 0xc]
cmp dword [edx + 0x34], 0
mov ecx, dword [ebx + 0x10]
je 0x404def
xor ebx, ebx
cmp ecx, 0xffffffff
jne 0x404e09
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 2
jmp 0x40501e
cmp dword [esp + 0x10], 0
jne 0x404e00
mov bl, 1
cmp ecx, 0xffff
jne 0x404e09
mov dword [edx + 0x34], 1
xor ebx, ebx
mov ecx, dword [esp + 0x14]
or ecx, dword [esp + 0x10]
je 0x404e26
test esi, esi
jne 0x404e26
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0x18
jmp 0x40501c
mov ecx, dword [ebp + 0xc]
cmp byte [ecx], 0x2f
je 0x404eaa
test esi, esi
je 0x404e43
mov eax, dword [ebp + 0x2c]
mov dword [esp + 0x8c], eax
mov byte [esp + 0x1c], 1
jmp 0x404e98
or ah, al
mov byte [esp + 0x14], ah
mov eax, dword [ebp + 0x14]
push eax
push dword [ebp + 0x10]
push 0
call fcn.00402bd0
add esp, 0xc
mov dword [esp + 0x8c], eax
mov dword [esp + 0x10], 0
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0x40], ecx
mov dword [esp + 0x44], 0
mov eax, 0
cmp ecx, 4
setb cl
jb 0x404e87
mov eax, edi
or cl, byte [esp + 0x14]
mov byte [esp + 0x1c], cl
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0x14], ecx
mov edi, eax
push dword [ebp + 0xc]
call fcn.00408070
add esp, 4
cmp eax, 0x10000
jb 0x404eb9
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0x19
jmp 0x40501c
mov dword [esp + 0x20], eax
movzx eax, word [ebp + 0x1c]
mov dword [esp + 0x90], eax
mov dword [esp + 8], 0
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x20]
mov edx, dword [eax + 0x24]
or edx, ecx
mov edx, 0
je 0x404ef4
mov edx, 0xfffffffe
add edx, ecx
inc edx
mov eax, dword [eax]
and eax, edx
sub ecx, eax
and ecx, edx
mov edx, ecx
mov dword [esp + 0x28], edx
mov eax, dword [esp + 0xc]
mov eax, dword [eax + 4]
xor edx, edx
mov ecx, dword [esp + 0x90]
add ecx, dword [esp + 0x20]
setb dl
mov dword [esp + 0x88], eax
add ecx, eax
adc edx, 0
mov eax, ecx
mov dword [esp + 0x24], ecx
add eax, 0x4a
adc edx, 0
mov ecx, 0xfffffffe
cmp ecx, eax
sbb dword [esp + 8], edx
jae 0x404f43
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0xf
jmp 0x40501c
test bl, bl
je 0x404fd2
mov eax, dword [ebp + 8]
mov ebx, dword [eax]
mov ecx, ebx
mov eax, dword [esp + 0x28]
and ecx, eax
xor ebx, eax
add ecx, dword [esp + 0x20]
mov eax, 0
setb al
shld eax, ecx, 1
mov dword [esp + 0x84], eax
add ecx, ecx
mov dword [esp + 8], 0
mov eax, dword [esp + 0x90]
add eax, dword [ebp + 0x38]
mov edx, 0
adc edx, 0xffffffff
add eax, dword [ebp + 0x40]
adc edx, 0
add eax, dword [esp + 0x88]
adc edx, 0
add eax, ebx
mov ebx, dword [ebp + 8]
adc edx, dword [ebx + 4]
add eax, ecx
adc edx, dword [esp + 0x84]
add eax, 0x72
adc edx, 0
cmp edx, 0xffffffff
mov edx, dword [esp + 0x20]
je 0x404fde
mov eax, dword [esp + 0xc]
mov dword [eax + 0x34], 1
mov dword [esp + 8], 0x1c
jmp 0x404fde
mov dword [esp + 8], 0x1c
mov edx, dword [esp + 0x20]
mov dword [esp + 0x88], 0
test edx, edx
je 0x405028
mov eax, dword [ebp + 0xc]
cmp byte [eax + edx - 1], 0x2f
mov ebx, dword [ebp + 8]
jne 0x40502b
cmp dword [ebp + 0x14], 0
jne 0x405015
mov dword [esp + 0x88], 0x10
mov eax, dword [esp + 0x14]
or eax, dword [esp + 0x10]
je 0x40502b
mov dword [ebx + 0x1c], 0x18
xor ebx, ebx
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov ebx, dword [ebp + 8]
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0x24]
add eax, ecx
add eax, 0x2e
mov ecx, dword [esp + 0xc]
cmp dword [ecx + 8], eax
jae 0x40505a
push 1
push eax
push ecx
push ebx
call fcn.00407de0
mov ecx, dword [esp + 0x1c]
add esp, 0x10
test eax, eax
je 0x405197
mov eax, dword [ecx + 0x14]
inc eax
cmp dword [ecx + 0x18], eax
jae 0x40507b
add ecx, 0x10
push 1
push eax
push ecx
push ebx
call fcn.00407de0
add esp, 0x10
test eax, eax
je 0x405197
cmp dword [ebp + 0x14], 0
sete cl
xor eax, eax
or cl, byte [esp + 0x1c]
jne 0x4050a2
push 0x4df40
push 1
push dword [ebx + 0x34]
call dword [ebx + 0x28]
add esp, 0xc
test eax, eax
je 0x405197
mov dword [esp + 8], eax
mov ecx, ebx
mov edx, dword [esp + 4]
push dword [esp + 0x28]
mov ebx, dword [esp + 4]
push ebx
call fcn.00405890
add esp, 8
test eax, eax
je 0x4051a3
test esi, esi
setne al
mov edx, dword [esp + 4]
add edx, dword [esp + 0x28]
adc ebx, 0
mov dword [esp + 0x38], edx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x64], 0
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], 0
mov dword [esp + 0x70], 0
mov dword [esp + 0x74], 0
mov dword [esp + 0x78], 0
mov dword [esp + 0x7c], 0
mov word [esp + 0x80], 0
movzx ecx, byte [esp + 0x1c]
xor cl, 1
or cl, al
mov byte [esp + 0x24], cl
movzx eax, cl
shl eax, 3
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0xc]
cmp dword [eax + 0x34], 0
mov esi, ebx
je 0x4051b8
xor ebx, ebx
mov eax, 0xfffffffe
cmp eax, dword [esp + 0x14]
mov eax, 0
sbb eax, dword [esp + 0x10]
mov dword [esp + 4], edx
jb 0x40517a
xor eax, eax
mov ecx, 0xfffffffe
cmp ecx, edx
sbb eax, esi
mov eax, edx
mov ecx, esi
mov dword [esp + 0xc], 0
jae 0x4052f6
xor eax, eax
mov ecx, 0xfffffffe
cmp ecx, edx
mov ecx, 0
sbb ecx, esi
jb 0x4052ac
xor ecx, ecx
jmp 0x4052b0
mov dword [ebx + 0x1c], 0x10
jmp 0x40501c
push dword [esp + 8]
mov eax, dword [ebp + 8]
push dword [eax + 0x34]
call dword [eax + 0x2c]
add esp, 8
jmp 0x40501c
test esi, esi
je 0x4051cb
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0x1d
jmp 0x40501c
mov dword [esp + 0x64], 0x4034b50
movzx eax, byte [esp + 0x24]
test al, al
je 0x4051de
mov al, 0x14
mov byte [esp + 0x68], al
mov ecx, dword [esp + 0x2c]
movzx eax, cx
mov byte [esp + 0x6a], cl
mov byte [esp + 0x6b], ah
mov eax, dword [esp + 0x28]
mov byte [esp + 0x6c], al
mov dword [esp + 0x6d], 0
mov dword [esp + 0x71], 0
mov dword [esp + 0x75], 0
mov dword [esp + 0x79], 0
mov byte [esp + 0x7d], 0
mov ebx, dword [esp + 0x20]
mov byte [esp + 0x7e], bl
mov byte [esp + 0x7f], bh
mov eax, dword [ebp + 0x38]
mov byte [esp + 0x80], al
mov byte [esp + 0x81], ah
lea eax, [esp + 0x64]
push 0x1e
push eax
push esi
push edx
mov dword [esp + 0x10], esi
mov esi, dword [ebp + 8]
push dword [esi + 0x44]
mov dword [esp + 0x18], edx
call dword [esi + 0x3c]
add esp, 0x14
cmp eax, 0x1e
jne 0x40541f
mov eax, dword [esp + 4]
add eax, 0x1e
mov ecx, dword [esp]
adc ecx, 0
push ebx
push dword [ebp + 0xc]
mov dword [esp + 8], ecx
push ecx
mov dword [esp + 0x10], eax
push eax
push dword [esi + 0x44]
call dword [esi + 0x3c]
add esp, 0x14
cmp eax, ebx
jne 0x405412
mov ecx, dword [esp + 4]
add ecx, ebx
adc dword [esp], 0
mov dword [esp + 0xc], 0
mov dword [esp + 0x14], 0
jmp 0x405433
lea ecx, [esp + 0x38]
mov edx, 0xfffffffe
cmp edx, dword [esp + 0x14]
mov edx, 0
sbb edx, dword [esp + 0x10]
jb 0x4052cb
mov edx, 0
jmp 0x4052cf
lea edx, [esp + 0x30]
jae 0x4052d5
lea eax, [esp + 0x40]
lea ebx, [esp + 0xa0]
push ecx
push edx
push eax
mov dword [esp + 0x18], ebx
push ebx
call fcn.00405930
add esp, 0x10
mov ebx, eax
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x3c]
mov dword [esp + 0x10], eax
mov dword [esp], esi
mov edx, ebx
mov eax, dword [ebp + 0x38]
and edx, eax
mov dword [esp + 0x14], ebx
xor ebx, eax
lea edx, [ebx + edx*2]
mov dword [esp + 0x64], 0x4034b50
movzx eax, byte [esp + 0x24]
test al, al
je 0x405320
mov al, 0x14
mov byte [esp + 0x68], al
mov byte [esp + 0x69], 0
movzx ebx, word [esp + 0x2c]
mov byte [esp + 0x6a], bl
mov byte [esp + 0x6b], bh
mov ebx, dword [esp + 0x28]
mov byte [esp + 0x6c], bl
mov dword [esp + 0x6d], 0
mov dword [esp + 0x71], 0
mov dword [esp + 0x75], 0
mov dword [esp + 0x79], 0
mov byte [esp + 0x7d], 0
mov ebx, dword [esp + 0x20]
mov byte [esp + 0x7e], bl
mov byte [esp + 0x7f], bh
mov byte [esp + 0x80], dl
mov byte [esp + 0x81], dh
lea edx, [esp + 0x64]
push 0x1e
push edx
push ecx
push dword [esp + 0x1c]
mov esi, dword [ebp + 8]
push dword [esi + 0x44]
call dword [esi + 0x3c]
add esp, 0x14
cmp eax, 0x1e
jne 0x40541f
mov ecx, ebx
mov ebx, dword [esp + 4]
lea eax, [ebx + ebx]
and eax, 0x3c
xor ebx, 0x1e
add ebx, eax
mov eax, dword [esp]
adc eax, 0
push ecx
push dword [ebp + 0xc]
mov dword [esp + 8], eax
push eax
push ebx
push dword [esi + 0x44]
call dword [esi + 0x3c]
add esp, 0x14
mov ecx, dword [esp + 0x20]
cmp eax, ecx
jne 0x405412
mov eax, ecx
add ebx, ecx
mov edx, dword [esp]
adc edx, 0
cmp dword [esp + 0xc], 0
mov ecx, ebx
mov dword [esp], edx
je 0x40542b
lea eax, [esp + 0xa0]
mov ebx, dword [esp + 0x14]
push ebx
push eax
push edx
push ecx
push dword [esi + 0x44]
mov dword [esp + 0x18], ecx
call dword [esi + 0x3c]
add esp, 0x14
cmp eax, ebx
jne 0x40541f
mov ecx, dword [esp + 4]
add ecx, ebx
adc dword [esp], 0
jmp 0x405433
push dword [esp + 8]
push dword [esi + 0x34]
call dword [esi + 0x2c]
add esp, 8
mov dword [esi + 0x1c], 0x13
jmp 0x40501c
mov dword [esp + 0xc], 0
mov eax, dword [ebp + 0x38]
test eax, eax
je 0x40546d
push eax
push dword [ebp + 0x34]
push dword [esp + 8]
push ecx
push dword [esi + 0x44]
mov ebx, ecx
call dword [esi + 0x3c]
mov edx, dword [ebp + 0x38]
add esp, 0x14
cmp eax, edx
jne 0x40541f
mov eax, ebx
and eax, edx
mov ecx, eax
shr ecx, 0x1f
add eax, eax
xor ebx, edx
add ebx, eax
mov dword [esp + 4], ebx
adc dword [esp], ecx
jmp 0x405471
mov dword [esp + 4], ecx
cmp byte [esp + 0x1c], 0
je 0x4054c8
mov esi, dword [ebp + 0x14]
push esi
push dword [ebp + 0x10]
push dword [esp + 8]
push dword [esp + 0x10]
mov eax, dword [ebp + 8]
push dword [eax + 0x44]
call dword [eax + 0x3c]
add esp, 0x14
cmp eax, esi
jne 0x405677
mov ecx, esi
mov edx, dword [esp + 4]
mov eax, edx
and eax, ecx
mov ecx, eax
shr ecx, 0x1f
add eax, eax
xor edx, esi
add edx, eax
mov dword [esp + 4], edx
adc dword [esp], ecx
mov dword [esp + 0x30], esi
mov dword [esp + 0x34], 0
jmp 0x405577
cmp dword [ebp + 0x14], 0
je 0x405577
mov eax, dword [ebp + 8]
mov dword [esp + 0x48], eax
mov eax, dword [esp + 4]
mov dword [esp + 0x50], eax
mov eax, dword [esp]
mov dword [esp + 0x54], eax
mov dword [esp + 0x5c], 0
mov dword [esp + 0x58], 0
xor eax, eax
cmp edi, 4
setb al
shl eax, 0xe
or eax, dword [edi*4 + 0x43e84c]
test edi, edi
jne 0x405513
or eax, 0x80000
lea ecx, [esp + 0x48]
push eax
push ecx
push 0x4059a0
mov esi, dword [esp + 0x14]
push esi
call fcn.00404150
add esp, 0x10
mov eax, dword [ebp + 0x14]
mov dword [esp + 0x9c], eax
lea eax, [esp + 0x9c]
push 4
push 0
push 0
push eax
push dword [ebp + 0x10]
push esi
call fcn.00402d20
add esp, 0x18
cmp eax, 1
jne 0x40568c
mov eax, dword [esp + 0x58]
mov ecx, dword [esp + 0x5c]
mov dword [esp + 0x34], ecx
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x50]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x54]
mov dword [esp], eax
push dword [esp + 8]
mov eax, dword [ebp + 8]
push dword [eax + 0x34]
call dword [eax + 0x2c]
add esp, 8
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x44]
mov esi, eax
mov dword [esp + 0x10], ecx
or eax, ecx
je 0x405683
mov dword [esp + 0x48], 0x8074b50
mov ecx, dword [esp + 0x8c]
mov byte [esp + 0x4c], cl
mov byte [esp + 0x4d], ch
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x4e], al
mov eax, ecx
shr eax, 0x18
mov byte [esp + 0x4f], al
mov ebx, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
cmp dword [esp + 0xc], 0
je 0x4056a8
mov byte [esp + 0x50], bl
mov byte [esp + 0x51], bh
mov eax, ebx
shr eax, 0x10
mov byte [esp + 0x52], al
mov eax, ecx
shr eax, 0x10
shr ebx, 0x18
mov byte [esp + 0x53], bl
mov ebx, ecx
shr ebx, 0x18
mov byte [esp + 0x54], cl
mov byte [esp + 0x55], ch
mov byte [esp + 0x56], al
mov byte [esp + 0x57], bl
mov ecx, esi
mov byte [esp + 0x58], cl
mov byte [esp + 0x59], ch
mov eax, esi
shr eax, 0x10
mov byte [esp + 0x5a], al
mov eax, esi
shr eax, 0x18
mov byte [esp + 0x5b], al
mov dword [esp + 0x24], 0x38
mov dword [esp + 0x98], 0x30
mov ecx, 0x28
mov dword [esp + 0x1c], 0x18
mov dword [esp + 8], 0x17
mov eax, dword [esp + 0x10]
mov byte [esp + 0x1b], al
mov dword [esp + 0x84], 0x16
mov dword [esp + 0x94], 0x15
mov edi, 0x14
jmp 0x4056fd
push dword [esp + 8]
mov esi, dword [ebp + 8]
jmp 0x405416
xor eax, eax
xor ecx, ecx
jmp 0x40579f
push dword [esp + 8]
mov esi, dword [ebp + 8]
push dword [esi + 0x34]
call dword [esi + 0x2c]
add esp, 8
mov dword [esi + 0x1c], 0xc
jmp 0x40501c
test ecx, ecx
jne 0x4051bc
mov dword [esp + 0x50], ebx
mov dword [esp + 0x24], 0x18
mov dword [esp + 0x98], 0x10
mov ecx, 8
mov dword [esp + 8], 0xf
mov dword [esp + 0x84], 0xe
mov eax, esi
mov byte [esp + 0x1b], al
mov dword [esp + 0x94], 0xd
mov edi, 0xc
mov dword [esp + 0x1c], 0x10
mov ebx, esi
mov eax, dword [esp + 0x10]
shrd ebx, eax, cl
shr eax, cl
movzx edx, byte [esp + 0x1b]
mov byte [esp + edi + 0x48], dl
test cl, 0x20
jne 0x405718
mov eax, ebx
mov ebx, esi
mov ecx, dword [esp + 0x98]
mov edx, dword [esp + 0x10]
shrd ebx, edx, cl
mov edi, dword [esp + 0x94]
mov byte [esp + edi + 0x48], al
mov eax, edx
shr eax, cl
test cl, 0x20
jne 0x40573e
mov eax, ebx
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x10]
shrd esi, edx, cl
mov edi, dword [esp + 0x84]
mov byte [esp + edi + 0x48], al
shr edx, cl
test cl, 0x20
jne 0x40575d
mov edx, esi
mov eax, dword [esp + 8]
mov byte [esp + eax + 0x48], dl
lea eax, [esp + 0x48]
mov esi, dword [esp + 0x1c]
push esi
push eax
push dword [esp + 8]
push dword [esp + 0x10]
mov eax, dword [ebp + 8]
push dword [eax + 0x44]
call dword [eax + 0x3c]
add esp, 0x14
cmp eax, esi
jne 0x40501c
mov eax, dword [esp + 0x1c]
add dword [esp + 4], eax
adc dword [esp], 0
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x44]
cmp dword [esp + 0xc], 0
je 0x405804
xor edx, edx
mov esi, 0xfffffffe
cmp esi, dword [esp + 0x38]
mov esi, 0
sbb esi, dword [esp + 0x3c]
jb 0x4057c0
xor edi, edi
jmp 0x4057c4
lea edi, [esp + 0x38]
mov esi, 0xfffffffe
cmp esi, eax
mov eax, 0
sbb eax, ecx
jb 0x4057db
mov eax, 0
jmp 0x4057df
lea eax, [esp + 0x30]
jae 0x4057e5
lea edx, [esp + 0x40]
lea ecx, [esp + 0xa0]
push edi
push eax
push edx
push ecx
call fcn.00405930
add esp, 0x10
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x44]
movzx ebx, word [esp + 0x2c]
movzx esi, word [esp + 0x28]
movzx edx, word [esp + 0x14]
movzx edi, word [esp + 0x20]
push dword [ebp + 0x40]
push dword [ebp + 0x3c]
push dword [esp + 0x90]
push dword [esp + 0x48]
push dword [esp + 0x48]
push 0
push 0
push ebx
push esi
push dword [esp + 0xb0]
push dword [esp + 0x5c]
push dword [esp + 0x5c]
push ecx
push eax
push dword [esp + 0xc8]
push dword [ebp + 0x18]
push edx
push dword [esp + 0x50]
push edi
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004059f0
add esp, 0x54
test eax, eax
je 0x40501c
mov eax, dword [ebp + 8]
inc dword [eax + 0x10]
mov ecx, dword [esp + 4]
mov dword [eax], ecx
mov ecx, dword [esp]
mov dword [eax + 4], ecx
mov ebx, 1
jmp 0x40501e