mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 17:05:55 +08:00
From: alan webb <alan_webb@us.ibm.com>
This fixes a sitting problem which popped up on loading regions from archive and turned out to be caused by the fact that the archiving mechanisms all preserve the sit-target information that is set in the object at the time the image is captured. This caused the new region to pick a sit-target prim that did not correspond to the prim on which the script was running, so the script's changed event is driven with an invalid avatar UUID. I have modified the ArchiveReadRequest class so that any sit information that survives the archiving process is deleted before the object is instantiated. This change has just been checked in.
This commit is contained in:
@@ -30,6 +30,7 @@ using OpenSim.Region.Environment.Scenes;
|
||||
using OpenSim.Region.Environment.Modules.World.Serialiser;
|
||||
using OpenSim.Region.Environment.Modules.World.Terrain;
|
||||
using System;
|
||||
using Axiom.Math;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.IO.Compression;
|
||||
@@ -135,6 +136,9 @@ namespace OpenSim.Region.Environment.Modules.World.Archiver
|
||||
part.CreatorID = masterAvatarId;
|
||||
part.OwnerID = masterAvatarId;
|
||||
part.LastOwnerID = masterAvatarId;
|
||||
// And zap any troublesome sit target information
|
||||
part.SitTargetOrientation = new Quaternion(0,0,0,1);
|
||||
part.SitTargetPosition = new Vector3(0,0,0);
|
||||
}
|
||||
|
||||
if (m_scene.AddRestoredSceneObject(sceneObject, true, false))
|
||||
|
||||
Reference in New Issue
Block a user