Function at 0x43939c
Capabilities:
Generate random numbers using a mersenne twister

Disassembly:
sub dword [0x4bd3b0], edx
jne 0x4393a9
call fcn.00411f30
mov ecx, dword [0x4bfc68]
mov eax, dword [ecx]
add ecx, 4
mov dword [0x4bfc68], ecx
mov ecx, eax
shr ecx, 0xb
xor eax, ecx
mov edx, eax
and edx, 0xff3a58ad
shl edx, 7
xor eax, edx
mov ecx, eax
and ecx, 0xffffdf8c
shl ecx, 0xf
xor eax, ecx
mov edx, eax
shr edx, 0x12
xor edx, eax
shr edx, 1
mov dword [esi + 4], edx
cmp dword [0x4bfb24], 0
je 0x439401
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x20]
push 0x438db0
push eax
push ecx
jmp 0x439435
cmp byte [esp + 0x13], 0
je 0x439419
mov edx, dword [esp + 0x28]
cmp byte [esp + 0x18], 0
mov eax, 0x438d00
jne 0x43942a
mov eax, 0x438b90
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x20]
push eax
push ecx
push edx
push ebx
call fcn.00482c80
mov ecx, dword [esp + 0x2c]
mov al, byte [ecx + 0x17]
mov ebx, dword [esp + 0x40]
add esp, 0x10
mov dword [esp + 0x30], ebx
test al, al
jne 0x439462
mov ecx, dword [ecx + 0xc]
push 1
push 0
push ebx
push 0
call fcn.004698a0
jmp 0x4394d4
mov byte [esp + 0x13], 1
mov dl, 1
cmp ebx, 0xffffffff
jne 0x43947e
mov dword [esp + 0x30], 0
mov ebx, dword [esp + 0x30]
xor dl, dl
jmp 0x439483
mov byte [esp + 0x13], 0
lea ecx, [ebx + 1]
lea edi, [ecx + ecx]
cmp al, 2
jne 0x4394b6
cmp byte [esp + 0x13], 0
je 0x4394a2
push 0x4a5c64
mov eax, ebx
call fcn.00403c20
jmp 0x4394d4
mov edi, ecx
mov esi, 0x4c2fe4
call fcn.00403ca0
neg eax
sbb eax, eax
neg eax
jmp 0x4394d4
mov esi, dword [0x4bd3c8]
cmp edi, esi
jbe 0x4394e6
push 0x4a5c64
push str.Memory_limit_reached__see_MaxMem_in_the_help_file_.__The_current_thread_will_exit.
mov ecx, 0x4c3000
call fcn.0042b900
cmp eax, 1
je 0x439504
mov dword [esp + 0x20], 0
jmp 0x4399df
cmp ecx, 2
jae 0x439590
xor ecx, ecx
test dl, dl
setne cl
xor al, al
lea edi, [ecx + 3]
mov ecx, dword [esp + 0x1c]
call fcn.00469d70
mov ecx, dword [esp + 0x1c]
mov al, byte [ecx + 0x15]
test al, 2
je 0x4395b4
and al, 0x3d
mov byte [ecx + 0x15], al
mov eax, dword [ecx]
mov edx, dword [eax]
push eax
mov eax, dword [edx + 8]
call eax
mov esi, dword [0x4bd3c8]
mov ecx, dword [esp + 0x1c]
mov edx, dword [ecx + 0x10]
and byte [ecx + 0x15], 0x86
cmp edi, edx
jbe 0x4395ee
mov ecx, dword [esp + 0x1c]
mov cl, byte [ecx + 0x14]
cmp cl, 1
jbe 0x43962d
cmp cl, 2
je 0x43966b
mov edi, dword [esp + 0x44]
cmp edi, 0x80
ja 0x43966b
cmp edi, 8
ja 0x439641
mov edi, 8
jmp 0x43964f
mov edx, 0x10
cmp edx, edi
sbb edi, edi
and edi, 0x70
add edi, edx
mov eax, edi
call fcn.00464590
test eax, eax
je 0x4394d9
mov ecx, dword [esp + 0x1c]
mov byte [ecx + 0x14], 1
jmp 0x4395e0
cmp edi, 0x20
jae 0x43967a
mov edi, 0x20
jmp 0x43972a
cmp edi, 0x208
jae 0x43968c
mov edi, 0x208
jmp 0x43972a
cmp edi, 0x50000
jae 0x4396d0
mov dword [esp + 0x3c], edi
fild dword [esp + 0x3c]
test edi, edi
jns 0x4396a6
fadd qword [0x4b7850]
fmul qword [0x4b78a0]
fnstcw word [esp + 0x18]
movzx eax, word [esp + 0x18]
or eax, 0xc00
mov dword [esp + 0x3c], eax
fldcw word [esp + 0x3c]
cmp al, 0xdf
jl 0x4396e9
pop eax
mov edi, dword [esp + 0x58]
fldcw word [esp + 0x18]
jmp 0x43972a
cmp edi, 0x320000
jae 0x4396e0
add edi, 0x8000
jmp 0x43972a
cmp edi, 0xc80000
jae 0x439724
mov dword [esp + 0x3c], edi
fild dword [esp + 0x3c]
test edi, edi
jns 0x4396fa
fadd qword [0x4b7850]
fmul qword [0x4b7898]
fnstcw word [esp + 0x18]
movzx eax, word [esp + 0x18]
or eax, 0xc00
mov dword [esp + 0x3c], eax
fldcw word [esp + 0x3c]
fistp qword [esp + 0x58]
and al, 0x58
mov edi, dword [esp + 0x58]
fldcw word [esp + 0x18]
jmp 0x43972a
add edi, 0x20000
cmp edi, esi
jbe 0x439730
mov edi, esi
cmp cl, 2
jne 0x439773
test edx, edx
je 0x439773
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax + 8]
push ecx
mov bl, 1
call fcn.004833c5
add esp, 4
cmp edi, 0x7fffffff
ja 0x439777
push edi
call fcn.00481e64
add esp, 4
test eax, eax
je 0x439777
mov edx, dword [esp + 0x1c]
mov ebx, dword [esp + 0x30]
mov byte [edx + 0x14], 2
mov ecx, edx
jmp 0x4395e0
invalid