Function at 0x382870
Capabilities:
Access peb ldr_data
Check for peb beingdebugged flag

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x38fc28
mov eax, dword fs:[0]
push eax
sub esp, 0x58
push edi
mov eax, dword [0x3c508c]
xor eax, esp
push eax
lea eax, [esp + 0x60]
mov dword fs:[0], eax
xor edi, edi
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], 0x3a2420
lea eax, [esp + 0x1c]
mov dword [esp + 0x68], edi
mov edx, dword [ecx + 0x20]
push eax
push edx
call dword [0x39a400]
push 0xff00ff
push 1
push edi
call dword [0x39a034]
push eax
lea ecx, [esp + 0x10]
call fcn.0038b228
mov eax, dword [esp + 0x10]
cmp eax, edi
je 0x3828e6
push eax
mov eax, dword [esi + 4]
push eax
call dword [0x39a054]
push edi
push edi
lea ecx, [esp + 0x1c]
push ecx
mov ecx, esi
call fcn.0038b73e
push edi
push 2
mov ecx, esi
call fcn.0038b744
push 2
push edi
mov ecx, esi
call fcn.0038b744
push edi
push edi
mov ecx, esi
call fcn.0038b744
mov eax, dword [esp + 0x24]
sub eax, dword [esp + 0x1c]
push 0xff00ff
lea edx, [eax - 2]
mov dword [esp + 0x38], eax
lea eax, [esp + 0x30]
push eax
mov ecx, esi
mov dword [esp + 0x34], edx
mov dword [esp + 0x38], edi
mov dword [esp + 0x40], 2
call fcn.0038b570
mov ecx, dword [esp + 0x24]
sub ecx, dword [esp + 0x1c]
push edi
sub ecx, 3
push ecx
lea edx, [esp + 0x1c]
push edx
mov ecx, esi
call fcn.0038b73e
mov eax, dword [esp + 0x24]
sub eax, dword [esp + 0x1c]
push edi
push eax
mov ecx, esi
call fcn.0038b744
mov ecx, dword [esp + 0x24]
sub ecx, dword [esp + 0x1c]
push edi
dec ecx
push ecx
lea edx, [esp + 0x1c]
push edx
mov ecx, esi
call fcn.0038b73e
mov eax, dword [esp + 0x24]
sub eax, dword [esp + 0x1c]
push 3
dec eax
push eax
mov ecx, esi
call fcn.0038b744
mov eax, dword [esp + 0x28]
sub eax, dword [esp + 0x20]
push 0xff00ff
add eax, 0xfffffffe
lea ecx, [esp + 0x40]
mov dword [esp + 0x44], eax
add eax, 2
push ecx
mov ecx, esi
mov dword [esp + 0x44], edi
mov dword [esp + 0x4c], 2
mov dword [esp + 0x50], eax
call fcn.0038b570
mov edx, dword [esp + 0x28]
sub edx, dword [esp + 0x20]
lea eax, [esp + 0x14]
sub edx, 3
push edx
push edi
push eax
mov ecx, esi
call fcn.0038b73e
mov ecx, dword [esp + 0x28]
sub ecx, dword [esp + 0x20]
dec ecx
push ecx
push edi
mov ecx, esi
call fcn.0038b744
mov edx, dword [esp + 0x28]
sub edx, dword [esp + 0x20]
mov ecx, esi
dec edx
push edx
push 3
call fcn.0038b744
mov eax, dword [esp + 0x28]
sub eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
sub ecx, dword [esp + 0x1c]
add eax, 0xfffffffe
add ecx, 0xfffffffe
mov dword [esp + 0x50], eax
add eax, 2
mov dword [esp + 0x4c], ecx
add ecx, 2
mov dword [esp + 0x58], eax
push 0xff00ff
lea eax, [esp + 0x50]
mov dword [esp + 0x58], ecx
push eax
mov ecx, esi
call fcn.0038b570
mov ecx, dword [esp + 0x28]
sub ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
sub edx, dword [esp + 0x1c]
dec ecx
push ecx
sub edx, 3
push edx
lea eax, [esp + 0x1c]
push eax
mov ecx, esi
call fcn.0038b73e
mov ecx, dword [esp + 0x28]
sub ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
sub edx, dword [esp + 0x1c]
dec ecx
push ecx
push edx
mov ecx, esi
call fcn.0038b744
mov eax, dword [esp + 0x28]
sub eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
sub ecx, dword [esp + 0x1c]
dec eax
push eax
dec ecx
push ecx
lea edx, [esp + 0x1c]
push edx
mov ecx, esi
call fcn.0038b73e
mov eax, dword [esp + 0x28]
sub eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
sub ecx, dword [esp + 0x1c]
sub eax, 4
dec ecx
push eax
push ecx
mov ecx, esi
call fcn.0038b744
mov dword [esp + 0x68], 0xffffffff
lea ecx, [esp + 0xc]
mov dword [esp + 0xc], 0x3a2420
call fcn.00312180
mov ecx, dword [esp + 0x60]
mov dword fs:[0], ecx
pop ecx
pop edi
mov esp, ebp
pop ebp
ret