Garry's Mod Wiki

Revision Difference

player.GetCount#528527

<function name="GetCount" parent="player" type="libraryfunc"> <description> Gives you the player count. <note>Similar to **#**<page>player.GetAll</page>() but with better performance since the player table doesn't have to be generated. If <page>player.GetAll</page> is already being called for iteration, than using the **#** operator on the table will be faster than calling this function since it is JITted.</note> <note>Similar to **#**<page>player.GetAll</page>() but with better performance since the player table doesn't have to be generated. If <page>player.GetAll</page> is already being called for iteration, then using the **#** operator on the table will be faster than calling this function since it is JITted.</note> </description> <realm>Shared</realm> <rets> <ret name="" type="number">Number of players</ret> </rets> </function>