SL Scripter comments, is this accurate

Creating scripts
Jean Swashbuckler
Posts: 39
Joined: Wed Oct 30, 2013 1:23 pm
Has thanked: 62 times
Been thanked: 48 times

Re: SL Scripter comments, is this accurate

Post by Jean Swashbuckler »

Ilan Tochner wrote:An additional optimization would be to ask these people to refrain from rezzing new objects when the world is under heavy use. Building puts some stress on a simulator. Usually it isn't noticeable but if the sim is currently under heavily load then that extra strain can be the difference between a lag-free/low-lag experience and having noticeable lag.
I think I understand but let me be sure with some concrete examples based on SL experience.

- Should we ever have an event or have more than a few avatars on a sim, such as a boat race, then we do not want building go on during that time, correct? Will there be an issue if there are 40 or so people and we need to rezz 10-20 boats? Not thinking we will do this but it is good to know since that is what we used to do in The Blake Sea in SL.

My assumption is that since we have a 16 megaregion, that we think of the above example as the megaregion as one region like in SL. The people could be spread out over the 16 sims but the impact would be on the server and since the server holds all 16, then the impact is server load, not individual sim. In SL sims are distributed across multiple servers. I knew our full sims were on two or three different servers and the homestead grouped with other homesteads on another server. I'm just trying to get a feel for what works and what doesn't.

- If we have less than 5 to 8 people in the megaregion, then they can all be building vs. having 30+ people building. I would not expect us to have a lot of people building at any one time. Again, just trying to get a feel what is the line before we see performance hits. Also know from mainland and private estate in SL that this will vary, sometimes significantly, and that it's just one of those things we all face.

- the last example will probably be the most extreme example. I know we have a max avatar number of 100. We used to set this to 80 on a full sim since the stage was a high prim stage with lots of particle, lighting, etc. effects. We did experience lag..sometimes in the 4-10 fps. That's the SL viewer, not one of the 3rd party viewers. Should we ever have something like this, and we understand there will be lag, is this going to cause an issue?

Thanks for your perspectives.
User avatar
Sherrie Melody
Posts: 273
Joined: Fri Mar 29, 2013 6:56 pm
Has thanked: 201 times
Been thanked: 159 times

Re: SL Scripter comments, is this accurate

Post by Sherrie Melody »

Just a note about the boat script that Minethere posted. As she indicated, it was pulled from a full-perm boat that was out on Osgrid Wright Plaza.

In several places, specific link numbers are hard-coded to be acted on, such as in the SetParticle* functions, some places where specific link numbers are rotated, and a specific link number that receives link messages. From what I could see, the hard-coded link numbers are 10 (link messages) and 23, 27, 29, and 30. There might be more. Those are the ones I saw skimming through. Not sure what the messages to link 10 would have been for, but I'm guessing the SetParticle and link rotations were for the motor that would be at the back of the boat?

I realized this, LOL, when a pillow on my boat started spewing water spray :) and was rotated at one point. It happened to be link 23 in an object of 23 prims. :D

So if you are going to use the script, you'll probably want to modify those hard-coded places to work with the appropriate link numbers, or comment them out if they don't apply to your build.
These users thanked the author Sherrie Melody for the post:
Constance Peregrine
User avatar
Sherrie Melody
Posts: 273
Joined: Fri Mar 29, 2013 6:56 pm
Has thanked: 201 times
Been thanked: 159 times

Re: SL Scripter comments, is this accurate

Post by Sherrie Melody »

Here's the boat I'm working on.
Attachments
Snapshot_003.jpg
Snapshot_002.jpg
These users thanked the author Sherrie Melody for the post:
Boo Rojyo
User avatar
Ilan Tochner
Posts: 6545
Joined: Sun Dec 23, 2012 8:44 am
Has thanked: 5014 times
Been thanked: 4487 times
Contact:

Re: SL Scripter comments, is this accurate

Post by Ilan Tochner »

Hi Jean,

The rezzing of the boats (a one-time operation) probably won't be an issue but the scripts running those boats (which run continuously) may be an issue if they are not well written. A sim can run thousands of scripts and be just fine and it can run just a handful of really badly written scripts and experience lag. Physics based boats will not perform as well as inSL until the BulletSim physics engine replacing the existing ODE one.

Each world gets its own sim but all the regions in a world (regardless of whether it uses Advanced Megaregion mode) all run on that single OpenSim instance. This means that how people are distributed in your world has very little effect on resource usage.

Building is resource intensive as it requires frequent sending of potentially big updates to/from the server to each of the connected viewers and also frequent data persistence. The more things move in the world the more resource intensive this becomes. 8 builders may create more server load than 30 builders, it really depends on how many changes they make to the world and how frequently they make them. As a rule of thumb, the more static things are in the world the less load you'll have. If possible, have people stationary and sitting during the race to minimize the amount of movement that needs to be broadcast to all the viewers.

This is all the same best practices as you have inSL. In Kitely each world can get a lot more server resources than an SL region but their physics engine is currently much better performing than what OpenSim has (ODE).

If you have an event with 80 people inside a sim then after a while our system will make sure that no other worlds remain active on the server hosting your world. This will free up additional server resources to handle your world. However, even with this additional server resource boost your world may still lag if there is a lot of movement inside it (it may be lag free if nothing is moving and everyone just sits on the ground). Other than the lag (which may be severe if your world constantly changes in big ways), I don't expect this will cause issues.

That said, as in SL crashes can still happen sometimes in OpenSim-based grids as well. If it does our on-demand system will set up the world on a newly started sim the next time someone tries to enter it (which I expect people who get logged out due to the crash will quickly do). Our system can take up to a minute to detect the sim crashed and restarting the world on a new sim can take between 20 seconds and a few minutes depending on the world complexity (the less scripts and objects, especially physical ones, need to load the faster the world will start up).
These users thanked the author Ilan Tochner for the post (total 2):
Jean SwashbucklerDundridge Dreadlow
Jean Swashbuckler
Posts: 39
Joined: Wed Oct 30, 2013 1:23 pm
Has thanked: 62 times
Been thanked: 48 times

Re: SL Scripter comments, is this accurate

Post by Jean Swashbuckler »

Excellent Ilan,

That's exactly what I was hoping for. This is very helpful and appreciated. Will be looking forward to reading about Bullet and its debut.
User avatar
Sarge Misfit
Posts: 254
Joined: Thu Mar 14, 2013 4:10 pm
Has thanked: 5 times
Been thanked: 223 times

Re: SL Scripter comments, is this accurate

Post by Sarge Misfit »

Just a note for everyone, we do have the beginnings of a Script Library so feel free to donate any that you know work properly in Kitely. And feel free to use any that are posted. :D
http://www.kitely.com/forums/viewtopic.php?f=26&t=759
These users thanked the author Sarge Misfit for the post (total 3):
Jean SwashbucklerConstance PeregrineMarstol Nitely
Living life on the wrong side of a one-track mind.

National Security Threat Level: Gnat

My site: Excelsior Station
My Kitely World: Misfit's Folly
User avatar
Constance Peregrine
Posts: 2352
Joined: Sun Dec 23, 2012 11:35 am
Has thanked: 2780 times
Been thanked: 1487 times

Re: SL Scripter comments, is this accurate

Post by Constance Peregrine »

Sarge Misfit wrote:Just a note for everyone, we do have the beginnings of a Script Library so feel free to donate any that you know work properly in Kitely. And feel free to use any that are posted. :D
http://www.kitely.com/forums/viewtopic.php?f=26&t=759
yea, that is why I did not post the boat script to the library, it is way beyond my pay scale, and, as Sherrie pointed out, it needs to be modified in some regards...frankly, I am happy to see it works here at all as there are so many variables. But as osg is the test grid, for the most part, such as that should work pretty good in any other os grid that is mostly current.

I am sure the creator will be pleased to see it being more used also, I just love how ppl share such things so freely...that spirit is something I wish to see much more nurtured, you do not see this at all, but the opposite, in most OS based commercial grids....or, they are held and doled out by only a few.

Yea, the speedboat has a cool spraying effect and there was also some texture for that, as I recall...I am just waking up and not inworld atm. It also included a sound effect.
These users thanked the author Constance Peregrine for the post:
Marstol Nitely
Laissez faire et laissez passer, le monde va de lui même!
My little sounds store https://www.kitely.com/market?store=2040306

Ephemeral wanderer...
User avatar
Boo Rojyo
Posts: 29
Joined: Wed Sep 04, 2013 7:47 pm
Has thanked: 60 times
Been thanked: 38 times

Re: SL Scripter comments, is this accurate

Post by Boo Rojyo »

If Minethere's script is the same as the one I've used which I think it is, then as well as the hard coded prim link numbers for the particles Sherrie, there is also another hard coded number for the sound ball as I recall. Once you've changed those numbers correctly it works a treat. I'm not a scripter but I did wonder if there's a way to configure the particle scripts not by prim link number but name of prim (eg 'front right engine'). Maybe somebody who knows about scripts could tell me that?

I do use the megaregion settings Ilan, which are in general pretty cool, one minor niggle is that sound on my boat only works in one of the four sims, the key sim I'm thinking. I've also had an issue with a Teleporter script which doesn't like any co-ordinates above the normal 256,256,nnn maximum zone. Maybe there's a general way to configure scripts to recognise sims outside of the normal maximum 256 metre co-ordinate limit?
User avatar
Ilan Tochner
Posts: 6545
Joined: Sun Dec 23, 2012 8:44 am
Has thanked: 5014 times
Been thanked: 4487 times
Contact:

Re: SL Scripter comments, is this accurate

Post by Ilan Tochner »

Hi Boo,

Please see: http://opensimulator.org/wiki/OsTeleportOwner, please let me know if it causes you problems above 256m.

When you say "sound on my boat only works in one of the four sims", what exactly are you referring to? What function are you using to play the sound?
User avatar
Sherrie Melody
Posts: 273
Joined: Fri Mar 29, 2013 6:56 pm
Has thanked: 201 times
Been thanked: 159 times

Re: SL Scripter comments, is this accurate

Post by Sherrie Melody »

Boo Rojyo wrote:If Minethere's script is the same as the one I've used which I think it is, then as well as the hard coded prim link numbers for the particles Sherrie, there is also another hard coded number for the sound ball as I recall. Once you've changed those numbers correctly it works a treat. I'm not a scripter but I did wonder if there's a way to configure the particle scripts not by prim link number but name of prim (eg 'front right engine'). Maybe somebody who knows about scripts could tell me that?
Yes, And it wouldn't take much. We can change it so that those behaviors work on prims by name, and to allow us to enable/disable those behaviors if we don't need them. The boat I was working on doesn't have a motor for example (although I was considering powering it by dolphins or maybe seagulls, LOL).

I'd planned to modify the script for myself, to do the above. If someone else doesn't get to it before I do, I'll post the updated script when I'm finished.
These users thanked the author Sherrie Melody for the post:
Marstol Nitely
Post Reply