From 9bdeb8af6f797e35b5322d6856ecc488340c9453 Mon Sep 17 00:00:00 2001 From: lbsa71 Date: Mon, 6 Aug 2007 10:48:40 +0000 Subject: * SimpleApp works again: * NetworkServersInfo settable without config file * DefaultHomeLoc throws if getted before setted * Removed nonsensical sandbox distinction * Refactored default config file creation * Some more small refactorings on shapes --- .../Framework/General/Types/PrimitiveBaseShape.cs | 37 ++++++++++------------ 1 file changed, 16 insertions(+), 21 deletions(-) (limited to 'OpenSim/Framework/General/Types/PrimitiveBaseShape.cs') diff --git a/OpenSim/Framework/General/Types/PrimitiveBaseShape.cs b/OpenSim/Framework/General/Types/PrimitiveBaseShape.cs index 57018b2..1938a90 100644 --- a/OpenSim/Framework/General/Types/PrimitiveBaseShape.cs +++ b/OpenSim/Framework/General/Types/PrimitiveBaseShape.cs @@ -21,6 +21,9 @@ namespace OpenSim.Framework.Types { //protected ShapeType m_type = ShapeType.Unknown; + + private static byte[] m_defaultTextureEntry; + public byte PCode; public ushort PathBegin; public ushort PathEnd; @@ -60,9 +63,15 @@ namespace OpenSim.Framework.Types } } + static PrimitiveBaseShape() + { + m_defaultTextureEntry = new LLObject.TextureEntry(new LLUUID("00000000-0000-0000-9999-000000000005")).ToBytes(); + } + public PrimitiveBaseShape() { ExtraParams = new byte[1]; + TextureEntry = m_defaultTextureEntry; } //void returns need to change of course @@ -91,29 +100,15 @@ namespace OpenSim.Framework.Types { get { - BoxShape primShape = new BoxShape(); + BoxShape boxShape = new BoxShape(); - primShape.Scale = new LLVector3(0.5f, 0.5f, 0.5f); - primShape.PathBegin = 0; - primShape.PathEnd = 0; - primShape.PathScaleX = 0; - primShape.PathScaleY = 0; - primShape.PathShearX = 0; - primShape.PathShearY = 0; - primShape.PathSkew = 0; - primShape.ProfileBegin = 0; - primShape.ProfileEnd = 0; - primShape.ProfileHollow = 0; - primShape.PathRadiusOffset = 0; - primShape.PathRevolutions = 0; - primShape.PathTaperX = 0; - primShape.PathTaperY = 0; - primShape.PathTwist = 0; - primShape.PathTwistBegin = 0; - LLObject.TextureEntry ntex = new LLObject.TextureEntry(new LLUUID("00000000-0000-0000-9999-000000000005")); - primShape.TextureEntry = ntex.ToBytes(); + boxShape.Scale = new LLVector3(0.5f, 0.5f, 0.5f); - return primShape; + //boxShape.PathTaperX = 1; + //boxShape.PathTaperY = 1; + boxShape.PathSkew = 1; + + return boxShape; } } } -- cgit v1.1