[Opensim-dev] Proposal: Change the OnDeRezObject event

Charles Krinke cfk at pacbell.net
Fri Jul 10 15:44:29 UTC 2009


Dear Mw:

Thank you for sharing your technical thoughts as you work through them. It is my fervent hope that others will share similarly so that some of us 'lesser wizards' may learn a bit more by reading how OpenSim is evolving.

Charles




________________________________
From: MW <michaelwri22 at yahoo.co.uk>
To: opensim-dev at lists.berlios.de
Sent: Friday, July 10, 2009 7:39:06 AM
Subject: [Opensim-dev] Proposal: Change the OnDeRezObject event


In the current OnDeRezObject event, only a single localID of a prim is passed at a time.

So if multiple objects are DeRezzed in one action, even though all the ids are sent in a single packet. We have code in the ClientView that loops through that list and for each id triggers the OnDeRezObject event.

I propose moving that loop into the Scene handling of the action (Scene.DeRezObject(...))  so that the event is only triggered once per packet and if there are multiple prims to derezz in a packet, the scene code can loop through them and deal with them as required.

So current the delegate of the OnDeRezObject event is :

 public delegate void DeRezObject(
        IClientAPI remoteClient, uint localID, UUID groupID, DeRezAction action, UUID destinationID);

I propose changing it to:

public delegate void DeRezObject(
        IClientAPI remoteClient, List<uint> localIDs, UUID groupID, DeRezAction action, UUID destinationID);

It has to be better to have only one event triggering rather than possibly hundreds for the same user action. 

My next step (which I'm currently in the middle of in my local version) is to handle the taking of those multiple prims into inventory and only making a single inventory item, rather than the current method of a separate inventory item for each prim. But that will be detailed in a different proposal.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://opensimulator.org/pipermail/opensim-dev/attachments/20090710/00297c27/attachment-0001.html>


More information about the Opensim-dev mailing list