Function at 0x4024ec
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe6c
push ebx
push esi
push edi
mov dword [ebp - 0x100], eax
mov eax, dword [ebp - 0x100]
call fcn.00401780
xor eax, eax
push ebp
push 0x4027dc
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x100]
call fcn.004017e4
mov dword [ebp - 0x124], eax
mov eax, dword [ebp - 0x124]
mov esi, eax
lea edi, [ebp - 0x164]
mov ecx, 0x10
rep movsd dword es:[edi], dword [esi]
mov eax, dword [ebp - 0x124]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x128]
cdq
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
mov esi, eax
lea edi, [ebp - 0xfc]
mov ecx, 0x3e
rep movsd dword es:[edi], dword [esi]
mov eax, dword [ebp - 0x100]
call fcn.00401778
mov ebx, eax
shl ebx, 3
push 0x40
push 0x1000
push ebx
push 0
call sub.kernel32.dll_VirtualAlloc
mov dword [ebp - 4], eax
movzx ebx, word [ebp - 0xf6]
dec ebx
test ebx, ebx
jb 0x40260b
inc ebx
xor esi, esi
mov eax, dword [ebp - 0x124]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x128]
cdq
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
add eax, 0xf8
adc edx, 0
push edx
push eax
mov eax, esi
shl eax, 3
lea eax, [eax + eax*4]
xor edx, edx
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
push esi
mov esi, eax
lea edi, [ebp - 0x18c]
mov ecx, 0xa
rep movsd dword es:[edi], dword [esi]
pop esi
mov eax, dword [ebp - 0x17c]
test eax, eax
jbe 0x402607
mov edx, dword [ebp - 0x124]
add edx, dword [ebp - 0x178]
mov ecx, dword [ebp - 4]
add ecx, dword [ebp - 0x180]
xchg ecx, eax
call fcn.004021f8
inc esi
dec ebx
jne 0x402598
mov eax, dword [ebp - 4]
add eax, dword [ebp - 0x7c]
mov dword [ebp - 0x108], eax
jmp 0x4026c9
add edi, dword [ebp - 4]
push edi
call sub.kernel32.dll_LoadLibraryA
mov esi, eax
cmp esi, 0xffffffff
je 0x4026c2
mov eax, dword [ebp - 0x108]
cmp dword [eax], 0
je 0x40264e
mov eax, dword [ebp - 0x108]
mov eax, dword [eax]
add eax, dword [ebp - 4]
mov dword [ebp - 0x10c], eax
jmp 0x402660
mov eax, dword [ebp - 0x108]
mov eax, dword [eax + 0x10]
add eax, dword [ebp - 4]
mov dword [ebp - 0x10c], eax
mov eax, dword [ebp - 0x108]
mov eax, dword [eax + 0x10]
add eax, dword [ebp - 4]
mov dword [ebp - 0x110], eax
jmp 0x4026b6
test ebx, 0x80000000
je 0x402693
and ebx, 0xffff
push ebx
push esi
call sub.kernel32.dll_GetProcAddress
mov edx, dword [ebp - 0x110]
mov dword [edx], eax
jmp 0x4026a8
add ebx, dword [ebp - 4]
add ebx, 2
push ebx
push esi
call sub.kernel32.dll_GetProcAddress
mov edx, dword [ebp - 0x110]
mov dword [edx], eax
add dword [ebp - 0x10c], 4
add dword [ebp - 0x110], 4
mov eax, dword [ebp - 0x10c]
mov ebx, dword [eax]
test ebx, ebx
jne 0x402674
add dword [ebp - 0x108], 0x14
mov eax, dword [ebp - 0x108]
mov edi, dword [eax + 0xc]
test edi, edi
jne 0x40261c
mov eax, dword [ebp - 4]
add eax, dword [ebp - 0x5c]
mov dword [ebp - 0x114], eax
mov eax, dword [ebp - 0x114]
mov dword [ebp - 0x118], eax
jmp 0x4027a3
mov eax, dword [ebp - 0x118]
mov eax, dword [eax + 4]
sub eax, 8
mov dword [ebp - 0x194], eax
xor eax, eax
mov dword [ebp - 0x190], eax
fild qword [ebp - 0x194]
fdiv dword [0x4027f0]
call fcn.00401390
mov dword [ebp - 0x11c], eax
mov eax, dword [ebp - 0x118]
add eax, 8
mov dword [ebp - 0x120], eax
mov ebx, dword [ebp - 0x11c]
dec ebx
test ebx, ebx
jb 0x40278e
inc ebx
mov eax, dword [ebp - 0x120]
movzx eax, word [eax]
shr eax, 0xc
cmp eax, 3
jne 0x40277c
mov eax, dword [ebp - 0x118]
mov eax, dword [eax]
mov edi, dword [ebp - 4]
add eax, edi
mov edx, dword [ebp - 0x120]
mov dx, word [edx]
and dx, 0xfff
movzx edx, dx
add eax, edx
sub edi, dword [ebp - 0xc8]
add dword [eax], edi
mov eax, dword [ebp - 0x120]
add eax, 2
mov dword [ebp - 0x120], eax
dec ebx
jne 0x402743
mov eax, dword [ebp - 0x118]
mov eax, dword [eax + 4]
add eax, dword [ebp - 0x118]
mov dword [ebp - 0x118], eax
mov eax, dword [ebp - 0x118]
sub eax, dword [ebp - 0x114]
cmp eax, dword [ebp - 0x58]
jb 0x4026f7
mov eax, dword [ebp - 4]
add eax, dword [ebp - 0xd4]
jmp eax