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

Disassembly:
sub esp, 0x380
mov eax, dword [0x1013567c]
xor eax, esp
mov dword [esp + 0x37c], eax
push ebx
push ebp
push esi
mov esi, dword [esp + 0x390]
mov dword [esp + 0x20], 0
mov dword [esp + 0x3c], 0
push edi
mov ecx, dword [esi + 0x1c]
mov ebx, dword [esi + 8]
mov ebp, dword [esi + 4]
mov dword [esi], 0
mov dword [ecx + 4], 0
mov eax, dword [esi + 0x1c]
mov dword [esp + 0x48], esi
mov dword [esp + 0x3c], 0
mov dword [esp + 0x1c], 0
mov dword [eax + 8], 0
mov eax, dword [esi + 0x1c]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x44], 0xffffffff
mov dword [esp + 0x30], ecx
mov dword [eax + 0xc], 0
xor eax, eax
mov word [esp + 0x108], ax
cmp dword [ecx], 1
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x2c], 0
jae 0x1003929b
xor edi, edi
jmp 0x10039950
push 1
push 0x82
lea eax, [esp + 0x8c]
push eax
push dword [esi + 0xc]
push ebp
call fcn.1003c530
mov edi, eax
test edi, edi
js 0x10039924
push 3
push 0x80
push 0
lea eax, [esp + 0x1c]
push eax
push 0x1c
lea eax, [esp + 0x64]
push eax
push 0
push 0
lea eax, [esp + 0xa4]
push eax
push 0x10002410
push ebx
push ebp
call fcn.1002cb20
mov edi, eax
test edi, edi
js 0x10039924
push 0
push 0
push dword [esp + 0x5c]
lea eax, [esp + 0x90]
push ebp
mov dword [esi + 0x20], eax
call fcn.1003c730
mov edi, eax
test edi, edi
jne 0x1003974c
mov ecx, dword [esp + 0x30]
add ecx, 8
mov dword [esp + 0x38], ecx
push 0
push 0
lea eax, [esp + 0x18]
push eax
push 0x200
lea eax, [esp + 0x19c]
push eax
push dword [esp + 0x74]
push dword [esp + 0x6c]
push ebp
call fcn.1003cac0
mov edi, eax
test edi, edi
jne 0x10039748
test byte [esp + 0x18c], 1
je 0x10039730
push eax
push eax
lea eax, [esp + 0x18]
push eax
push 0x200
lea eax, [esp + 0x19c]
push eax
push dword [esp + 0x70]
push dword [esp + 0x6c]
push ebp
call fcn.1003cac0
mov edi, eax
test edi, edi
jne 0x10039748
mov eax, dword [esp + 0x10]
mov ecx, 0x40
shr eax, 1
cmp eax, ecx
cmovb ecx, eax
add ecx, ecx
cmp ecx, 0x200
jae 0x1003996d
xor eax, eax
mov word [esp + ecx + 0x18c], ax
lea eax, [esp + 0x18c]
push 0x10002a24
push eax
call fcn.10115590
add esp, 8
test eax, eax
jne 0x100393cf
lea ebx, [edi + 1]
jmp 0x1003942b
lea eax, [esp + 0x18c]
push 0x10002a40
push eax
call fcn.10115590
add esp, 8
test eax, eax
jne 0x100393ed
lea ebx, [eax + 2]
jmp 0x1003942b
lea eax, [esp + 0x18c]
push 0x10002a80
push eax
call fcn.10115590
add esp, 8
test eax, eax
jne 0x1003940b
lea ebx, [eax + 4]
jmp 0x1003942b
lea eax, [esp + 0x18c]
push 0x10002a94
push eax
call fcn.10115590
add esp, 8
test eax, eax
jne 0x10039730
lea ebx, [eax + 5]
push 0
push 0
lea eax, [esp + 0x18]
push eax
push 0x200
lea eax, [esp + 0x19c]
push eax
push dword [esp + 0x6c]
push dword [esp + 0x6c]
push ebp
call fcn.1003cac0
mov edi, eax
test edi, edi
jne 0x10039748
mov eax, dword [esp + 0x10]
mov ecx, 0x40
shr eax, 1
cmp eax, ecx
cmovb ecx, eax
add ecx, ecx
cmp ecx, 0x200
jae 0x1003996d
xor eax, eax
mov word [esp + ecx + 0x18c], ax
lea eax, [esp + 0x108]
push eax
lea eax, [esp + 0x190]
push eax
call fcn.10115590
add esp, 8
test eax, eax
je 0x100395ad
push edi
push 0x18
lea eax, [esp + 0x74]
push eax
lea eax, [esp + 0x198]
push eax
push dword [esi + 0xc]
push ebp
call fcn.1003c3e0
mov edi, eax
cmp edi, 0xfffffa1d
je 0x10039730
test edi, edi
js 0x10039748
cmp dword [esi], 0
jne 0x100394f5
push esi
call fcn.100390e0
mov edi, eax
test edi, edi
js 0x10039924
mov eax, dword [esi]
mov eax, dword [eax + 8]
mov dword [esp + 0x3c], eax
add eax, 0x18
mov dword [esp + 0x1c], eax
mov edi, dword [esp + 0x38]
lea eax, [esp + 0x18c]
inc dword [esp + 0x44]
mov ecx, 0x200
add edi, 0xc
cmp dword [esp + 0x10], ecx
mov dword [esp + 0x38], edi
cmovb ecx, dword [esp + 0x10]
add ecx, 2
push ecx
push eax
lea eax, [esp + 0x110]
push eax
call fcn.10117410
lea eax, [edi - 4]
xorps xmm0, xmm0
movq qword [eax], xmm0
add esp, 0xc
mov dword [eax + 8], 0
mov dword [esp + 0x18], eax
lea eax, [esp + 0x108]
mov dword [esi + 0x24], eax
mov eax, dword [esp + 0x70]
mov dword [edi + 4], eax
lea eax, [esp + 0x24]
push eax
push 0
push 0x34
push dword [esp + 0x48]
call fcn.100c9d55
mov edi, eax
test edi, edi
js 0x10039924
push 0x34
push 0
push dword [esp + 0x2c]
call fcn.101172b0
mov ecx, dword [esp + 0x44]
add esp, 0xc
mov eax, dword [esp + 0x24]
mov dword [ecx], eax
mov eax, dword [esp + 0x24]
mov dword [esi], eax
mov ecx, dword [ecx]
mov eax, dword [esp + 0x3c]
add ecx, 8
mov dword [esp + 0x14], ecx
mov dword [ecx], eax
mov eax, dword [esp + 0x70]
mov dword [ecx + 0x24], eax
mov eax, dword [esp + 0x74]
mov dword [ecx + 0x28], eax
push 0
push 0
lea eax, [esp + 0x18]
push eax
mov eax, dword [esp + 0x28]
push 0xffdc
push dword [eax + 8]
push dword [esp + 0x78]
push dword [esp + 0x6c]
push ebp
call fcn.1003cac0
mov edi, eax
test edi, edi
jne 0x10039748
mov edx, dword [esp + 0x1c]
mov ecx, 0xffdc
cmp dword [esp + 0x10], ecx
cmovb ecx, dword [esp + 0x10]
mov dword [esp + 0x10], ecx
mov eax, dword [edx + 8]
mov byte [ecx + eax + 1], 0
mov ecx, dword [edx + 8]
mov eax, dword [esp + 0x10]
mov byte [eax + ecx], 0
xor ecx, ecx
lea eax, [ebx - 1]
mov dword [esp + 0x40], ecx
cmp eax, 4
ja case.0x10039615.3
jmp dword [eax*4 + 0x10039974]
mov eax, dword [edx + 8]
mov dword [esp + 0x28], eax
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x10]
shr eax, 1
mov dword [esp + 0x34], eax
cmp ebx, 1
jne 0x1003963b
mov dword [esi + 0x2c], ebx
jmp 0x10039672
push 0
push 0
lea eax, [esp + 0x18]
mov dword [esi + 0x2c], 2
push eax
push 4
lea eax, [esp + 0x50]
push eax
push dword [esp + 0x74]
push dword [esp + 0x6c]
push ebp
call fcn.1003cac0
mov edi, eax
test edi, edi
js 0x10039924
mov ecx, dword [esp + 0x40]
mov eax, dword [esp + 0x34]
mov ebx, dword [esp + 0x14]
and ecx, 8
push ecx
push ebx
push eax
push dword [esp + 0x34]
push 0
push esi
call fcn.10039990
mov edi, eax
test edi, edi
js 0x10039924
mov eax, dword [ebx + 0x1c]
mov ebx, dword [esp + 0x18]
or dword [ebx], eax
jmp case.0x10039615.3
mov eax, dword [esp + 0x10]
cmp eax, 4
jne 0x100396b2
mov eax, dword [edx + 8]
cmp dword [eax], ecx
jne 0x100396cd
jmp case.0x10039615.3
cmp eax, 2
jne 0x100396c1
mov eax, dword [edx + 8]
cmp word [eax], cx
jne 0x100396cd
jmp case.0x10039615.3
cmp eax, 1
jne case.0x10039615.3
mov eax, dword [edx + 8]
cmp byte [eax], cl
je case.0x10039615.3
mov ebx, dword [esp + 0x14]
or dword [ebx + 0x1c], 0x4000
mov ebx, dword [esp + 0x18]
or dword [ebx], 0x4001
jmp case.0x10039615.3
mov eax, dword [esp + 0x10]
cmp eax, 4
jne 0x100396f6
mov eax, dword [edx + 8]
cmp dword [eax], ecx
je 0x10039711
jmp case.0x10039615.3
cmp eax, 2
jne 0x10039705
mov eax, dword [edx + 8]
cmp word [eax], cx
je 0x10039711
jmp case.0x10039615.3
cmp eax, 1
jne case.0x10039615.3
mov eax, dword [edx + 8]
cmp byte [eax], cl
jne case.0x10039615.3
mov ebx, dword [esp + 0x14]
or dword [ebx + 0x1c], 0x8000
mov ebx, dword [esp + 0x18]
or dword [ebx], 0x8001
mov eax, dword [esp + 0x24]
mov dword [eax], 1
push 0
push 1
push dword [esp + 0x5c]
push ebp
call fcn.1003c730
mov edi, eax
test edi, edi
je 0x10039321
mov ebx, dword [esp + 0x20]
push dword [esp + 0x54]
push ebp
call fcn.1003bd20
test edi, edi
js 0x10039760
mov edi, eax
test eax, eax
jns 0x1003976c
cmp edi, 0xfffff9bd
jne 0x1003991a
lea eax, [esp + 0x4c]
push eax
lea eax, [esp + 0x20]
push eax
push esi
lea eax, [esp + 0x90]
push eax
push ebx
push ebp
call fcn.10038180
mov edi, eax
cmp edi, 0xfffff1f0
jne 0x1003979b
mov ecx, dword [esp + 0x30]
xor edi, edi
jmp 0x10039912
test edi, edi
js 0x10039924
mov eax, dword [esi]
mov dword [esp + 0x14], 0
mov ecx, dword [eax + 8]
mov eax, dword [esp + 0x1c]
dec eax
mov dword [esp + 0x34], ecx
imul ebx, eax, 0x2c
lea eax, [esp + 0x18]
push eax
push 0
add ebx, 0x34
push ebx
push ecx
call fcn.100c9d55
mov edi, eax
test edi, edi
js 0x10039924
push ebx
push 0
push dword [esp + 0x20]
call fcn.101172b0
mov eax, dword [esp + 0x24]
add esp, 0xc
mov edx, dword [esp + 0x1c]
mov ebx, dword [esp + 0x4c]
mov dword [esi], eax
mov dword [esi + 0x2c], 3
mov dword [eax], edx
mov ebp, dword [esp + 0x18]
add ebp, 8
cmp word [ebx], 0
jne 0x10039839
add ebx, 2
cmp word [ebx], 0
je 0x10039848
mov ecx, ebx
mov dword [esp + 0x2c], ebx
lea eax, [ecx + 2]
mov dword [esp + 0x28], eax
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10039820
sub ecx, dword [esp + 0x28]
sar ecx, 1
lea ebx, [ebx + ecx*2]
add ebx, 2
jmp 0x10039848
or dword [ebp + 0x20], 0x4000
mov dword [esp + 0x2c], 0
mov dword [esi + 0x24], 0
test edx, edx
je 0x100398fc
mov eax, dword [esp + 0x34]
mov esi, ebx
dec edx
mov dword [ebp], eax
mov dword [esp + 0x28], edx
lea ecx, [esi + 2]
jmp 0x10039870
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x10039870
push 1
push ebp
sub esi, ecx
sar esi, 1
push esi
push ebx
push dword [esp + 0x3c]
push dword [esp + 0x5c]
call fcn.10039990
mov edi, eax
test edi, edi
js 0x10039920
cmp dword [esp + 0x14], 0
jne 0x100398b0
test byte [ebp + 0x20], 2
mov dword [esp + 0x14], 0
je 0x100398b8
mov dword [esp + 0x14], 1
mov eax, dword [esp + 0x18]
lea ebx, [ebx + esi*2]
add ebx, 2
add ebp, 0x2c
mov dword [esp + 0x2c], ebx
inc dword [eax + 4]
cmp word [ebx], 0
je 0x100398ec
mov ecx, ebx
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x100398d7
sub ecx, edx
sar ecx, 1
lea ebx, [ebx + ecx*2]
add ebx, 2
mov edx, dword [esp + 0x28]
test edx, edx
jne 0x10039857
mov esi, dword [esp + 0x48]
mov ecx, dword [esp + 0x30]
mov eax, dword [esi]
mov dword [ecx + 8], eax
xor eax, eax
cmp dword [esp + 0x14], eax
setne al
inc eax
mov dword [ecx + 4], eax
mov eax, dword [esp + 0x44]
inc eax
mov dword [ecx + 0xc], eax
test edi, edi
jns 0x10039942
jmp 0x10039924
mov esi, dword [esp + 0x48]
mov eax, dword [esi]
test eax, eax
je 0x10039930
push eax
call fcn.1003a050
mov dword [esi], 0
cmp edi, 0xfffff1ee
je 0x10039294
cmp edi, 0xfffff401
mov eax, 0xfffffc0d
cmove edi, eax
mov ecx, dword [esp + 0x38c]
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.1011705d
add esp, 0x380
ret 4
call fcn.10116cf2
mov edi, edi
sbb al, 0x96
add edx, dword [eax]
sbb al, 0x96
add edx, dword [eax]
xchg edi, eax
add edx, dword [eax]
mov al, byte [0xe4100396]
xchg esi, eax
add edx, dword [eax]
int3