Difference between revisions of "LlGetParcelMaxPrims"

From Second Life Wiki
Jump to navigation Jump to search
m
 
(16 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{LSL_Function
{{LSL_Function
|inject-2=
{{LSL_Function/boolean|sim_wide|td=treats all parcels owned by this parcel owner in the sim in a single maximum|fd=determines the max for the specified parcel}}
{{LSL_Function/position|pos|region=noZ}}
|func_id=326|func_sleep=0.0|func_energy=10.0
|func_id=326|func_sleep=0.0|func_energy=10.0
|func=llGetParcelMaxPrims|return_type=integer|p1_type=vector|p1_name=pos|p1_desc=[[Viewer coordinate frames#Region|region coordinate]]
|func=llGetParcelMaxPrims
|p2_type=integer|p2_name=sim_wide|p2_desc=boolean, {{LSLG|FALSE}} for the parcel, otherwise for the [[sim]].
|return_type=integer
|p1_type=vector|p1_name=pos
|p2_type=integer|p2_subtype=boolean|p2_name=sim_wide
|func_footnote
|func_footnote
|func_desc
|func_desc
|return_text=that is the maximum number of prims allowed on the parcel at '''pos'''.
|return_text=that is the maximum combined [http://community.secondlife.com/t5/English-Knowledge-Base/Calculating-land-impact/ta-p/974163 land impact] allowed for objects on the parcel at {{LSLP|pos}}.
|spec
|spec=If {{LSLP|sim_wide}} is...
|caveats
*{{#var:FALSE}} then the return is the maximum land impact supported by the parcel.
*''not'' {{#var:FALSE}} then the return is the total land impact supported by all land in the region owned by the parcel owner.
|caveats=
*If there is an Object Bonus for the region, the value returned may be more than the region's total limit.
|constants
|constants
|examples
|examples=
<source lang="lsl2">default
{
    touch_start(integer total_number)
    {
        llSay(0, "The total land impact of objects rezzed on this parcel is "
            +(string)llGetParcelPrimCount(llGetPos(), PARCEL_COUNT_TOTAL, FALSE) +", of "
            +(string)llGetParcelMaxPrims(llGetPos(), FALSE) + " allowed.");
    }
}</source>
|helpers
|helpers
|also_functions
|also_functions=
{{LSL DefineRow||[[llGetParcelPrimCount]]}}
|also_events
|also_events
|also_tests
|also_tests
|also_articles
|also_articles
|notes
|notes
|permission
|negative_index
|sort=GetParcelMaxPrims
|cat1=Parcel
|cat1=Parcel
|cat2
|cat2=Region
|cat3
|cat3
|cat4
|cat4
}}
}}

Latest revision as of 06:56, 1 November 2016

Summary

Function: integer llGetParcelMaxPrims( vector pos, integer sim_wide );

Returns an integer that is the maximum combined land impact allowed for objects on the parcel at pos.

• vector pos position in region coordinates (z component is ignored)
• integer sim_wide TRUE treats all parcels owned by this parcel owner in the sim in a single maximum, FALSE determines the max for the specified parcel

Specification

If sim_wide is...

  • FALSE then the return is the maximum land impact supported by the parcel.
  • not FALSE then the return is the total land impact supported by all land in the region owned by the parcel owner.

Caveats

  • If there is an Object Bonus for the region, the value returned may be more than the region's total limit.
All Issues ~ Search JIRA for related Bugs

Examples

default
{
    touch_start(integer total_number)
    {
        llSay(0, "The total land impact of objects rezzed on this parcel is "
             +(string)llGetParcelPrimCount(llGetPos(), PARCEL_COUNT_TOTAL, FALSE) +", of "
             +(string)llGetParcelMaxPrims(llGetPos(), FALSE) + " allowed.");
    }
}

See Also

Functions

•  llGetParcelPrimCount

Deep Notes

Search JIRA for related Issues

Signature

function integer llGetParcelMaxPrims( vector pos, integer sim_wide );