|
Paladin Pinion
The other one of 10
Join date: 3 Aug 2007
Posts: 191
|
03-25-2008 12:09
I am working with a script that rezzes objects and will fail on no-build parcels and those that are too full. I want to detect these conditions and not rez anything if it will error. I believe I can detect no-build land using llGetParcelFlags but I don't see a way to detect if the parcel is full. Will llScriptDanger alert me to both these things?
If not, is there a way to try a rez and catch the error before it is displayed so my script can abort the process? Or a way to turn off error reports to the client?
|
|
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
|
03-25-2008 14:00
|
|
Paladin Pinion
The other one of 10
Join date: 3 Aug 2007
Posts: 191
|
03-25-2008 14:31
Thanks! I have been using the rpstats wiki because it often seems to load faster, and neither of these functions are in there. I guess I'd better change my reference material. Appreciate the info, this solves the problem neatly.
|
|
Paladin Pinion
The other one of 10
Join date: 3 Aug 2007
Posts: 191
|
03-25-2008 16:06
Hit another snag. LlGetParcelFlags only tells me whether anyone can build, but doesn't tell me if the current owner can build. If I use that flag to filter out rezzing, it means that unless the owner is in a sandbox, they can't rez things on their own land. How would I find out if the owner has permission to build?
|
|
Paladin Pinion
The other one of 10
Join date: 3 Aug 2007
Posts: 191
|
03-25-2008 21:30
Re-reading what I just posted, it isn't very clear. The llGetParcelFlags function can tell me if land allows all people to build (such as a sandbox) but I can't find a way to determine if a particular person has a right to build on the particular land they are standing on. For example, the land may have build perms for the group (which the AV may or may not be a member of) but I don't see a way to determine that.
There is also a problem determining whether a parcel is full using the llGetParcelMaxPrims and llGetParcelPrimCount functions. I tested in an area where -- to my surprise -- the allowable prim count was reported to be less than the number of prims that already existed. That doesn't seem very reliable, so that's no good.
The script will be in an attachment and needs to know whether it can rez temporary objects or not. If it tries and fails, the user sees the ugly blue error dialog. What I need is a function that will just return whether rezzing is permited for this particular AV on this particular parcel.
What I'd like even better would be a simpler approach, since the goal is simply to avoid error messages. My preferred options would be:
1. Turn off error dialogs entirely. If an error occurs, just don't allow it to show; have the script fail silently.
2. Have a try/catch construct that would allow the script to attempt an operation and allow a different action or graceful abort if there is an error.
It doesn't look like SL allows either of these. I'm thinking since temp objects don't count against the prim count, I don't need to worry about full parcels. Is that right?
What do any of you do about this? I'm not making a weapon but I imagine the problem is the same if you want to rez, say, bullets from a machine gun. Imagine a stream of those error message appearing before you can turn off the bullets. What would you do?
|
|
Squirrel Wood
Nuteater. Beware!
Join date: 14 Jun 2006
Posts: 471
|
03-26-2008 02:17
have the rezzed object tell your script via a defined channel that it has been rezzed and use a timeout to determine whether it was successfully rezzed or not.
Also, the number of temp prims you can have on a parcel is limited by either one of the following:
half the parcels allowed prim count or 500. whichever is lower.
|
|
Paladin Pinion
The other one of 10
Join date: 3 Aug 2007
Posts: 191
|
03-26-2008 10:46
Thanks for the reply. But when the object is rezzed, there will still be an error dialog if it fails, right? I see how I could use this to stop further rezzing but there would be at least one dialog. Maybe that's the best I can hope for though.
|