Merge branch 'master' of melanie@opensimulator.org:/var/git/opensim
commit
a431f346e7
|
@ -94,14 +94,6 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
set { m_velocity = value; }
|
set { m_velocity = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
protected Quaternion m_rotation = new Quaternion(0f, 0f, 1f, 0f);
|
|
||||||
|
|
||||||
public virtual Quaternion Rotation
|
|
||||||
{
|
|
||||||
get { return m_rotation; }
|
|
||||||
set { m_rotation = value; }
|
|
||||||
}
|
|
||||||
|
|
||||||
protected uint m_localId;
|
protected uint m_localId;
|
||||||
|
|
||||||
public virtual uint LocalId
|
public virtual uint LocalId
|
||||||
|
@ -115,13 +107,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public EntityBase()
|
public EntityBase()
|
||||||
{
|
{
|
||||||
m_uuid = UUID.Zero;
|
|
||||||
|
|
||||||
m_pos = Vector3.Zero;
|
|
||||||
m_velocity = Vector3.Zero;
|
|
||||||
Rotation = Quaternion.Identity;
|
|
||||||
m_name = "(basic entity)";
|
m_name = "(basic entity)";
|
||||||
m_rotationalvelocity = Vector3.Zero;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
@ -204,6 +204,14 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
get { return m_parts.Count; }
|
get { return m_parts.Count; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected Quaternion m_rotation = Quaternion.Identity;
|
||||||
|
|
||||||
|
public virtual Quaternion Rotation
|
||||||
|
{
|
||||||
|
get { return m_rotation; }
|
||||||
|
set { m_rotation = value; }
|
||||||
|
}
|
||||||
|
|
||||||
public Quaternion GroupRotation
|
public Quaternion GroupRotation
|
||||||
{
|
{
|
||||||
get { return m_rootPart.RotationOffset; }
|
get { return m_rootPart.RotationOffset; }
|
||||||
|
|
|
@ -243,7 +243,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
protected SceneObjectGroup m_parentGroup;
|
protected SceneObjectGroup m_parentGroup;
|
||||||
protected byte[] m_particleSystem = Utils.EmptyBytes;
|
protected byte[] m_particleSystem = Utils.EmptyBytes;
|
||||||
protected ulong m_regionHandle;
|
protected ulong m_regionHandle;
|
||||||
protected Quaternion m_rotationOffset;
|
protected Quaternion m_rotationOffset = Quaternion.Identity;
|
||||||
protected PrimitiveBaseShape m_shape;
|
protected PrimitiveBaseShape m_shape;
|
||||||
protected UUID m_uuid;
|
protected UUID m_uuid;
|
||||||
protected Vector3 m_velocity;
|
protected Vector3 m_velocity;
|
||||||
|
|
|
@ -481,6 +481,12 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Quaternion Rotation
|
||||||
|
{
|
||||||
|
get { return m_bodyRot; }
|
||||||
|
set { m_bodyRot = value; }
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// If this is true, agent doesn't have a representation in this scene.
|
/// If this is true, agent doesn't have a representation in this scene.
|
||||||
/// this is an agent 'looking into' this scene from a nearby scene(region)
|
/// this is an agent 'looking into' this scene from a nearby scene(region)
|
||||||
|
@ -2256,7 +2262,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
m_perfMonMS = Environment.TickCount;
|
m_perfMonMS = Environment.TickCount;
|
||||||
|
|
||||||
m_rotation = rotation;
|
Rotation = rotation;
|
||||||
Vector3 direc = vec * rotation;
|
Vector3 direc = vec * rotation;
|
||||||
direc.Normalize();
|
direc.Normalize();
|
||||||
|
|
||||||
|
|
|
@ -384,7 +384,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
||||||
m_host.AddScriptLPS(1);
|
m_host.AddScriptLPS(1);
|
||||||
if (World.Entities.ContainsKey(target))
|
if (World.Entities.ContainsKey(target))
|
||||||
{
|
{
|
||||||
World.Entities[target].Rotation = rotation;
|
EntityBase entity;
|
||||||
|
if (World.Entities.TryGetValue(target, out entity))
|
||||||
|
{
|
||||||
|
if (entity is SceneObjectGroup)
|
||||||
|
((SceneObjectGroup)entity).Rotation = rotation;
|
||||||
|
else if (entity is ScenePresence)
|
||||||
|
((ScenePresence)entity).Rotation = rotation;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue