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

Disassembly:
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x28
cmp dword [0x18007cd08], 0x270
jl 0x18004df24
mov dword [rsp + 0x24], 0
mov esi, dword [rsp + 0x24]
mov ecx, 0x9a586308
call fcn.18002ced0
cmp esi, eax
jge 0x18004dd9d
movsxd rax, dword [rsp + 0x24]
lea rcx, [0x18007db20]
mov esi, dword [rcx + rax*4]
and esi, 0x80000000
mov edi, dword [rsp + 0x24]
mov ecx, 0x9a5863ea
call fcn.18002ced0
add edi, eax
movsxd rax, edi
lea rcx, [0x18007db20]
mov eax, dword [rcx + rax*4]
and eax, 0x7fffffff
or esi, eax
mov dword [rsp + 0x20], esi
mov esi, dword [rsp + 0x24]
mov ecx, 0x9a586266
call fcn.18002ced0
add esi, eax
movsxd rax, esi
lea rcx, [0x18007db20]
mov ecx, dword [rcx + rax*4]
mov esi, dword [rsp + 0x20]
shr esi, 1
mov eax, ecx
xor eax, 0xffffffff
and eax, 0xda2c998b
mov edi, 0xffffffff
xor edi, 0xda2c998b
and ecx, edi
mov edx, esi
xor edx, 0xffffffff
and edx, 0xda2c998b
and esi, edi
or eax, ecx
or edx, esi
xor eax, edx
mov ecx, dword [rsp + 0x20]
and ecx, 1
mov ecx, ecx
lea rdx, [0x18007b540]
xor eax, dword [rdx + rcx*4]
movsxd rcx, dword [rsp + 0x24]
lea rdx, [0x18007db20]
mov dword [rdx + rcx*4], eax
mov eax, dword [rsp + 0x24]
add eax, 0x1635b439
add eax, 1
sub eax, 0x1635b439
mov dword [rsp + 0x24], eax
jmp 0x18004dcc0
jmp 0x18004dd9f
mov esi, dword [rsp + 0x24]
mov ecx, 0x9a586184
call fcn.18002ced0
cmp esi, eax
jge 0x18004de95
movsxd rax, dword [rsp + 0x24]
lea rcx, [0x18007db20]
mov esi, dword [rcx + rax*4]
mov ecx, 0x1a5863eb
call fcn.18002ced0
and esi, eax
mov eax, dword [rsp + 0x24]
sub eax, 0xd0e30ba2
add eax, 1
add eax, 0xd0e30ba2
cdqe
lea rcx, [0x18007db20]
mov ecx, dword [rcx + rax*4]
call fcn.180011790
mov ecx, 0xffffffff
xor ecx, 0x7fffffff
mov edi, 0xffffffff
xor edi, 0x43c9199c
or eax, ecx
or edi, 0x43c9199c
mov ecx, eax
call fcn.180011790
and eax, edi
or esi, eax
mov dword [rsp + 0x20], esi
mov eax, dword [rsp + 0x24]
add eax, 0xffffff1d
cdqe
lea rcx, [0x18007db20]
mov esi, dword [rcx + rax*4]
mov eax, dword [rsp + 0x20]
shr eax, 1
xor esi, eax
mov ecx, dword [rsp + 0x20]
call fcn.180011790
mov ecx, 0xffffffff
xor ecx, 1
mov edi, 0xffffffff
xor edi, 0xb366e81a
or eax, ecx
or edi, 0xb366e81a
mov ecx, eax
call fcn.180011790
and eax, edi
mov eax, eax
lea rcx, [0x18007b540]
xor esi, dword [rcx + rax*4]
movsxd rax, dword [rsp + 0x24]
lea rcx, [0x18007db20]
mov dword [rcx + rax*4], esi
mov eax, dword [rsp + 0x24]
add eax, 1
mov dword [rsp + 0x24], eax
jmp 0x18004dd9f
mov esi, dword [0x18007e4dc]
and esi, 0x80000000
mov edi, dword [0x18007db20]
mov ecx, 0xe5a79c14
call fcn.18002ced0
and edi, eax
or esi, edi
mov dword [rsp + 0x20], esi
mov esi, dword [0x18007e150]
mov edi, dword [rsp + 0x20]
mov ecx, 0x9a5863ea
call fcn.18002ced0
mov ecx, eax
shr edi, cl
xor esi, edi
mov eax, dword [rsp + 0x20]
and eax, 1
mov eax, eax
lea rcx, [0x18007b540]
mov ebx, dword [rcx + rax*4]
mov ecx, esi
call fcn.180011790
mov edi, eax
and edi, 0xc02e1467
mov ebp, 0xffffffff
xor ebp, 0xc02e1467
and esi, ebp
mov ecx, ebx
xor ecx, 0xffffffff
call fcn.18000c310
and ebx, ebp
or edi, esi
or eax, ebx
xor edi, eax
mov dword [0x18007e4dc], edi
mov dword [0x18007cd08], 0
mov esi, dword [0x18007cd08]
mov ecx, 0x9a5863ea
call fcn.18002ced0
mov ecx, esi
add ecx, eax
mov dword [0x18007cd08], ecx
movsxd rax, esi
lea rcx, [0x18007db20]
mov eax, dword [rcx + rax*4]
mov dword [rsp + 0x20], eax
mov edi, dword [rsp + 0x20]
mov ecx, 0x9a5863e0
call fcn.18002ced0
mov ecx, eax
shr edi, cl
mov esi, dword [rsp + 0x20]
mov ecx, esi
call fcn.180011790
mov ecx, edi
and ecx, eax
xor edi, 0xffffffff
and esi, edi
or ecx, esi
mov dword [rsp + 0x20], ecx
mov eax, dword [rsp + 0x20]
shl eax, 7
and eax, 0x9d2c5680
xor eax, dword [rsp + 0x20]
mov dword [rsp + 0x20], eax
mov eax, dword [rsp + 0x20]
shl eax, 0xf
and eax, 0xefc60000
mov ecx, dword [rsp + 0x20]
mov edx, ecx
xor edx, 0xffffffff
mov ebp, eax
and ebp, edx
xor eax, 0xffffffff
and ecx, eax
or ebp, ecx
mov dword [rsp + 0x20], ebp
mov eax, dword [rsp + 0x20]
shr eax, 0x12
xor eax, dword [rsp + 0x20]
mov dword [rsp + 0x20], eax
mov eax, dword [rsp + 0x20]
add rsp, 0x28
pop rbx
pop rbp
pop rdi
pop rsi
ret