Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Exact prim allowance on land?

Yumi Murakami
DoIt!AttachTheEarOfACat!
Join date: 27 Sep 2005
Posts: 6,860
07-27-2006 15:05
Hi,

Could somebody please be so kind as to post the exact formula, as used by the server-side source code, to calculate the number of prims on a parcel of a given size?

Most formulas I have seen, such as those based on proportions (such as 117:512), fail for certain values. (eg, 117:512 fails for 65536; 65536 / 512 = 128, 128 * 117 = 14976, but 65536sqm actually has 15000). Evidently the server must have a formula that never fails - would it be possible for it to be posted?

Thank you,
Yumi.
Andrew Linden
Linden staff
Join date: 18 Nov 2002
Posts: 692
07-27-2006 20:24
The formula is:

prim_limit = integer( parcel_area * region_limit / region_area )

Note that the prim_limit must be a "whole number" so the decimal part of the "real number" inside the parentheses is discarded.