Difference between revisions of "LlGetRegionAgentCount"

From Second Life Wiki
Jump to navigation Jump to search
(Clarifying behavior per SVC-6964)
(+related)
Line 19: Line 19:
|helpers
|helpers
|also_functions=
|also_functions=
{{LSL DefineRow||[[llGetAgentList]]}}
{{LSL DefineRow||[[llGetRegionFPS]]}}
{{LSL DefineRow||[[llGetRegionFPS]]}}
{{LSL DefineRow||[[llGetRegionTimeDilation]]}}
{{LSL DefineRow||[[llGetRegionTimeDilation]]}}

Revision as of 00:14, 7 June 2012

Summary

Function: integer llGetRegionAgentCount( );
0.0 Forced Delay
10.0 Energy

Returns an integer that is the number of avatars in the region.

Caveats

  • The value returned by this function is technically the average number of agents who were in the region for the past second, rounded to the nearest integer. This means that there is a slight (<1 second) delay in agent count when an agent enters or exits a region.

Examples

<lsl>//Tell the owner how many avatars are in the region on touch default {

   touch_start(integer count)
   {
       llOwnerSay((string)llGetRegionAgentCount());
   }
}</lsl>

See Also

Deep Notes

History

Signature

function integer llGetRegionAgentCount();