Merge branch 'ubitwork' of ssh://3dhosting.de/var/git/careminster into ubitwork

avinationmerge
ubit 2012-05-15 01:08:59 +02:00
commit 493108be11
1 changed files with 14 additions and 4 deletions

View File

@ -10525,7 +10525,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
return new LSL_Vector(); return new LSL_Vector();
m_host.TaskInventory.LockItemsForRead(true); m_host.TaskInventory.LockItemsForRead(true);
if (m_host.TaskInventory[invItemID].PermsGranter == UUID.Zero)
UUID agentID = m_host.TaskInventory[invItemID].PermsGranter;
// if (m_host.TaskInventory[invItemID].PermsGranter == UUID.Zero)
if (agentID == UUID.Zero)
{ {
m_host.TaskInventory.LockItemsForRead(false); m_host.TaskInventory.LockItemsForRead(false);
return new LSL_Vector(); return new LSL_Vector();
@ -10539,7 +10543,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
} }
m_host.TaskInventory.LockItemsForRead(false); m_host.TaskInventory.LockItemsForRead(false);
ScenePresence presence = World.GetScenePresence(m_host.OwnerID); // ScenePresence presence = World.GetScenePresence(m_host.OwnerID);
ScenePresence presence = World.GetScenePresence(agentID);
if (presence != null) if (presence != null)
{ {
LSL_Vector pos = new LSL_Vector(presence.CameraPosition.X, presence.CameraPosition.Y, presence.CameraPosition.Z); LSL_Vector pos = new LSL_Vector(presence.CameraPosition.X, presence.CameraPosition.Y, presence.CameraPosition.Z);
@ -10556,7 +10561,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
return new LSL_Rotation(); return new LSL_Rotation();
m_host.TaskInventory.LockItemsForRead(true); m_host.TaskInventory.LockItemsForRead(true);
if (m_host.TaskInventory[invItemID].PermsGranter == UUID.Zero)
UUID agentID = m_host.TaskInventory[invItemID].PermsGranter;
// if (m_host.TaskInventory[invItemID].PermsGranter == UUID.Zero)
if (agentID == UUID.Zero)
{ {
m_host.TaskInventory.LockItemsForRead(false); m_host.TaskInventory.LockItemsForRead(false);
return new LSL_Rotation(); return new LSL_Rotation();
@ -10569,7 +10578,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
} }
m_host.TaskInventory.LockItemsForRead(false); m_host.TaskInventory.LockItemsForRead(false);
ScenePresence presence = World.GetScenePresence(m_host.OwnerID); // ScenePresence presence = World.GetScenePresence(m_host.OwnerID);
ScenePresence presence = World.GetScenePresence(agentID);
if (presence != null) if (presence != null)
{ {
return new LSL_Rotation(presence.CameraRotation.X, presence.CameraRotation.Y, presence.CameraRotation.Z, presence.CameraRotation.W); return new LSL_Rotation(presence.CameraRotation.X, presence.CameraRotation.Y, presence.CameraRotation.Z, presence.CameraRotation.W);