Function at 0x598598
Capabilities:
Access peb ldr_data
Get process heap flags
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
mov ecx, 0xa
push 0
push 0
dec ecx
jne 0x5985a0
push ecx
push ebx
push esi
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.0040452c
mov ebx, 0x668c50
xor eax, eax
push ebp
push 0x59886a
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0xc]
mov edx, dword [ebp - 4]
call fcn.00404174
cmp dword [ebp - 0xc], 0
jne 0x5985f3
lea edx, [ebp - 0x18]
mov eax, dword [0x663c8c]
mov eax, dword [eax]
call fcn.004af6b8
mov eax, dword [ebp - 0x18]
lea edx, [ebp - 0xc]
call fcn.0040c65c
lea eax, [ebp - 0x10]
mov edx, 0x598880
call fcn.00404174
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp - 0x10]
mov edx, dword [ebp - 0xc]
call fcn.004043c4
mov ecx, dword [ebp - 0x1c]
mov dl, 1
mov eax, dword [0x4c228c]
call fcn.004c2334
mov dword [ebp - 8], eax
lea eax, [ebp - 0x14]
mov edx, 0x598898
call fcn.00404174
xor eax, eax
push ebp
push 0x598840
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x5988b0
lea eax, [ebp - 0x20]
push eax
mov ecx, 0x5988c8
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x20]
mov eax, ebx
call fcn.00404130
push 0x5988e0
lea eax, [ebp - 0x24]
push eax
mov ecx, 0x598900
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x24]
lea eax, [ebx + 4]
call fcn.00404130
push 0x598918
lea eax, [ebp - 0x28]
push eax
mov ecx, 0x598940
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x28]
lea eax, [ebx + 8]
call fcn.00404130
push 0x598954
lea eax, [ebp - 0x2c]
push eax
mov ecx, 0x598984
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x2c]
lea eax, [ebx + 0xc]
call fcn.00404130
push 0x5989a0
lea eax, [ebp - 0x30]
push eax
mov ecx, 0x5989d4
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x30]
lea eax, [ebx + 0x10]
call fcn.00404130
push 0x5989f8
lea eax, [ebp - 0x34]
push eax
mov ecx, 0x598a2c
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x34]
lea eax, [ebx + 0x14]
call fcn.00404130
push 0x598a4c
lea eax, [ebp - 0x38]
push eax
mov ecx, 0x598a80
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x38]
lea eax, [ebx + 0x18]
call fcn.00404130
push 0x598a9c
lea eax, [ebp - 0x3c]
push eax
mov ecx, 0x598ac4
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x3c]
lea eax, [ebx + 0x1c]
call fcn.00404130
push 0x598ae4
lea eax, [ebp - 0x40]
push eax
mov ecx, 0x598b0c
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x40]
lea eax, [ebx + 0x20]
call fcn.00404130
push 0x598b2c
lea eax, [ebp - 0x44]
push eax
mov ecx, 0x598b6c
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x44]
lea eax, [ebx + 0x24]
call fcn.00404130
push 0x598b88
lea eax, [ebp - 0x48]
push eax
mov ecx, 0x598bc4
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x48]
lea eax, [ebx + 0x28]
call fcn.00404130
push 0x598bec
lea eax, [ebp - 0x4c]
push eax
mov ecx, 0x598c20
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x4c]
lea eax, [ebx + 0x2c]
call fcn.00404130
push 0x598c44
lea eax, [ebp - 0x50]
push eax
mov ecx, 0x598c78
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x50]
lea eax, [ebx + 0x30]
call fcn.00404130
push 0x598c9c
lea eax, [ebp - 0x54]
push eax
mov ecx, 0x598cd0
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 8]
mov esi, dword [eax]
call dword [esi]
mov edx, dword [ebp - 0x54]
lea eax, [ebx + 0x34]
call fcn.00404130
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x598847
cmp dword [ebp - 8], 0
je 0x59883f
mov eax, dword [ebp - 8]
call fcn.004032b4
ret