Pool::toArray
JavaScript |
---|
This function converts a pool to an array. If you don't need to create a new array every time, use Pool::toArrayFast.
JavaScript Syntax
Syntax
mp.pool.toArray();
Example
Server-Side
const onlinePlayers = mp.players.toArray(); if(onlinePlayers.every((player) => { return player.isAiming; } )) console.log("Everyone is aiming.");