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

Disassembly:
mov ecx, dword [0x6b21fc]
mov ecx, dword fs:[ecx]
mov ecx, dword [ecx]
mov eax, esp
sub eax, 0x4140
jb 0x50ea47
cmp eax, dword [ecx + 8]
jbe 0x50ea47
sub esp, 0x41c0
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], 0
mov eax, dword [esp + 0x4218]
mov dword [esp], eax
call fcn.00409b00
mov eax, dword [esp + 4]
lea ecx, [0x52aa00]
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], eax
lea eax, [0x547b3d]
mov dword [esp], eax
mov dword [esp + 4], 0xc
lea eax, [esp + 0x68]
mov dword [esp + 8], eax
mov dword [esp + 0xc], 1
mov dword [esp + 0x10], 1
call fcn.004a4980
mov eax, dword [esp + 0x14]
mov dword [esp + 0x44], eax
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x20], ecx
lea edx, [0x52bee0]
mov dword [esp], edx
mov edx, dword [esp + 0x421c]
mov dword [esp + 4], edx
mov ebx, dword [esp + 0x4220]
mov dword [esp + 8], ebx
call fcn.00409e20
mov eax, dword [esp + 0xc]
test eax, eax
jne 0x50dfbc
mov ecx, dword [esp + 0x20]
mov eax, dword [esp + 0x44]
jmp 0x50dfd0
mov eax, dword [eax + 0x10]
mov ecx, dword [esp + 0x10]
mov dword [esp], ecx
call eax
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
mov dword [esp + 0x20], ecx
mov dword [esp + 0x44], eax
mov edx, dword [esp + 0x421c]
mov dword [esp], edx
mov edx, dword [esp + 0x4220]
mov dword [esp + 4], edx
call fcn.004876c0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
test eax, eax
je 0x50e0f2
mov dword [esp + 0x64], ecx
mov eax, dword [esp + 0x14]
mov dword [esp + 0x60], eax
mov dword [esp + 0x80], 0
mov dword [esp + 0x84], 0
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov ecx, dword [esp + 0x44]
mov dword [esp], ecx
mov ecx, dword [esp + 0x20]
mov dword [esp + 4], ecx
call fcn.00409c10
mov eax, dword [esp + 8]
lea ecx, [0x52a880]
mov dword [esp + 0x80], ecx
mov dword [esp + 0x84], eax
mov eax, dword [esp + 0x60]
test eax, eax
je 0x50e071
mov eax, dword [eax + 4]
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x64]
mov dword [esp + 0x8c], eax
lea eax, [0x54c093]
mov dword [esp], eax
mov dword [esp + 4], 0x18
lea eax, [esp + 0x80]
mov dword [esp + 8], eax
mov dword [esp + 0xc], 2
mov dword [esp + 0x10], 2
call fcn.004a1ec0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x4224], 0
mov dword [esp + 0x4228], 0
mov dword [esp + 0x422c], 0
mov dword [esp + 0x4230], eax
mov dword [esp + 0x4234], ecx
add esp, 0x41c0
ret
mov eax, dword [esp + 0xc]
mov dword [esp + 0x28], eax
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x2c], ecx
mov edx, dword [esp + 8]
mov dword [esp + 0x50], edx
lea ebx, [0x5355e0]
mov dword [esp], ebx
call fcn.0040c3d0
mov eax, dword [esp + 4]
mov ecx, dword [esp + 0x28]
mov dword [eax + 4], ecx
mov edx, dword [esp + 0x2c]
mov dword [eax + 8], edx
mov ebx, dword [0x6b2320]
test ebx, ebx
jne 0x50e13a
mov ebx, dword [esp + 0x50]
jmp 0x50e145
call fcn.00468860
mov ebx, dword [esp + 0x50]
mov dword [edi], ebx
mov dword [eax], ebx
mov dword [eax + 0xc], 0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 0xffffffff
lea ecx, [0x5d4494]
mov dword [esp], ecx
mov dword [esp + 4], eax
call fcn.004e1cb0
mov eax, dword [esp + 0xc]
test eax, eax
jne 0x50e298
movzx edx, byte [esp + 0x41d4]
mov ebx, dword [esp + 8]
test dl, dl
je 0x50e27e
mov dword [esp + 0x48], ebx
mov eax, dword [ebx + 4]
mov dword [esp + 0x40], eax
mov dword [esp + 0x70], 0
mov dword [esp + 0x74], 0
mov dword [esp + 0x78], 0
mov dword [esp + 0x7c], 0
mov ecx, dword [esp + 0x44]
mov dword [esp], ecx
mov edx, dword [esp + 0x20]
mov dword [esp + 4], edx
call fcn.00409c10
mov eax, dword [esp + 8]
lea ecx, [0x52a880]
mov dword [esp + 0x70], ecx
mov dword [esp + 0x74], eax
mov eax, dword [esp + 0x40]
mov dword [esp], eax
call fcn.00409b00
mov eax, dword [esp + 4]
lea ecx, [0x52aa00]
mov dword [esp + 0x78], ecx
mov dword [esp + 0x7c], eax
lea edi, [esp + 0xa8]
xor eax, eax
call fcn.00468aaa
lea eax, [0x50ea60]
mov dword [esp + 0xa8], eax
mov dword [esp + 0xb0], 0x15
lea eax, [0x54aa9b]
mov dword [esp + 0xac], eax
mov dword [esp + 0xb8], 2
mov dword [esp + 0xbc], 2
lea eax, [esp + 0x70]
mov dword [esp + 0xb4], eax
mov eax, dword [0x68b9c4]
mov dword [esp], eax
mov dword [esp + 4], 0
mov dword [esp + 8], 2
lea eax, [esp + 0xa8]
mov dword [esp + 0xc], eax
call fcn.004b1180
mov ebx, dword [esp + 0x48]
mov edx, dword [ebx]
mov dword [esp + 0x5c], edx
mov ebx, dword [ebx + 4]
mov dword [esp + 0x40], ebx
xor eax, eax
xor ecx, ecx
xor ebp, ebp
xor esi, esi
jmp 0x50e6b4
lea edi, [esp + 0x2140]
mov ecx, 0x410
xor eax, eax
rep stosd dword es:[edi], eax
mov edx, dword [esp + 0x44]
mov dword [esp + 0x2140], edx
mov edx, dword [esp + 0x20]
mov dword [esp + 0x2144], edx
lea edi, [esp + 0x2148]
lea esi, [esp + 0x41c4]
call fcn.00468eee
lea edi, [esp + 0xc0]
lea esi, [esp + 0x2140]
mov ecx, 0x410
rep movsd dword es:[edi], dword [esi]
mov edx, dword [esp + 0x41dc]
mov ebx, dword [esp + 0x41e0]
lea ebp, [esp + 0xc0]
mov dword [esp], ebp
mov dword [esp + 4], edx
mov dword [esp + 8], ebx
call fcn.004edcf0
mov edx, dword [esp + 0xc]
mov ebx, dword [esp + 0x10]
test edx, edx
je 0x50e411
mov dword [esp + 0x64], ebx
mov eax, dword [esp + 0xc]
mov dword [esp + 0x60], eax
mov dword [esp + 0x80], 0
mov dword [esp + 0x84], 0
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov ecx, dword [esp + 0x41dc]
mov edx, dword [esp + 0x41e0]
mov dword [esp], ecx
mov dword [esp + 4], edx
call fcn.00409c10
mov eax, dword [esp + 8]
lea ecx, [0x52a880]
mov dword [esp + 0x80], ecx
mov dword [esp + 0x84], eax
mov eax, dword [esp + 0x60]
test eax, eax
je 0x50e390
mov eax, dword [eax + 4]
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x64]
mov dword [esp + 0x8c], eax
lea eax, [0x550f42]
mov dword [esp], eax
mov dword [esp + 4], 0x27
lea eax, [esp + 0x80]
mov dword [esp + 8], eax
mov dword [esp + 0xc], 2
mov dword [esp + 0x10], 2
call fcn.004a1ec0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x4224], 0
mov dword [esp + 0x4228], 0
mov dword [esp + 0x422c], 0
mov dword [esp + 0x4230], eax
mov dword [esp + 0x4234], ecx
add esp, 0x41c0
ret
lea eax, [0x5355e0]
mov dword [esp], eax
call fcn.0040c3d0
mov eax, dword [esp + 4]
mov ecx, dword [esp + 0x28]
mov dword [eax + 4], ecx
mov ecx, dword [esp + 0x2c]
mov dword [eax + 8], ecx
mov ecx, dword [0x6b2320]
test ecx, ecx
jne 0x50e441
mov ecx, dword [esp + 0x50]
jmp 0x50e44c
call fcn.00468860
mov ecx, dword [esp + 0x50]
mov dword [edi], ecx
mov dword [eax], ecx
mov dword [eax + 0xc], 0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 0xffffffff
lea ecx, [0x5d4494]
mov dword [esp], ecx
mov dword [esp + 4], eax
call fcn.004db1b0
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0xc]
mov edx, dword [esp + 0x18]
mov ebx, dword [esp + 0x18]
mov ebp, dword [esp + 0x1c]
mov dword [esp + 0x11c], eax
mov dword [esp + 0x120], ecx
test edx, edx
je 0x50e52a
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], 0
test ebx, ebx
je 0x50e4b6
mov ebx, dword [ebx + 4]
mov dword [esp + 0x68], ebx
mov dword [esp + 0x6c], ebp
lea eax, [0x54b9ad]
mov dword [esp], eax
mov dword [esp + 4], 0x17
lea eax, [esp + 0x68]
mov dword [esp + 8], eax
mov dword [esp + 0xc], 1
mov dword [esp + 0x10], 1
call fcn.004a1ec0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x4224], 0
mov dword [esp + 0x4228], 0
mov dword [esp + 0x422c], 0
mov dword [esp + 0x4230], eax
mov dword [esp + 0x4234], ecx
add esp, 0x41c0
ret
lea eax, [esp + 0xc0]
mov dword [esp], eax
call fcn.004ee220
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
test eax, eax
je 0x50e5d8
mov eax, dword [esp + 4]
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], 0
test eax, eax
je 0x50e564
mov eax, dword [eax + 4]
mov dword [esp + 0x68], eax
mov dword [esp + 0x6c], ecx
lea eax, [0x54cec7]
mov dword [esp], eax
mov dword [esp + 4], 0x1a
lea eax, [esp + 0x68]
mov dword [esp + 8], eax
mov dword [esp + 0xc], 1
mov dword [esp + 0x10], 1
call fcn.004a1ec0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x4224], 0
mov dword [esp + 0x4228], 0
mov dword [esp + 0x422c], 0
mov dword [esp + 0x4230], eax
mov dword [esp + 0x4234], ecx
add esp, 0x41c0
ret
mov dword [esp], 0
mov dword [esp + 4], 1
mov dword [esp + 8], 0
mov dword [esp + 0xc], 1
lea eax, [0x53f920]
mov dword [esp + 0x10], eax
call fcn.0044f350
mov eax, dword [0x6b2320]
mov edi, dword [esp + 0x14]
mov dword [esp + 0x58], edi
mov ecx, dword [esp + 0x1c]
test eax, eax
je 0x50e645
mov dword [esp + 0x40], ecx
lea eax, [0x53f920]
mov dword [esp], eax
mov dword [esp + 4], edi
lea eax, [esp + 0xc0]
mov dword [esp + 8], eax
call fcn.004111d0
mov ecx, dword [esp + 0x40]
mov edi, dword [esp + 0x58]
lea esi, [esp + 0xc0]
mov eax, ecx
mov ecx, 0x410
rep movsd dword es:[edi], dword [esi]
mov edx, dword [esp + 0x58]
mov dword [esp + 0x4224], edx
mov dword [esp + 0x4228], 1
mov dword [esp + 0x422c], eax
mov dword [esp + 0x4230], 0
mov dword [esp + 0x4234], 0
add esp, 0x41c0
ret
lea esi, [esp + 0x1100]
mov eax, ecx
mov ecx, 0x410
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [esp + 0x24]
inc ecx
mov ebx, dword [esp + 0x40]
mov esi, edx
mov edx, dword [esp + 0x5c]
mov edi, eax
mov eax, ecx
mov ecx, edi
cmp eax, ebx
jge 0x50ea15
mov dword [esp + 0x24], eax
mov dword [esp + 0x58], ebp
mov dword [esp + 0x3c], esi
mov dword [esp + 0x38], ecx
mov ebx, dword [edx + eax*4]
lea edi, [esp + 0x3180]
mov ecx, 0x410
xor eax, eax
rep stosd dword es:[edi], eax
mov edx, dword [esp + 0x44]
mov dword [esp + 0x3180], edx
mov edx, dword [esp + 0x20]
mov dword [esp + 0x3184], edx
lea edi, [esp + 0x3188]
lea esi, [esp + 0x41c4]
call fcn.00468eee
lea edx, [0x5d4964]
mov dword [esp + 0x31dc], edx
mov dword [esp + 0x31e0], ebx
lea edi, [esp + 0x1100]
lea esi, [esp + 0x3180]
mov ecx, 0x410
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [esp + 0x41dc]
mov esi, dword [esp + 0x41e0]
lea edx, [esp + 0x1100]
mov dword [esp], edx
mov dword [esp + 4], ecx
mov dword [esp + 8], esi
call fcn.004edcf0
mov edx, dword [esp + 0xc]
mov ebx, dword [esp + 0x10]
test edx, edx
jne 0x50e91f
lea eax, [esp + 0x1100]
mov dword [esp], eax
call fcn.004ee220
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
test eax, eax
jne 0x50e829
mov edx, dword [esp + 0x3c]
inc edx
mov ebx, dword [esp + 0x38]
cmp ebx, edx
jb 0x50e79a
mov ebp, dword [esp + 0x58]
mov ecx, ebx
jmp 0x50e7cc
mov eax, dword [esp + 0x58]
mov dword [esp], eax
mov dword [esp + 4], edx
mov dword [esp + 8], ebx
mov dword [esp + 0xc], 1
lea eax, [0x53f920]
mov dword [esp + 0x10], eax
call fcn.0044f350
mov ebp, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
mov ebx, dword [0x6b2320]
imul eax, edx, 0x1040
lea edi, [eax + ebp - 0x1040]
test ebx, ebx
je 0x50e68f
mov dword [esp + 0x54], ebp
mov dword [esp + 0x34], edx
mov dword [esp + 0x30], ecx
mov dword [esp + 0x58], edi
lea eax, [0x53f920]
mov dword [esp], eax
mov dword [esp + 4], edi
lea eax, [esp + 0x1100]
mov dword [esp + 8], eax
call fcn.004111d0
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x34]
mov ebp, dword [esp + 0x54]
mov edi, dword [esp + 0x58]
jmp 0x50e68f
mov dword [esp + 0x4c], ecx
mov ecx, dword [esp + 4]
mov dword [esp + 0x60], ecx
lea edi, [esp + 0x90]
xor eax, eax
call fcn.00468aaa
mov ecx, dword [esp + 0x44]
mov dword [esp], ecx
mov ecx, dword [esp + 0x20]
mov dword [esp + 4], ecx
call fcn.00409c10
mov ecx, dword [esp + 8]
lea edx, [0x52a880]
mov dword [esp + 0x90], edx
mov dword [esp + 0x94], ecx
mov ecx, dword [esp + 0x24]
mov dword [esp], ecx
call fcn.00409b00
mov ecx, dword [esp + 4]
lea edx, [0x52aa00]
mov dword [esp + 0x98], edx
mov dword [esp + 0x9c], ecx
mov ecx, dword [esp + 0x60]
test ecx, ecx
je 0x50e89e
mov ecx, dword [ecx + 4]
mov dword [esp + 0xa0], ecx
mov eax, dword [esp + 0x4c]
mov dword [esp + 0xa4], eax
lea eax, [0x550b50]
mov dword [esp], eax
mov dword [esp + 4], 0x26
lea eax, [esp + 0x90]
mov dword [esp + 8], eax
mov dword [esp + 0xc], 3
mov dword [esp + 0x10], 3
call fcn.004a1ec0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x4224], 0
mov dword [esp + 0x4228], 0
mov dword [esp + 0x422c], 0
mov dword [esp + 0x4230], eax
mov dword [esp + 0x4234], ecx
add esp, 0x41c0
ret
mov dword [esp + 0x4c], ebx
mov eax, dword [esp + 0xc]
mov dword [esp + 0x60], eax
mov dword [esp + 0x80], 0
mov dword [esp + 0x84], 0
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov ecx, dword [esp + 0x41dc]
mov edx, dword [esp + 0x41e0]
mov dword [esp], ecx
mov dword [esp + 4], edx
call fcn.00409c10
mov eax, dword [esp + 8]
lea ecx, [0x52a880]
mov dword [esp + 0x80], ecx
mov dword [esp + 0x84], eax
mov eax, dword [esp + 0x60]
test eax, eax
je 0x50e994
mov eax, dword [eax + 4]
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x8c], eax
lea eax, [0x550f42]
mov dword [esp], eax
mov dword [esp + 4], 0x27
lea eax, [esp + 0x80]
mov dword [esp + 8], eax
mov dword [esp + 0xc], 2
mov dword [esp + 0x10], 2
call fcn.004a1ec0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x4224], 0
mov dword [esp + 0x4228], 0
mov dword [esp + 0x422c], 0
mov dword [esp + 0x4230], eax
mov dword [esp + 0x4234], ecx
add esp, 0x41c0
ret
mov dword [esp + 0x4224], ebp
mov dword [esp + 0x4228], esi
mov dword [esp + 0x422c], ecx
mov dword [esp + 0x4230], 0
mov dword [esp + 0x4234], 0
add esp, 0x41c0
ret
call fcn.00467460
jmp fcn.0050def0