How many players are present. Deliberately not getPlayers().length: it reads the
tracked size directly instead of building a payload per player, so it stays cheap for
per-frame checks like capacity gates. Counts the local player on a client, same as
getPlayers.
Because of that it reflects the last settled tick, while getPlayers validates
against live components — so for one frame after an entity disappears this can read one
higher than getPlayers().length. Use getPlayers().length when you need the two to
agree exactly.
How many players are present. Deliberately not
getPlayers().length: it reads the tracked size directly instead of building a payload per player, so it stays cheap for per-frame checks like capacity gates. Counts the local player on a client, same as getPlayers.Because of that it reflects the last settled tick, while getPlayers validates against live components — so for one frame after an entity disappears this can read one higher than
getPlayers().length. UsegetPlayers().lengthwhen you need the two to agree exactly.