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

Disassembly:
sub esp, 0x90
push ebx
push ebp
xor ecx, ecx
xorps xmm0, xmm0
push esi
push edi
movlpd qword [esp + 0x68], xmm0
cmp word [esp + 0xb4], cx
je 0x59b154
mov eax, dword [esp + 0xa4]
mov eax, dword [eax]
mov eax, dword [eax]
test byte [eax + 0x50], 0x40
jne 0x59ba81
mov eax, dword [esp + 0xa8]
movzx eax, word [eax]
mov dword [esp + 0x7c], eax
cmp eax, 0x3f
ja 0x59ba81
movzx edi, ax
xor edx, edx
xor ebx, ebx
mov ebp, dword [esp + 0x6c]
mov eax, edi
movlpd qword [esp + 0x40], xmm0
bts edx, eax
movlpd qword [esp + 0x38], xmm0
cmp eax, 0x20
mov byte [esp + 0x18], 1
mov dword [esp + 0x34], edi
cmovae ebx, edx
mov dword [esp + 0x1c], ebp
xor edx, ebx
cmp eax, 0x40
mov eax, dword [esp + 0xb0]
cmovae ebx, edx
add edx, 0xffffffff
mov dword [esp + 0x78], edx
mov edx, dword [esp + 0x68]
adc ebx, 0xffffffff
and eax, 0x803
mov dword [esp + 0x74], ebx
mov ebx, dword [esp + 0x18]
neg eax
mov dword [esp + 0x14], edx
sbb eax, eax
neg eax
add eax, 0x182
xor esi, esi
movzx eax, ax
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x44]
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x40]
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 0x64], esi
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x74]
cmp ebp, eax
ja 0x59b9fa
jb 0x59b218
cmp edx, dword [esp + 0x78]
jae 0x59b9fe
movzx eax, word [esp + 0xb4]
cmp esi, eax
jg 0x59ba25
test esi, esi
jle 0x59b246
mov edi, dword [esp + 0x4c]
or edi, dword [ecx + 8]
mov dword [esp + 0x4c], edi
mov edi, dword [esp + 0x50]
or edi, dword [ecx + 0xc]
mov dword [esp + 0x50], edi
mov edi, dword [esp + 0x34]
cmp esi, eax
jge 0x59b270
mov eax, dword [esp + 0xac]
mov eax, dword [eax + 0x18]
mov esi, dword [eax + esi*4]
mov eax, dword [esp + 0xb0]
mov dword [esp + 0x24], esi
test eax, 0x800
je 0x59b282
mov ecx, esi
jmp 0x59b9e5
mov esi, dword [esp + 0xb8]
mov eax, dword [esp + 0xb0]
mov dword [esp + 0x24], esi
test dword [esi + 0x2c], 0x400
jne 0x59ba13
and eax, 0x80
mov dword [esp + 0x40], eax
je 0x59b2a0
xor eax, eax
mov word [esi + 0x1e], ax
movzx eax, byte [esi + 0x10]
lea ecx, [eax + eax*8]
mov eax, dword [esp + 0xa4]
mov eax, dword [eax + 4]
mov edi, dword [eax + ecx*8 + 0x34]
xor eax, eax
mov dword [esp + 0x30], edi
mov dword [esp + 0x28], eax
cmp dword [esp + 0x34], eax
jbe 0x59b439
mov ebx, dword [esp + 0xa8]
add ebx, 8
mov dword [esp + 0x20], ebx
xor ebp, ebp
xor edx, edx
bts ebp, eax
cmp eax, 0x20
cmovae edx, ebp
xor ebp, edx
cmp eax, 0x40
mov ecx, ebp
cmovae edx, ebp
and ecx, dword [esp + 0x14]
mov eax, edx
mov dword [esp + 0x38], edx
and eax, dword [esp + 0x1c]
or ecx, eax
jne 0x59b419
mov esi, dword [ebx]
test esi, esi
je 0x59b419
nop
mov eax, dword [esi + 4]
test eax, 0x82000
je 0x59b335
test eax, 0x80000
je 0x59b329
mov eax, dword [esi + 0x14]
mov esi, dword [eax + 8]
jmp 0x59b32c
mov esi, dword [esi + 0xc]
test esi, esi
jne 0x59b310
jmp 0x59b419
mov al, byte [esi]
cmp al, 0xa7
je 0x59b343
cmp al, 0xa9
jne 0x59b419
cmp dword [esi + 0x1c], edi
jne 0x59b419
mov eax, dword [esp + 0x70]
mov ecx, dword [esp + 0x4c]
movzx eax, ax
not ecx
push 0
push eax
mov eax, dword [esp + 0x58]
not eax
push eax
movsx eax, word [esi + 0x20]
push ecx
push eax
mov eax, dword [esp + 0xb8]
add eax, 0x50
push edi
push eax
call fcn.00586150
mov edi, eax
add esp, 0x1c
test edi, edi
je 0x59b415
movzx ebx, word [edi + 0xc]
cmp ebx, 1
jne 0x59b3b1
mov eax, dword [esp + 0x24]
xor ecx, ecx
movzx edx, word [eax + 0x30]
test edx, edx
je 0x59b3ad
mov eax, dword [eax + 0x38]
cmp edi, dword [eax]
je 0x59b3ad
inc ecx
add eax, 4
cmp ecx, edx
jl 0x59b3a1
cmp ecx, edx
jge 0x59b415
test bl, 0x82
je 0x59b3ff
cmp word [esi + 0x20], 0
jl 0x59b3ff
mov eax, dword [esp + 0xa4]
mov esi, dword [eax]
mov eax, dword [esp + 0x20]
push dword [eax]
push esi
call fcn.00542300
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x59b3e0
mov eax, dword [esi]
mov ebx, dword [eax + 8]
push dword [edi]
push esi
call fcn.005427a0
add esp, 8
test eax, eax
je 0x59b415
push dword [eax]
push dword [ebx]
call fcn.0056ab20
add esp, 8
test eax, eax
jne 0x59b415
mov edx, dword [esp + 0x14]
or edx, ebp
mov ebp, dword [esp + 0x1c]
or ebp, dword [esp + 0x38]
mov dword [esp + 0x14], edx
mov dword [esp + 0x1c], ebp
mov edi, dword [esp + 0x30]
mov eax, dword [esp + 0x28]
add dword [esp + 0x20], 0x14
inc eax
mov ebx, dword [esp + 0x20]
mov dword [esp + 0x28], eax
cmp eax, dword [esp + 0x34]
jl 0x59b2d7
mov esi, dword [esp + 0x24]
mov eax, dword [esi + 0x2c]
test eax, 0x1000
jne 0x59b851
test eax, 0x100
je 0x59b465
mov dword [esp + 0x48], 0
mov ecx, 1
mov dword [esp + 0x38], 0
jmp 0x59b4a1
mov edx, dword [esi + 0x20]
mov dword [esp + 0x48], edx
test edx, edx
je 0x59ba81
test byte [edx + 0x38], 4
jne 0x59ba81
cmp byte [edx + 0x36], 0
movzx ecx, word [edx + 0x32]
mov dword [esp + 0x38], ecx
movzx ecx, word [edx + 0x34]
je 0x59b49c
mov byte [esp + 0x18], 1
test eax, 0x8000
je 0x59b4a1
mov byte [esp + 0x18], 0
xor al, al
xor dl, dl
mov byte [esp + 0x13], al
xor ebp, ebp
mov dword [esp + 0x28], eax
movzx eax, cx
mov byte [esp + 0x12], dl
mov dword [esp + 0x20], ebp
mov dword [esp + 0x68], eax
test eax, eax
je 0x59b851
mov dword [esp + 0x58], ebp
nop word [eax + eax]
movzx edi, word [esi + 0x18]
mov bh, 1
mov byte [esp + 0x11], bh
cmp ebp, edi
jge 0x59b542
movzx eax, word [esi + 0x32]
cmp ebp, eax
jl 0x59b542
mov ebx, dword [esi + 0x38]
mov eax, dword [esp + 0x70]
mov esi, dword [ebx + ebp*4]
movzx ecx, word [esi + 0xc]
and eax, ecx
test ax, ax
je 0x59b519
mov eax, dword [esp + 0x18]
test ecx, 0x180
mov ecx, 0
movzx eax, al
cmove ecx, eax
mov byte [esp + 0x18], cl
jmp 0x59b812
test cl, 1
je 0x59b53e
mov esi, dword [esi]
lea edx, [ebp + 1]
cmp edx, edi
jge 0x59b53e
lea ecx, [ebp + 1]
lea ecx, [ebx + ecx*4]
nop dword [eax]
mov eax, dword [ecx]
cmp dword [eax], esi
je 0x59b571
inc edx
add ecx, 4
cmp edx, edi
jl 0x59b530
mov bh, byte [esp + 0x11]
mov edx, dword [esp + 0x48]
test edx, edx
je 0x59b575
mov eax, dword [edx + 4]
movsx esi, word [eax + ebp*2]
mov eax, dword [edx + 0x1c]
mov cl, byte [eax + ebp]
mov eax, dword [edx + 0xc]
and cl, 1
mov byte [esp + 0x11], cl
movsx eax, word [eax + 0x20]
cmp esi, eax
mov eax, 0xffffffff
cmove esi, eax
jmp 0x59b57d
xor bh, bh
jmp 0x59b542
or esi, 0xffffffff
mov byte [esp + 0x11], 0
mov eax, dword [esp + 0x18]
mov dword [esp + 0x54], esi
test al, al
je 0x59b5b8
test esi, esi
js 0x59b5a9
cmp ebp, edi
jl 0x59b5b8
mov eax, dword [edx + 0xc]
mov ecx, esi
add ecx, ecx
mov eax, dword [eax + 4]
test byte [eax + ecx*8 + 4], 0xf
jne 0x59b5b8
mov byte [esp + 0x18], 0
jmp 0x59b5b8
xor ecx, ecx
movzx eax, al
cmp esi, 0xfffffffe
cmove eax, ecx
mov dword [esp + 0x18], eax
xor edi, edi
test bh, bh
je 0x59b82f
mov ebp, dword [esp + 0xa8]
add ebp, 8
nop dword [eax]
cmp edi, dword [esp + 0x34]
jge 0x59b82b
xor edx, edx
xor ecx, ecx
mov eax, edi
bts edx, eax
cmp eax, 0x20
cmovae ecx, edx
xor edx, ecx
cmp eax, 0x40
cmovae ecx, edx
and edx, dword [esp + 0x14]
and ecx, dword [esp + 0x1c]
or edx, ecx
jne 0x59b707
mov eax, dword [ebp]
test eax, eax
je 0x59b707
nop dword [eax]
mov ecx, dword [eax + 4]
test ecx, 0x82000
je 0x59b637
test ecx, 0x80000
je 0x59b62b
mov ecx, dword [eax + 0x14]
mov eax, dword [ecx + 8]
jmp 0x59b62e
mov eax, dword [eax + 0xc]
test eax, eax
jne 0x59b610
jmp 0x59b707
mov cl, byte [esp + 0xb0]
and cl, 0xc0
neg cl
sbb cl, cl
and bh, cl
mov bl, bh
cmp esi, 0xffffffff
jl 0x59b675
mov cl, byte [eax]
cmp cl, 0xa7
je 0x59b65e
cmp cl, 0xa9
jne 0x59b707
mov ecx, dword [esp + 0x30]
mov bh, bl
cmp dword [eax + 0x1c], ecx
jne 0x59b707
movsx eax, word [eax + 0x20]
cmp eax, esi
jmp 0x59b6c2
mov ecx, dword [esp + 0x48]
mov edx, dword [esp + 0x58]
mov ecx, dword [ecx + 0x28]
mov ecx, dword [ecx + edx + 8]
test ecx, ecx
je 0x59b6a0
nop dword [eax + eax]
test dword [ecx + 4], 0x2000
je 0x59b6a0
mov ecx, dword [ecx + 0xc]
test ecx, ecx
jne 0x59b690
test dword [eax + 4], 0x2000
je 0x59b6b0
mov eax, dword [eax + 0xc]
test eax, eax
jne 0x59b6a0
push dword [esp + 0x30]
push ecx
push eax
push 0
call fcn.00542530
add esp, 0x10
test eax, eax
jne 0x59b707
cmp esi, 0xffffffff
je 0x59b720
mov eax, dword [esp + 0xa4]
push dword [ebp]
mov esi, dword [eax]
push esi
call fcn.00542300
mov ecx, eax
add esp, 8
test ecx, ecx
jne 0x59b6e9
mov eax, dword [esi]
mov ecx, dword [eax + 8]
mov eax, dword [esp + 0x48]
mov bh, bl
mov edx, dword [esp + 0x20]
mov eax, dword [eax + 0x20]
push dword [eax + edx*4]
push dword [ecx]
call fcn.0056ab20
add esp, 8
test eax, eax
je 0x59b71c
inc edi
add ebp, 0x14
test bh, bh
je 0x59b82b
mov esi, dword [esp + 0x54]
jmp 0x59b5d0
mov esi, dword [esp + 0x54]
cmp word [esp + 0x40], 0
mov ebp, dword [esp + 0x20]
je 0x59b737
mov ecx, dword [esp + 0x24]
lea eax, [ebp + 1]
mov word [ecx + 0x1e], ax
test byte [esp + 0xb0], 0x40
mov byte [esp + 0x2f], 1
jne 0x59b7bb
mov ecx, dword [esp + 0xa8]
lea eax, [edi + edi*4]
mov bh, byte [esp + 0x13]
mov dl, byte [ecx + eax*4 + 0x10]
and dl, 1
test bh, bh
je 0x59b787
mov dh, byte [esp + 0x12]
xor ecx, ecx
mov bl, byte [esp + 0x11]
movzx eax, byte [esp + 0x2f]
xor bl, dh
cmp bl, dl
mov byte [esp + 0x12], dh
mov byte [esp + 0x13], bh
cmove ecx, eax
test cl, cl
je 0x59b82f
jmp 0x59b7bb
xor dl, byte [esp + 0x11]
mov byte [esp + 0x12], dl
je 0x59b7b6
mov eax, dword [esp + 0x64]
xor ecx, ecx
bts ecx, eax
xor edx, edx
cmp eax, 0x20
cmovae edx, ecx
xor ecx, edx
cmp eax, 0x40
mov eax, dword [esp + 0xbc]
cmovae edx, ecx
or dword [eax], ecx
or dword [eax + 4], edx
mov byte [esp + 0x13], 1
mov ecx, dword [esp + 0xa8]
lea eax, [edi + edi*4]
test byte [ecx + eax*4 + 0x10], 2
je 0x59b7df
mov ecx, dword [esp + 0x24]
movzx eax, word [ecx + 0x18]
cmp ebp, eax
jne 0x59b82f
or dword [ecx + 0x2c], 0x80000
mov edx, dword [esp + 0x28]
cmp esi, 0xffffffff
mov eax, 1
movzx edx, dl
cmove edx, eax
xor eax, eax
xor ecx, ecx
mov dword [esp + 0x28], edx
bts eax, edi
cmp edi, 0x20
cmovae ecx, eax
xor eax, ecx
cmp edi, 0x40
cmovae ecx, eax
or dword [esp + 0x14], eax
or dword [esp + 0x1c], ecx
add dword [esp + 0x58], 0x14
inc ebp
mov dword [esp + 0x20], ebp
cmp ebp, dword [esp + 0x68]
jge 0x59b843
mov esi, dword [esp + 0x24]
jmp 0x59b4d0
mov ebp, dword [esp + 0x20]
test ebp, ebp
je 0x59b83e
mov eax, dword [esp + 0x38]
movzx eax, ax
cmp ebp, eax
jge 0x59b843
mov byte [esp + 0x18], 0
cmp byte [esp + 0x28], 0
je 0x59b851
mov byte [esp + 0x18], 1
jmp 0x59b85c
cmp byte [esp + 0x18], 0
je 0x59b9d1
mov ecx, dword [esp + 0x24]
mov eax, dword [esp + 0x5c]
mov edi, dword [esp + 0x34]
mov ebp, dword [esp + 0x1c]
or eax, dword [ecx + 8]
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x60]
or eax, dword [ecx + 0xc]
mov dword [esp + 0x60], eax
xor eax, eax
mov dword [esp + 0x38], eax
test edi, edi
je 0x59b9dd
mov esi, dword [esp + 0xa8]
add esi, 8
mov dword [esp + 0x28], esi
nop word [eax + eax]
xor edi, edi
xor edx, edx
bts edi, eax
cmp eax, 0x20
cmovae edx, edi
xor edi, edx
cmp eax, 0x40
mov ecx, edi
cmovae edx, edi
and ecx, dword [esp + 0x14]
mov eax, edx
mov dword [esp + 0x68], edx
and eax, ebp
or ecx, eax
jne 0x59b9a9
mov ecx, dword [esp + 0xa4]
mov esi, dword [esi]
add ecx, 0x1f0
test esi, esi
je 0x59b914
cmp byte [esi], 0xa7
jne 0x59b8fb
test byte [esi + 4], 0x20
jne 0x59b8fb
push dword [esi + 0x1c]
push ecx
call fcn.005861e0
add esp, 8
mov ebx, eax
mov ebp, edx
jmp 0x59b925
test dword [esi + 4], 0x810000
jne 0x59b914
push esi
push ecx
call fcn.00585ff0
add esp, 8
mov ebx, eax
mov ebp, edx
jmp 0x59b925
xorps xmm0, xmm0
movlpd qword [esp + 0x40], xmm0
mov ebx, dword [esp + 0x40]
mov ebp, dword [esp + 0x44]
mov eax, ebx
or eax, ebp
jne 0x59b979
mov dword [esp + 0x88], fcn.004ec560
mov eax, 1
mov word [esp + 0x98], ax
mov dword [esp + 0x8c], 0x568e20
mov dword [esp + 0x9c], 0
test esi, esi
je 0x59b979
lea eax, [esp + 0x84]
push esi
push eax
call fcn.00581150
add esp, 8
cmp word [esp + 0x98], 0
je 0x59b9a5
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x60]
not ecx
mov edx, dword [esp + 0x14]
not eax
and eax, ebp
and ecx, ebx
or ecx, eax
mov ebp, dword [esp + 0x1c]
jne 0x59b9ad
or edx, edi
or ebp, dword [esp + 0x68]
mov dword [esp + 0x14], edx
mov dword [esp + 0x1c], ebp
jmp 0x59b9ad
mov ebp, dword [esp + 0x1c]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x38]
add dword [esp + 0x28], 0x14
inc eax
mov edi, dword [esp + 0x34]
mov esi, dword [esp + 0x28]
mov dword [esp + 0x38], eax
cmp eax, edi
jl 0x59b8a0
mov ecx, dword [esp + 0x24]
jmp 0x59b9e1
mov ecx, dword [esp + 0x24]
mov ebp, dword [esp + 0x1c]
mov edi, dword [esp + 0x34]
mov edx, dword [esp + 0x14]
mov ebx, dword [esp + 0x18]
mov esi, dword [esp + 0x64]
inc esi
mov dword [esp + 0x64], esi
test bl, bl
jne 0x59b200
mov eax, dword [esp + 0x74]
cmp edx, dword [esp + 0x78]
jne 0x59ba25
cmp ebp, eax
jne 0x59ba25
mov al, byte [esp + 0x7c]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x90
ret
cmp byte [esi + 0x20], 0
je 0x59ba25
and eax, 0x280
cmp eax, 0x80
jne 0x59ba04
test bl, bl
jne 0x59ba9b
lea ebx, [edi - 1]
test ebx, ebx
jle 0x59ba81
mov edi, dword [esp + 0x14]
cmp ebx, 0x40
jge 0x59ba58
xor ecx, ecx
xor edx, edx
mov eax, ebx
bts ecx, eax
cmp eax, 0x20
cmovae edx, ecx
xor ecx, edx
cmp eax, 0x40
cmovae edx, ecx
add ecx, 0xffffffff
adc edx, 0xffffffff
jmp 0x59ba6c
xorps xmm0, xmm0
movlpd qword [esp + 0x7c], xmm0
mov edx, dword [esp + 0x80]
mov ecx, dword [esp + 0x7c]
mov eax, ecx
mov esi, edx
and eax, edi
and esi, ebp
cmp eax, ecx
jne 0x59ba7c
cmp esi, edx
je 0x59ba8e
dec ebx
test ebx, ebx
jg 0x59ba34
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x90
ret
pop edi
pop esi
pop ebp
mov al, bl
pop ebx
add esp, 0x90
ret
pop edi
pop esi
pop ebp
or al, 0xff
pop ebx
add esp, 0x90
ret